| ||||||||||
You only need to submit pictures with your PictureCollage.java IF you used pictures not in the MediaSources directory. You'll need to upload them along with PictureCollage.java. To resubmit (if you want to change something and submit again later), you'll first have to "retrieve" your assignment, and then reupload the files. Mark Guzdial |
Right – wherever you have your MediaSources. REMOVEDnny will change that one line, put your pictures in his MediaSources directory, then compile and execute your program. And it should just work. Mark Guzdial |
yes. Student24 |
Sure – I'm always happy to take questions! We've discussed public static void main in class and recitation, but I'm glad to take questions here or in class. There is some discussion of the main method on p. 69 in the course notes. My suggestion for HW2 is to download MyPicture.java or MyTurtlePicture.java from the Syllabus page and edit that to make your collage. Mark Guzdial |
For Picture or Turtle, you don't need to import anything at all – it's already available if you set up your Preferences as we've discussed. You only need to do other imports for other facilities. You import java.awt.* if you want to access the Color class. If you want to access JMusic, there are three imports to do – copy them from any of the examples in the course notes or slides. Anything particular you want to ask about? Mark Guzdial |
A change in size is valid, too. The collages that are currently on Gallery HW2: Picture collage-Sp05 are really cool, but I don't think that they actually meet the letter of what's required, yet. Mark Guzdial |
MAJOR BUMMER! |
There is no this in a public static void main. this refers to the instance that got the method. That doesn't exist in a main() method. Mark Guzdial |
The answer is that mirrorVertical changes this – it doesn't return a new picture. You can only cascade methods like that if the methods return pictures. Mark Guzdial |
If we can figure it out from the code, yes, it counts, but it'd probably be more fun if you tweak the colors as you pile it back up. Mark Guzdial |
It's not required yet, but you should. It'll be required from HW3 on. Use the code that you're seeing in class as an example – comment sections of code to explain what you're doing, and comment whole methods to explain what they do. Including your name and gt-email address is always a wise/safe thing to do. Mark Guzdial |