tev-one-op

Description

This program tests the color composition algorithm on a TEV stage. Only one TEV stage is used, and the output is displayed as the rectangle of Result. Any possible combination of seven input parameters (ArgA, ArgB, ArgC, ArgD, Op, Bias, Scale) can be tested by modifying the control panel.

Coverage

Functions Parameters Description
GXInitTexObj Pointer to image data. Appropriate value.
Width and height Fixed value.
format GX_TF_RGBA8, GX_TF_I4
Wrap mode (s, t). Always GX_REPEAT.
Mipmap Always GX_FALSE.
GXLoadTexObj Destination texture name. Always GX_TEXMAP0.
GXSetNumTevStages Number of TEV stages. Always 1.
GXSetTevColor Destination color register ID. GX_TEVREG0, GX_TEVREG1, GX_TEVREG2, GX_TEVPREV
Color Various values.
GXSetTevColorIn TEV stage ID. Always GX_TEVSTAGE0.
Input argument A GX_CC_C0, GX_CC_C1, GX_CC_C2, GX_CC_CPREV, GX_CC_A0, GX_CC_A1, GX_CC_A2, GX_CC_APREV, GX_CC_TEXC, GX_CC_TEXA, GX_CC_RASC, GX_CC_RASA, GX_CC_ONE, GX_CC_HALF, GX_CC_QUARTER, GX_CC_ZERO, GX_CC_TEXRRR, GX_CC_TEXGGG, GX_CC_TEXBBB
Input argument B
Input argument C
Input argument D
GXSetTevColorOp TEV stage ID. Always GX_TEVSTAGE0.
TEV operation GX_TEV_ADD, GX_TEV_SUB
Bias value GX_TB_ZERO, GX_TB_ADDHALF, GX_TB_SUBHALF
Scale value GX_CS_SCALE_1, GX_CS_SCALE_2, GX_CS_SCALE_4, GX_CS_DIVIDE_2
Clamp result Always GX_TRUE.
Output register ID Always GX_TEVPREV.

Using the Demo

START exits the demo.

TheControl Stick or +Control Pad moves the cursor.

The X and Y Buttons change the value for the argument that the cursor points to.

The R Button changes the texture if the cursor points to the input argument that indicates the texture.
The R button changes the register color if the cursor points to the input argument that indicates a register.

Snapshot

A=RASC, B=TEXC, C=TEXA, D=ZERO, Op=add, Bias=0 and Scale=1 (settings close to GX_DECAL).

Tev-one-op-00.jpg (32531 bytes)

A=ZERO, B=TEXC, C=ONE, D=ZERO, Op=add, Bias=0 and Scale=4. (TEXC x 4).

Tev-one-op-03.jpg (32312 bytes)

A=C2, B=ONE, C=C1, D=C0, Op=add, Bias=0 and Scale=1.

Tev-one-op-06.jpg (27606 bytes)

A=A0, B=ONE, C=TEXC, D=ONE, Op=sub, Bias=0 and Scale=1.

Tev-one-op-09.jpg (31085 bytes)

Required Data Files

$REVOLUTION_SDK_ROOT/dvddata/gxTests/tev-00.tpl

Revision History

2006/03/01 Initial version.


CONFIDENTIAL