vtCamera Class Reference
[Scene Graph]

Inheritance diagram for vtCamera:

Inheritance graph
[legend]
List of all members.

Detailed Description

A Camera is analogous to a physical camera: it description the location of a point from which the scene is rendered. It can either be a perspective or orthographic camera, and it very easy to control since it inherits all the methods of a transform (vtTransform).

Although the camera is a node, this is purely for convenience. You do not have to place the camera node in your scene graph. You may, however, tell your scene (vtScene) which camera to use. The scene produces a default camera which is used unless you tell it otherwise.


Public Member Functions

void SetHither (float f)
float GetHither () const
void SetYon (float f)
float GetYon () const
void SetFOV (float f)
float GetFOV () const
float GetVertFOV () const
void SetOrtho (bool bOrtho)
bool IsOrtho () const
void SetWidth (float f)
float GetWidth () const
void ZoomToSphere (const FSphere &sphere, float fPitch=0.0f)


Member Function Documentation

float vtCamera::GetFOV  )  const
 

Return the camera's horizontal field of view (FOV) in radians.

float vtCamera::GetHither  )  const
 

Get the hither (near) clipping plane distance.

float vtCamera::GetVertFOV  )  const
 

Return the camera's vertical field of view (FOV) in radians.

float vtCamera::GetWidth  )  const
 

Get the view width of an orthographic camera.

float vtCamera::GetYon  )  const
 

Get the yon (far) clipping plane distance.

bool vtCamera::IsOrtho  )  const
 

Return true if the camera is orthographic.

void vtCamera::SetFOV float  fov_x  ) 
 

Set the camera's horizontal field of view (FOV) in radians.

void vtCamera::SetHither float  f  ) 
 

Set the hither (near) clipping plane distance.

void vtCamera::SetOrtho bool  bOrtho  ) 
 

Set this camera to use an orthographic view. An orthographic view has no FOV angle, so Set/GetFOV have no affect. Instead, use Get/SetWidth to control the width of the orthogonal view.

void vtCamera::SetWidth float  fWidth  ) 
 

Set the view width of an orthographic camera.

void vtCamera::SetYon float  f  ) 
 

Set the yon (far) clipping plane distance.

void vtCamera::ZoomToSphere const FSphere sphere,
float  fPitch = 0.0f
 

Zoom (move) the camera to a sphere, generally the bounding sphere of something you want to look at. The camera will be pointing directly down the -Z axis at the center of the sphere.

Parameters:
sphere The sphere to look at.
fPitch An optional pitch angle to look, in radians. For example, a pitch of -PIf/10 would be looking down at a mild angle.


Generated on Tue Apr 22 10:11:06 2008 for vtlib library by  doxygen 1.4.5