Assignment 1: Write a Paint Program


Due Date: 22.10.2013 Tuesday (09:30 am -10:20 am) in EA-203

This assignment will NOT be done in groups. Every individual student should do his/her homework.

Demo will be at class hour in EA building. Every student is required to be in the demo.

Grade Value: 15 %


Important Notice

You will demonstrate your programs to Dr.Güdükbay in the scheduled time. Demo times will be announced for each assignment in TA's course page. All the students must be physically available in the demonstrations. Demonstrations are a kind of exam. You will be asked questions to understand your contribution to the assignments in the demos.

You must also submit your source codes (including online documentation (comments and a README.txt file explaining how it is compiled and run) to the TA. You should email (with the Subject CS465 Assignment #1) to Ates Akaydin (akaydin@cs) a single zip file named as LastName_Name_CS465_Asst1.zip, containing two directories: Source, Executable, and a README.txt file describing how to compile and run your assignment.


Requirements

Write a simple paint program, a mini-Photoshop. Your program should have the following capabilities:

Important: Always comment your code. The code will also be checked during the demos.


Grading Criteria


Tips

Please make sure your program runs in preparation for the demos. You might want to pre-compile and test your program on a PC to prepare for your demo. Do not forget to copy any dynamic libraries(DLLs) and shader files to the same location where your executable file is.

You should use dragging appropriately to draw lines, rectangles, circles. For example, you can draw a line by pressing the mouse button to specify the initial point, drag the mouse until you give the final point. When you release the mouse, the final line could be drawn. While the mouse is pressed, intermediate lines are also displayed.

For the circle, press the mouse to specify the center, then while dragged draw intermediate circles, finally when you release the mouse the final circle is drawn.

You should be able to input line size, type (solid, dotted, dashed lines), color, brush size, type (circular, rectangular), color to draw shapes and painting.

To change the brush color, you could use three sliders (easiest), or pick from a few colored patches, or (if you're feeling ambitious) display a color chart and let the user point and pick. Optionally, you could let the user pick up a color from the image (maybe use left button for painting, middle button for picking a color?).


OpenGL Support

See TA's web page on development resources for pointers to documentation on OpenGL Shading Language.

You could use OpenGL Shading Language with the Freeglut, GLUT/GLUI libraries or the Qt Framework for constructing your user interfaces easily. Another alternative is to use MFC libraries of Visual C++.


Extra

If you complete all of the above, consider: