(no commit message)
authorAsh Tyndall <[email protected]>
Fri, 21 Oct 2011 07:55:44 +0000 (15:55 +0800)
committerAsh Tyndall <[email protected]>
Fri, 21 Oct 2011 07:55:44 +0000 (15:55 +0800)
scene.c

diff --git a/scene.c b/scene.c
index 705c2d1..74b15ca 100644 (file)
--- a/scene.c
+++ b/scene.c
@@ -339,12 +339,18 @@ void display() {
   lightPosition0[2] = 12*sin(lightAngle0);\r
   lightPosition0[3] = 0.0;\r
 \r
+  direction0[0] = lightPosition0[0];\r
+  direction0[2] = lightPosition0[2];\r
+\r
   /* Reposition the light source 1. */\r
   lightPosition1[0] = 12*cos(lightAngle1);\r
   lightPosition1[1] = lightHeight1;\r
   lightPosition1[2] = 12*sin(lightAngle1);\r
   lightPosition1[3] = 0.0;\r
 \r
+  direction1[0] = lightPosition1[0];\r
+  direction1[2] = lightPosition1[2];\r
+\r
   glPushMatrix();\r
 \r
     /* Perform scene rotations based on user mouse/keyboard input. */\r

UCC git Repository :: git.ucc.asn.au