X-Git-Url: https://git.ucc.asn.au/?p=atyndall%2Fcits2231.git;a=blobdiff_plain;f=scene.c;h=9d3594e3d1b86354de28fd5491dc715e65a37043;hp=cfb80c084521b23c751fe8bffb9a2173c5fdf6e2;hb=b453f3e8de0bb1e4dcb4848e6d949ca6e2a0e070;hpb=91ab47db2c22378c5607e3fb5499a008edfb0289 diff --git a/scene.c b/scene.c index cfb80c0..9d3594e 100644 --- a/scene.c +++ b/scene.c @@ -110,10 +110,10 @@ char *dirDefault2 = "/cslinux/examples/CITS2231/project-files/models-textures"; char dataDir[200]; // Stores the directory name for the meshes and textures. static GLfloat floorVertices[4][3] = { - { -20.0, 0.0, 20.0 }, - { 20.0, 0.0, 20.0 }, - { 20.0, 0.0, -20.0 }, - { -20.0, 0.0, -20.0 }, + { -1000.0, 0.0, 1000.0 }, + { 1000.0, 0.0, 1000.0 }, + { 1000.0, 0.0, -1000.0 }, + { -1000.0, 0.0, -1000.0 }, }; static GLfloat lightColor[] = {1.0, 1.0, 1.0, 1.0}; // White light @@ -557,18 +557,16 @@ void display() { glDisable(GL_BLEND); glPushMatrix(); - glDisable(GL_LIGHTING); - + glLoadIdentity(); glColor3f(1.0, 0.0, 1.0); - glTranslatef(0.0, 8.0, 0.0); + glTranslatef(-8.0, 0.0, -10.0); - glutSolidTeapot(1); // Draw teapot for test - - glEnable(GL_LIGHTING); + glutSolidTeapot(10); // Draw teapot for test glPopMatrix(); glPushMatrix(); glDisable(GL_LIGHTING); + glLoadIdentity(); glColor3f(1.0, 1.0, 1.0); /* Draw a yellow ball at the light source. */