Hi!
This question is going to be about the OgreCamera. But first a short info about my project.
We are creating a game that will take place on a very small planet. This planet is technically a sphere. So in this FPS game it is also possible to run around it. There are no ends.
To my problem:
To make this work, I have to modify both the camera and the physics. So far I have been trying to modify the camera. And here to my question:
What is the name of the OgreCamera:s up vector? I have been experimenting with the setFixedYawAxis() function. But this seems just to change the rotate axis, when I move the mouse. I did a function like this...
void Camera::yawToGround(void)
{
// Get the position of the camera
Vector3 eyePos = getPosition();
// Normalise the up vector
Vector3 up = eyePos.normalisedCopy();
// Set the up vector
setFixedYawAxis(true, up);
}
...that i invoke each time the camera updates. But what else should I do?
The planets centrum is in (0,0,0). With this function above I calculate the vector
from the planets centrum to the cameras eye. This vector I then want to be the up vector
of my camera. What is the name of the vector I should set this value to?
Thank you for helping
/Klarre
Camera up vector
- Clay
- OGRE Community Helper

- Posts: 518
- Joined: Wed Mar 17, 2004 4:14 am
- x 1
- Contact:
-
Klarre
- Kobold
- Posts: 31
- Joined: Mon Feb 14, 2005 9:52 pm