3D camera orientaion
in
Programming Questions
•
5 months ago
I am making a 3D program, where you use the mouse to look around and the code for my camera movement is:
- float camZ = (height/2.0) / tan(PI*60.0 / 360.0);
- camera(width/2, height/2, camZ, // Camera location
- mouseX, mouseY/2.0, 0, // Camera target
- 0, 1, 0); // Camera orientation
1