G3_PerspectiveW

Syntax

#include <nitro/gx/g3_util.h>
void G3_PerspectiveW( fx32 fovySin, fx32 fovyCos, fx32 aspect, fx32 n, fx32 f, fx32 scaleW, MtxFx44 * mtx );

Arguments

fovySin Sine value of (the field-of-view angle in y-direction)/2
fovyCos Cosine value of (the field-of-view angle in y-direction)/2
aspect Ratio of width of view field to height of view field (aspect ratio: width/height of the field of view)
n Distance from viewpoint to the near clipping plane
f Distance from viewpoint to the far clipping plane
scaleW Precision adjustment parameter for the view volume
mtx Pointer to a 4x4 matrix.

Return Values

None.

Description

This function sets the Matrix mode to the Projection mode. This function also sets the Frustum matrix as the current matrix. If mtx is not NULL, then the perspective projection matrix is also set in *mtx.
The diagram shows the matrix that is set.

× scaleW

The divider is used internally. Refer to Divider Usage Notes when using this function inside an interrupt.

See Also

G3_Perspectve, G3_FrustumW, G3_OrthoW

Revision History

2004/04/27 Initial version.


CONFIDENTIAL