G3_LookAt


C Specification

#include <nitro/gx/g3_util.h>
void G3_LookAt( const VecFx32 * camPos, const VecFx32 * camUp, const VecFx32 * target, MtxFx43 * mtx );

Description

This function sets the matrix mode to Position/Vector mode and sets the camera matrix as the current matrix. When mtx is not NULL, the camera matrix will also be set in *mtx. There is no need to normalize *camUp.

The matrix that is set up is shown below:

Arguments

camPos Pointer to the camera position vector
camUp Pointer to the camera up vector
target Pointer to the camera focal point
mtx Pointer to the 4x3 matrix

Return Values

None

See Also

Revision History

01/19/2004 Initial Version