There is an extra bit of code to center the frame on

This preview shows page 4 - 9 out of 9 pages.

contains the code to create the canvas, frame and animation. There is an extra bit of code to center the frame on start up. openGL version 2 is used. reshape – a bit of code to support translations, zooming can be configured here by manipulating the first value of the gluPerspective method call. display – Where the bulk of the code occurs. Notice the green commented sections with the name of the shape to be drawn using openGL primitives and vertex methods. Translations, rotations and sometimes scaling is performed on each shape. A lighting transformation is coded at the end of this method. Color transformation is also applied to each shape, the lighting transformation hides this. 5
Test Plan : What is tested Input Expected Out Actual Out Pass/Fail Frame is displayed Frame is displayed Frame is displayed pass 6 Images are displayed 6 Images are displayed 6 Images are displayed pass Translations Translations occur Translations occur pass Rotations Rotations occur Rotations occur pass Scales Scaling occurs Scaling occurs pass Animation sequence Animation occurs Animation occurs pass Lighting transformation Lighting transformation occurs Lighting transformation occurs pass Color transformation glu.gluPerspective(1 * 45.0f, h, 1.0, 20.0); changing 2 to 1 as the fovy multiplier Colors are transformed Colors are transformed pass zoom Zoom occurs Zoom occurs Exit on close Program shuts down when x button is hit Program shuts down when x button is hit pass
6 Lighting transformation, notice the darkness of the left hand side
7 Color transformation 6 shapes easily visible left to right: rhombus, two 3d triangles (one scaled), line loop (above pyramid), cube, 3D line Zoom in
8
9 References HWS Department of Mathematics and Computer Science. (n.d.). Retrieved November 19, 2017, from Point, T. (2017, August 15). JOGL Tutorial. Retrieved November 19, 2017, from (n.d.). Retrieved November 19, 2017, from

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture