Program Description
Phase 1
You are required to implement all steps in OpenGL transformation pipeline. You are also required to implement back-face culling, view frustum culling. Then draw a wireframe of the object.
Click here to download PPT
Phase 2
You are required to implements lighting, Guard shading, and hidden surface removal. Then draw the shaded image.
Click here to download PPT
Due Day
2006 12/12 (Thu), 15:00
Requirement
Phase 1
- Implement all steps in OpenGL transformation pipeline.
- Implement back-face culling.
- Implement view frustum culling.
- Draw the wire frame of the model.
- The object files, material files, and viewing files would be given.
- Can not use any OpenGL functions except
- glCLear
- glCLearColor
- glColor
- glBegin(GL_LINE_LOOP)
- glVetex2i
- glEnd
- glFlush
- glViewport
- glMatrixMode
- glLoadIdentity
- glOrtho2D
Phase 2
- Implement lighting.
- Implement Guard shading.
- Implement hidden surface removal.
- Draw the shaded image of the model.
- The object files, material files, and viewing files would be given.
- Can not use any OpenGL functions except
- glCLear
- glCLearColor
- glColor
- glBegin(GL_POINTS)
- glVetex2i
- glEnd
- glFlush
- glViewport
- glMatrixMode
- glLoadIdentity
- glOrtho2D
Bonus
Phase 1
- Implement view frustum clipping.
Phase 2
- Implement Phong shading.
Examples
There are some test cases. You can download it to test your program. Your program should get the file name from user. For example, when the program starts, it should ask the user to input the file name. If the user type "box", then the program should load box.obj, box.view.example 1:
box2.obj box2.mtl box2.view
wireframe
Guard shading
Phong shading
example 2:
psx.obj psx.mtl psx.view
wireframe
Guard shading
Phong shading