GXLoadTexObjPreLoaded

C Specification

#include <revolution/gx.h>
void GXLoadTexObjPreLoaded(
    const GXTexObj*        obj, 
    const GXTexRegion*     region,
    GXTexMapID               id );

Arguments

obj Pointer to the texture object that describes the texture and its properties.
region Pointer to a region object that describes the texture memory region.
id Texture name referenced by the texture environment (TEV) stage.

Return Values

None.

Description

This function loads the state describing a preloaded texture into one of the eight hardware register sets. Before this happens, the texture object, obj, should be initialized using GXInitTexObj or GXInitTexObjCI. The id argument refers to the texture state register set. The texture should be loaded beforehand using GXPreLoadEntireTexture.

Once loaded, the texture can be used in any texture environment (TEV) stage using the GXSetTevOrder function. GXInit initially calls GXSetTevOrder to make a simple texture pipeline that associates GX_TEXMAP0 with GX_TEVSTAGE0, GX_TEXMAP1 with GX_TEVSTAGE1, etc.

Note: GXLoadTexObjPreLoaded will not call the functions set by GXSetTexRegionCallBack (and GXSetTlutRegionCallBack if the texture is color index format) because the region is explicitly set. However, these callback functions must be aware of all regions that are preloaded. The default callbacks set by GXInit assume there are no preloaded regions.

See Also

GXPreLoadEntireTexture
GXSetTevOrder
GXInit
GXInitTexObj
GXInitTexObjCI
GXSetTexRegionCallBack
GXSetTlutRegionCallBack

Revision History

2006/03/01 Initial version.


CONFIDENTIAL