GXGetViewportv

Syntax

#include <revolution/gx.h>

void GXGetViewportv( f32* vp );

Arguments

vp Pointer to a floating point type array. Minimum size is GX_VIEWPORT_SZ.

Return Values

None.

Description

This function gets the current viewport parameters and places them in array vp.

The GXSetViewportv function sets the viewport in vector form. The order of parameters in vp corresponds to the order of parameters in the GXSetViewport function. The array returned by GXGetViewportv can be supplied as an argument to GXProject.

Examples

f32 vp[GX_VIEWPORT_SZ];

GXGetViewPortv( vp );
vp[2] = 512.0f; // change width to 512
GXSetViewportv( vp );

The viewport is typically set using parameters derived from the current render mode. For more information, see Render Modes.

See Also

GXSetScissor, MTXFrustum, Render Modes

Revision History

2006/03/01 Initial version.


CONFIDENTIAL