RenderWare V2.1

Previous Page Index Next Page

RwMatrix4d *

RwGetCameraLTM(RwCamera *camera, RwMatrix4d *matrix);

Description

Retrieves the camera’s Local Transformation Matrix (LTM) which maps object space to world space.

Arguments

camera Pointer to the camera.

matrix Pointer to the matrix that will receive the LTM.

Return Value

The argument matrix if successful and NULL otherwise.

Comments

The matrix returned by this function may be used to position a light or a clump at the camera. The following code fragment demonstrates this.

RwGetCameraLTM(Camera, RwScratchMatrix());
RwTransformLight(Light, RwScratchMatrix(), rwREPLACE);

See Also

RwCreateCamera()

RwGetCameraLookAt()

RwGetCameraLookRight()

RwGetCameraLookUp()

RwGetCameraPosition()

RwGetClumpLTM()

RwGetLightLTM()

RwResetCamera()

RwSetCameraLookAt()

RwSetCameraLookUp()

RwSetCameraPosition()

RwTransformCamera()

RwTransformClump()

RwTransformLight()