This program demonstrates the display list capability which includes matrix load commands. Matrix load APIs are APIs that you can use safely inside display lists. (You can call these APIs between GXBeginDisplayList and GXEndDisplayList.) Matrix load commands that reference index, such as GXLoadPosMtxIndx, are compatible with display lists because they load matrix data from the main memory when the display list is called.
This demo displays a snake model that contains 100 bones. Since the graphics hardware is limited to 10 matrix slots, you should frequently replace matrices to display these types of objects. This limitation might force you to divide the model into multiple pieces and repeatedly call matrix load commands and geometry primitives one after the other. However, it is possible to put the entire model into one display list by using indexed matrix load functions inside the display list. The snake model demo is packed into one display list, which is animated by updating the matrix array in every frame.
Display list functions.
| Functions | Parameters | Description |
GXBeginDisplayList |
list, size | An appropriate data pointer/size. |
GXEndDisplayList |
None. | |
GXCallDisplayList |
list, nbytes | An appropriate data pointer/size. |
Called inside a display list.
| Functions | Parameters | Description |
GXLoadPosMtxIndx |
Input source matrix index. | 0 - 99 |
| Destination matrix ID | GX_PNMTX0 - GX_PNMTX9 |
|
GXLoadNrmMtxIndx3x3 |
Input source matrix index. | 0 - 99 |
| Destination matrix ID | GX_PNMTX0 - GX_PNMTX9 |
|
GXLoadTexMtxIndx |
Input source matrix index. | 0 - 99 |
| Destination matrix ID | GX_TEXMTX0 - GX_TEXMTX9 |
|
| Matrix type. | GX_MTX2x4 |
The Control Stick manipulates the path of the snake model.
The substick controls global rotation of the snake model.
The A button resets the model position.
The B button stops the animation.
START exits the test.


$REVOLUTION_SDK_ROOT/dvddata/gxTest/tf-02.tpl is required.
2006/03/01 Initial version.
CONFIDENTIAL