if ( buttonSelected == GLUT_LEFT_BUTTON ) {\r
// w: left/right, h: near/far\r
\r
- // **NOTE: Currently a work in progress\r
+ // **NOTE: Currently a work in progress, does not work correctly\r
printf("cam angle: %f\n", rotate*camRotateFactor);\r
sceneObjs[curObject].x += diffx * sin(rotate*camRotateFactor);\r
sceneObjs[curObject].z += diffx * cos(rotate*camRotateFactor);\r
break;\r
\r
case STATE_OBJECT_ROTATION_TEXTURE_SCALE:\r
+\r
if ( buttonSelected == GLUT_LEFT_BUTTON ) {\r
// w: rotate on y\r
sceneObjs[curObject].rotation.y += diffx * rotateFactor;\r
+\r
// h: rotate on x\r
sceneObjs[curObject].rotation.x += diffy * rotateFactor;\r
+\r
} else if ( buttonSelected == GLUT_MIDDLE_BUTTON ) {\r
// w: rotate on x\r
sceneObjs[curObject].rotation.x += diffx * rotateFactor;\r
+\r
// h: texture scale\r
float max = (float)height/texscaleFactor;\r
float scaling = (diffy + max) / max;\r
sceneObjs[curObject].texture.scale *= scaling;\r
+\r
}\r
+ \r
break;\r
\r
}\r