Exercises
|
Concepts-Lines |
Polygons and Triangles |
Concepts and Graphics |
Exercise 4 |
Part a.
Part b.
Run the code provided in the examples (lines.c) to produce the following output - turn in output and code

Duplicate the following with a background of Stars in the Sky (see below, Exercise 3, part b)

Part a: Concepts
#define drawOneLine(x1,y1,x2,y2) glBegin(GL_LINES); \
glVertex2f ((x1),(y1)); glVertex2f ((x2),(y2)); glEnd();
Part b: Graphics
Duplicate the following 3 OpenGL graphics approximately)

Output 2: Blue Triangle Twins Behind Red Rectangle

Output 3: Battle of the In-Color Line Invaders

¢ OpenGL Primitives are shown below.
¢ Modify the code provided in the text and notes as appropriate to reproduce the following
Ø Triangle Strip
Ø Triangle Fan
Ø Quad Strip
¢ Use any color you wish
¢ Turn in both output and code.
¢ You can use 3 separate programs to simplify the lab.
