Homework# 3 (Due Date: Monday December 18 by Midnight)

Submission:
Submit your homework via E-learning

Deliverables:
Name your code file Section#_StudentID_FirstName.cpp, e.g. 1_0160000_john.cpp

Download the framework code Hw3.cpp and add your code there.

Group Policy:

Description:
You are required to build a room scene that consists of a floor, walls, tables, teapots, table lamps, chairs, sidetables, picture frames, etc... See figure below.

This figure represents merely an example of what you can include in your scene. You are not asked to build this particular scene, rather I urge you to build a more complex and appealling scene in order to get the full credit.

To generate such objects you only need to use glut and glu 3D geometric objects representation such as: glutSolidCube, glutSolidCone, glutSolidTeapot, gluCylinder.

Here's an exmple on using gluCylinder
GLUquadricObj *p = gluNewQuadric();
gluCylinder(p, 1, 1, 1, 30, 30);

If you would like to add your own models to the scene, make sure to build your model around the origin (0, 0, 0) and then use transformations to move them around the scene. For example the floor is built as a square of length 1 centered at (0, 0, 0).
void draw_floor()
{
	glColor4f(.0, .6, 0, 1);
	glPushMatrix();
	glScalef(4, 0.01, 4);
	glBegin(GL_QUADS);
		glVertex3f(-0.5, 0, 0.5);
		glVertex3f(0.5, 0, 0.5);
		glVertex3f(0.5, 0, -0.5);
		glVertex3f(-0.5, 0, -0.5);
	glEnd();
	glPopMatrix();
}