CS 111 - Introduction to Computing, Fall 2012

Fall 2012

Project 2 - Making 3D Images

Due: Tuesday, October 23, 2012 at 11:59 pm

For this assignment, you are to combine two images into a single 3 dimension image. These images will be viewed using red/blue glasses to give the 3D effect. The final image will attempt to be a grayscale of the object in the original original images. However with the red/blue glasses, one eye will only see the red color while the other eye will see the green/blue color.

The two images will need to be pictures of the same thing taken from a slightly different view point. The first image will view the object just to the left of the view of the second image. The left image will be converted to a red-scale image. The right image will be converted to a green/blue-scale image.

Once the red-scale and green/blue-scale images have been created, they can be combined into a single image. At each pixel in the final image, the amount of red will come from the corresponding pixel in the red-scale image; while the amount of green and bluee will come from the corresponding pixel in the green/blue-scale image.

You are to verify that the two images have the same width and height before attempting to create the 3D image. If the images do not match, print out an error message and exit the program.

Check out the following images of UIC (courtesy of Google Earth):

UICLeft.jpg UICRight.jpg IntroductionToComputing/folder f11/i101/WWW/projects/hwimages/UICLeft.jpg" /> IntroductionToComputing/folder f11/i101/WWW/projects/hwimages/UICRight.jpg" />

These two combine to create the following 3D image:


The intermediate versions of the images are as follows. Note that there is no reason to actually create and save these intermediate versions. You should be able to go from the two original images directly to the 3D image.


Other source images are:
IntroductionToComputing/folder f11/i101/WWW/projects/hwimages/ChicagoLeft.jpg" /> IntroductionToComputing/folder f11/i101/WWW/projects/hwimages/ChicagoRight.jpg" /> ChicagoLeft.jpg

The 3D result can be seen here.

IntroductionToComputing/folder f11/i101/WWW/projects/hwimages/test_left.jpg" /> IntroductionToComputing/folder f11/i101/WWW/projects/hwimages/test_right.jpg" />
The 3D result can be seen here.

Your code is to prompt the user for the left image first, then the right image. The final image is to be displayed and you are to prompt the user for a name to store the resulting image.

Programming Style

Part of the grade for this project will be on your use of good programming style. Programming style includes:
  • The use of methods!!! - the key factor in the grade for the points for style
  • The use of meaningful variable names
  • The use of header block comments at the beginning of each method and at the start of your program
  • The use of inline comments
  • The appropriate use of indentation
  • The appropriate use of blank lines

Project Collaboration

You are allowed to receive help on this project from other students who are also taking CS 101. Each student must still complete and submit his/her own project. You will be required to include a Collaboration Statement somewhere on your project if you receive help. This statement can simply be something like the following:
For this project, I received help from the following member of CS 101.
This statement should list each helping student's name in a comment in the "header comment" of your Java file that includes the main() method.

Submission of your Project

You must electronically submit all of your files (all .java files, any image files and any other files used) to the link for Project 2 in Blackboard.

-- Main.troy - 2012-10-09

Topic attachments
I Attachment Action Size Date Who Comment
JPEGjpg ChicagoLeft.jpg manage 70.9 K 2012-10-09 - 14:19 UnknownUser  
JPEGjpg ChicagoRight.jpg manage 73.1 K 2012-10-09 - 14:20 UnknownUser  
JPEGjpg UIC3d.jpg manage 337.4 K 2012-10-09 - 14:21 UnknownUser  
JPEGjpg UICLeft.jpg manage 77.6 K 2012-10-09 - 14:20 UnknownUser  
JPEGjpg UICLeftRed.jpg manage 260.6 K 2012-10-09 - 14:22 UnknownUser  
JPEGjpg UICRight.jpg manage 77.4 K 2012-10-09 - 14:20 UnknownUser  
JPEGjpg UICRightGreenBlue.jpg manage 304.0 K 2012-10-09 - 14:23 UnknownUser  
Edit | Attach | Print version | History: r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions...
Topic revision: r1 - 2012-10-09 - 14:24:33 - Main.troy
Copyright 2016 The Board of Trustees
of the University of Illinois.webmaster@cs.uic.edu
Helping Women Faculty Advance
Funded by NSF