GXSetTevIndTile

Syntax

#include <revolution/gx.h>

void GXSetTevIndTile( GXTevStageID tev_stage,
                      GXIndTexStageID ind_stage,
                      u16 tilesize_s,
                      u16 tilesize_t, 
                      u16 tilespacing_s, 
                      u16 tilespacing_t, 
                      GXIndTexFormat format,
                      GXIndTexMtxID matrix_sel,
                      GXIndTexBiasSel bias_sel, 
                      GXIndTexAlphaSel alpha_sel);

Arguments

tev_stage TEV stage to be set. Accepted values are: GX_TEVSTAGE0, GX_TEVSTAGE1, GX_TEVSTAGE2, ... , GX_TEVSTAGE15.
ind_stage The indirect stage results used with this TEV stage.
Accepted values are: GX_INDTEXSTAGE0, GX_INDTEXSTAGE1, GX_INDTEXSTAGE2 and GX_INDTEXSTAGE3.
tilesize_s Size of the tile in the S direction.
Applicable values are 16, 32, 64, 128 and 256.
tilesize_t Size of the tile in the T direction.
Applicable values are 16, 32, 64, 128 and 256.
tilespacing_s Spacing of the tiles (in the tile definition map) in the S direction.
tilespacing_t Spacing of the tiles (in the tile-definition map) in the T direction.
format Specifies which indirect texture format to use. Accepted values are:
Name Indirect Offset Data and Bump Alpha
GX_ITF_8 Use all 8 bits as indirect offset data. The same data (the upper 5 bits) is copied as the bump alpha.
GX_ITF_5 Use lower 5 bits as indirect offset data. Remaining 3 bits become "bump alpha".
GX_ITF_4 Use lower 4 bits as indirect offset data. Remaining 4 bits become "bump alpha".
GX_ITF_3 Use lower 3 bits as indirect offset data. Remaining 5 bits become "bump alpha".
matrix_sel The indirect matrix and scale value to multiply the offsets by.
bias_sel Tile stacking direction for pseudo-3D textures. Accepted values are:
Name Bias-applied Components
GX_ITB_NONE None.
GX_ITB_S S component only.
GX_ITB_T T component only.
GX_ITB_U U component only.
GX_ITB_ST S and T components.
GX_ITB_SU S and U components.
GX_ITB_TU T and U components.
GX_ITB_STU All components: S, T, and U.
alpha_sel Specifies which offset component will supply the indirect bump alpha, if any (for pseudo-3D textures). Accepted values are:
Name Bump Alpha Source
GX_ITBA_OFF no bump alpha
GX_ITBA_S S component supplies bump alpha
GX_ITBA_T T component supplies bump alpha
GX_ITBA_U U component supplies bump alpha

Return Values

None.

Description

This function can be used to implement tile textures that use indirect textures. It will set up the correct values in the given indirect matrix; you only need to specify which matrix slot to use.

Be aware that the regular texture map contains only the tile definitions. The actual texture size to be applied to the polygon being drawn is the product of the base tile size and the size of the indirect map. The GXSetTexCoordScaleManually function must be called to set the appropriate texture coordinate scale. The GXSetIndTexCoordScale function can also be used to use the same texture coordinates for the indirect stage as for the regular TEV stage.

See Also

GXSetTevIndirect, GXSetTexCoordScaleManually, GXSetIndTexCoordScale

Revision History

2006/03/01 Initial version.


CONFIDENTIAL