0% found this document useful (0 votes)
11 views

PictureExplorerLab_PictureExplorerLab (1)

The document outlines a lab assignment involving the PictureExplorer.java class, requiring students to answer specific questions about image dimensions and indexing. It includes tasks for modifying the main method to explore different pictures, adding new images, and scaling them using the Picture class. Students must document their code modifications and results through screenshots in a word document for submission.

Uploaded by

lt
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views

PictureExplorerLab_PictureExplorerLab (1)

The document outlines a lab assignment involving the PictureExplorer.java class, requiring students to answer specific questions about image dimensions and indexing. It includes tasks for modifying the main method to explore different pictures, adding new images, and scaling them using the Picture class. Students must document their code modifications and results through screenshots in a word document for submission.

Uploaded by

lt
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

Picture Explorer Lab

Type your answers to the following questions into a word document and submit to the dropbox.

Part A:

Use the PictureExplorer.java class to answer the following questions.

1. What is the row and column index for the top left corner of the picture?
2. The width of this picture is 640. What is the right most column index?
3. The height of this picture is 480. What is the bottom most row index?
4. Does the row index increase from left to right or top to bottom?
5. Set the zoom to 500%. What do you see?

Part B:

1. Modify the main method in the PictureExplorer class to create and explore a different picture from the images folder. Take a
screenshot of your modified code and paste it into your word document.
2. Add a picture to the images folder (remember it is set up to pull files from this folder, so it is important that you put the image in this
folder) and then create and explore that picture in the main method. Take a screenshot of your modified code and paste it into your word
document.
3. Scale the picture you added in step 2 by using the scale method in the Picture class. Take a screenshot of your code and before and
after screenshots of your picture and paste them into your word document.

For example, you can make a new picture one-fourth the size of the original by using:

You might also like