KFbxGlobalCameraSettings
#include<kfbxglobalcamerasettings.h>

List of all members.

Detailed Description

This class contains the global camera settings.

Definition at line78of filekfbxglobalcamerasettings.h.


Default viewing settings Camera

enum EViewingMode
 Viewing modes.More...
bool SetDefaultCamera(char *pCameraName)
 Set the default camera.
char * GetDefaultCamera()
 Get default camera name.
void RestoreDefaultSettings()
 Restore default settings.
void SetDefaultViewingMode(EViewingModepViewingMode)
 Set default viewing mode.
EViewingMode GetDefaultViewingMode()
 Get default viewing mode.

Error Management

The same error object is shared among instances of this class.

enum EError
 Error identifiers Most of these are only used internally.More...
KErrorGetError()
 Retrieve error object.
EError GetLastErrorID() const
 Get last error code.
const char * GetLastErrorString() const
 Get last error string.

Producer Cameras

Producer cameras are global cameras used in MotionBuilder to view the scene.

They are not animatable but their default position can be set.

void CreateProducerCameras()
 Create the default producer cameras.
void DestroyProducerCameras()
 Destroy the default producer cameras.
bool IsProducerCamera(KFbxCamera*pCamera)
 Check if the camera is one of the producer cameras.
KFbxCameraSwitcherGetCameraSwitcher()
 Get the camera switcher node.
void SetCameraSwitcher(KFbxCameraSwitcher*pSwitcher)
 Set the camera the camera switcher.
KFbxCameraGetCameraProducerPerspective()
 Get a reference to producer perspective camera.
KFbxCameraGetCameraProducerTop()
 Get a reference to producer top camera.
KFbxCameraGetCameraProducerBottom()
 Get a reference to producer bottom camera.
KFbxCameraGetCameraProducerFront()
 Get reference to producer front camera.
KFbxCameraGetCameraProducerBack()
 Get reference to producer back camera.
KFbxCameraGetCameraProducerRight()
 Get reference to producer right camera.
KFbxCameraGetCameraProducerLeft()
 Get reference to producer left camera.

Public Member Functions

constKFbxGlobalCameraSettingsoperator=(constKFbxGlobalCameraSettings&pGlobalCameraSettings)
 Assignment operator.

Member Enumeration Documentation

Viewing modes.

  • eSTANDARD
  • eXRAY
  • eMODELS_ONLY

Definition at line108of filekfbxglobalcamerasettings.h.

enumEError

Error identifiers Most of these are only used internally.

  • eNULL_PARAMETER
  • eUNKNOWN_CAMERA_NAME
  • eERROR_COUNT

Definition at line228of filekfbxglobalcamerasettings.h.

Member Function Documentation

bool SetDefaultCamera(char * pCameraName ) 

Set the default camera.

Parameters:
pCameraName Name of the default camera.
Returns:
trueif camera name is valid,falseotherwise.
Remarks:
A valid camera name is either one of the defined tokens (PRODUCER_PERSPECTIVE, PRODUCER_TOP, PRODUCER_FRONT, PRODUCER_RIGHT, CAMERA_SWITCHER) or the name of a camera inserted in the node tree under the scene's root node.

char* GetDefaultCamera( ) 

Get default camera name.

Returns:
The default camera name, or an empty string if the camera name has not been set

void RestoreDefaultSettings( ) 

Restore default settings.

void SetDefaultViewingMode(EViewingMode pViewingMode ) 

Set default viewing mode.

Parameters:
pViewingMode Set default viewing mode to either eSTANDARD, eXRAY or eMODELS_ONLY.

EViewingModeGetDefaultViewingMode( ) 

Get default viewing mode.

Returns:
The currently set Viewing mode.

void CreateProducerCameras( ) 

Create the default producer cameras.

void DestroyProducerCameras( ) 

Destroy the default producer cameras.

bool IsProducerCamera(KFbxCamerapCamera ) 

Check if the camera is one of the producer cameras.

Returns:
true if it is a producer camera false if not

KFbxCameraSwitcher* GetCameraSwitcher( ) 

Get the camera switcher node.

Returns:
Pointer to the camera switcher
Remarks:
This node has a node attribute of typeKFbxNodeAttribute::eCAMERA_SWITCHER. This node isn't saved if the scene contains no camera. Nodes inserted below are never saved.
Camera indices start at 1. Out of range indices are clamped between 1 and the number of cameras in the scene. The index of a camera refers to its order of appearance when searching the node tree depth first.

Use functionKFbxTakeNode::GetCameraIndex()to get and set the camera index. If a camera is added or removed after camera indices have been set, the camera indices must be updated. It's much simpler to set the camera indices once all cameras have been set.

Camera index keys must be set with constant interpolation to make sure camera switches occur exaclty at key time.

void SetCameraSwitcher(KFbxCameraSwitcherpSwitcher ) 

Set the camera the camera switcher.

Returns:
The reference to the internal Perspective camera.

KFbxCamera* GetCameraProducerPerspective( ) 

Get a reference to producer perspective camera.

Returns:
The reference to the internal Perspective camera.

KFbxCamera* GetCameraProducerTop( ) 

Get a reference to producer top camera.

Returns:
The reference to the internal Top camera.

KFbxCamera* GetCameraProducerBottom( ) 

Get a reference to producer bottom camera.

Returns:
The reference to the internal Bottom camera.

KFbxCamera* GetCameraProducerFront( ) 

Get reference to producer front camera.

Returns:
The reference to the internal Front camera.

KFbxCamera* GetCameraProducerBack( ) 

Get reference to producer back camera.

Returns:
The reference to the internal Back camera.

KFbxCamera* GetCameraProducerRight( ) 

Get reference to producer right camera.

Returns:
The reference to the internal Right camera.

KFbxCamera* GetCameraProducerLeft( ) 

Get reference to producer left camera.

Returns:
The reference to the internal Left camera.

constKFbxGlobalCameraSettings&operator=(constKFbxGlobalCameraSettingspGlobalCameraSettings ) 

Assignment operator.

KError&GetError( ) 

Retrieve error object.

Returns:
Reference to error object.

EErrorGetLastErrorID( ) const

Get last error code.

Returns:
Last error code.

const char* GetLastErrorString( ) const

Get last error string.

Returns:
Textual description of the last error.