Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / 3D Camera Problem After adding Z axis manipulation

Author
Message
VinceB
15
Years of Service
User Offline
Joined: 12th Sep 2009
Location:
Posted: 12th Sep 2009 12:02
I (reluctantly) copied the code from the main site to turn the camera on the x and y axes and from there also built a couple more commands that made the camera strafe left and right. The forward, back, left, right, and 360 degree turning via the mouse worked perfectly. Then I decided to add the z axis rotation to roll the camera and now when I move left or right, there is an unwanted transformation in there.

The following code is all in the main loop with all the fCameraAngle floats initialized before the main loop.



I'm fairly certain I will have to code in 3D math functions to handle the relationship between the 3 axes as the camera is manipulated past simple left / right transformations. Since I've never done anything like that before, any tips on where to start? Or whether or not I'm on to the right idea at all?

Login to post a reply

Server time is: 2024-11-20 15:35:29
Your offset time is: 2024-11-20 15:35:29