tf-tg-mtx uses all default texture matrices to test texture coordinate generation. The following texture coordinate schemes are tested. (Texture coordinates) * (Identity matrix)
(Position coordinates) * (3x4 matrix) : Texture projection
(Texture coordinates) * (2x4 matrix) : Texture transform
(Normal vector) * (3x4 matrix) : Reflection mapping
The GX_IDENTITY matrix is always transforming the center cube for comparison. Since this would result in Q=0 for projection and reflection mapping, the center cube is not drawn for those cases.
It is important to note for the reflection mapping area, the normals of the cube have been bent outward to resemble those of a sphere. We would have used a sphere model except that it is very hard to tell when a reflection-mapped sphere is rotating.
| Function | Parameters | Description |
| GXLoadTexMtxImm | Matrices | different matrix sent down for each cube |
| matrix destination | GX_TEXMTX0 - GX_TEXMTX9 | |
| Matrix type | GX_MTX2x4 or GX_MTX3x4 depeneding on generation type. |
|
| GXSetTexCoordGen | Destination coordinates. | Always GX_TEXCOORD0. |
| texgen type | GX_TG_MTX3x4 or GX_TG_MTX2x4 depending on generation type. |
|
| texgen src | GX_TG_TEX0, GX_TG_POS, GX_TG_NRM | |
| Matrix input source. | GX_TEXMTX0-GX_TEXMTX9, GX_IDENTITY |
START exits the demo.
The B Button stops/starts cube rotation.
The X Button changes the texgen method.
No texgen. The texture coordinates are all transformed by an identity matrix.

Projected texture.

Texture transform.

Reflection mapping.

$REVOLUTION_SDK_ROOT/dvddata/gxTests/tf-02.tpl
03/01/2006 Initial version.