Tile Descriptor Loading
Tile descriptors must be loaded using the RDP command SetTile. This command loads the format, size, line, Tmem address, palette, clamp, mirror, mask, and shift parameters for the tile number specified. The SL, TL, SH, and TH parameters are set by the RDP commands SetTileSize, LoadTile, LoadBlock, and LoadTLUT.
One important point to keep in mind is that tile descriptors are used both when loading textures and when rendering textures. In particular, when loading a texture, the texture coordinate unit uses the Tmem address, line, format, and size information from the tile specified in the LoadTile/Block/TLUT command. Therefore, this information must be loaded into the tile descriptor prior to executing the LoadTile/Block/TLUT command. Also, the LoadTile/Block/TLUT command automatically writes the SL,TL,SH,TH information into the tile descriptor. In the case of a LoadTile command, this is probably the information you wanted. In the case of a LoadBlock or LoadTLUT command, however, this information must be overwritten with a SetTileSize command after the texture load.
The GBI commands for loading tile descriptors directly are:
The GBI commands that effect tile descriptors are:
Note: The load commands above use a double buffered tile system for loading/rendering. When loading, the tile G_TX_LOADTILE is used, and when rendering the tile G_TX_RENDERTILE is used. This simple scheme avoids having to insert TileSyncs between loading and rendering. However, if you need to use more than one tile for some reason, make sure that you use the g*DPSetTile and g*DPSetTileSize to set the tile descriptors properly.
Copyright © 1999
Nintendo of America Inc. All Rights Reserved
Nintendo and N64 are registered trademarks of Nintendo
Last Updated January, 1999