Change Contents of the Bubble
View this PageEdit this PageUploads to this PageHistory of this PageHomeRecent ChangesSearchHelp Guide

Questions on HW2-Fall2006

Got questions on the homework?
Ask 'em here!

When I use te getmediafile it says
> java PictureCollage
Couldn't load the file C:/Documents and Settings/Mark Guzdial/My Documents/cs1316/MediaSources/swans.jpg

How do I fix this???

You need to set the media path. Right now it's set up for Professor Guzdial's computer. Here's what you do:
FileChooser.setMediaPath(String of the path to the folder containing the pictures you want);

For instance on my computer (Windows) it's like this.
FileChooser.setMediaPath("C://Program Files/cs1316/MediaSources/");

Now I want to use the MediaPath I just set.
p = new Picture (FileChooser.getMediaPath (String name of file));

On my computer (Windows) it's like this.
p = new Picture (FileChooser.getMediaPath ("arch.jpg"));

do u want us to draw our own picture and make a collage out of it or draw on top of another picture we find?

We want you to manipulate a Picture object (so that you have the original and 3 changed versions) and use a Turtle to drop the images around a World or Picture. The Turtle doesn't actually have to draw an picture (I'm not talking about the class but like a star or a circle or something). Here's an example of what I did.

Link to this Page