void render()
{
...
glLoadIdentity();
camera.transform.translate(0.0f, 0.0f, 10.0f); // move the camera away from the origin by 10 units..
glMultMatrixf(camera.transform);
object.transform.translate(0.0f, 0.0f, 10.0f); // how can I make this call translate the object
// 10 units from the origin and not the camera?
glMultMatrixf(object.transform);
object.render();
...
}
matrices...
If I have a camera at (0, 0, 10) that is 10 units away from the origin, how can I then create and place a cube so that it's 10 units away from the origin and not the camera?
Example.
Any ideas?
[Edited by - angry on June 10, 2005 3:05:53 PM]
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement