Functions | |
void | DPan_Camera (double theta, double phi) |
Similar to Pan_Camera(), but operates on double-precision data. More... | |
void | Pan_Camera (double theta, double phi) |
Sweeps the camera across its current scene. More... | |
Detailed Description
Function Documentation
◆ DPan_Camera()
void DPan_Camera | ( | double | theta, |
double | phi | ||
) |
Similar to Pan_Camera(), but operates on double-precision data.
- Parameters
-
theta - The distance, in degrees, that the camera should sweep to the right. Can be negative. phi - The distance, in degrees, that the camera should tilt upwards. Can be negative.
◆ Pan_Camera()
void Pan_Camera | ( | double | theta, |
double | phi | ||
) |
Sweeps the camera across its current scene.
- Parameters
-
theta - The distance, in degrees, that the camera should sweep to the right. Can be negative. phi - The distance, in degrees, that the camera should tilt upwards. Can be negative.
DETAILS
Once you've established a point of view, with Set_Camera_Position() and Set_Camera_Target() , or Set_Camera_By_Volume() , there are various ways provided to look around.
Pan_Camera() gives the effect of turning in place, with your view sweeping across the scene in front of you. A positive q rotates the camera to its right (the scene appears to move to the left), and a negative q rotates the camera to its left (the scene appears to move to the right.) Similarly, a positive f tilts the camera upwards and a negative f tilts it downwards.
If nonzero values are given for both q and f, first the horizontal Pan is performed, then the vertical. A full Pan of 360 degrees leaves you back where you started, of course. The axis of rotation is always the current camera Up Vector. If you'd like to "Pan" around an arbitrary axis, call Roll_Camera() , then Pan_Camera() , and then Roll_Camera() back again.
NOTES
If there is no Camera set up already in the segment, Pan_Camera() will create a default camera (-1 to +1, etc.) and then pan it. The owning segment's camera is ignored, so it's advisable to always do your camera work in the same segment.