N64® Functions Menu

al - Audio Library Functions
gDP - DP GBI Macros
gdSP - General GBI Macros
gSP - SP GBI Macros
gt - Turbo Microcode RDP
gu - Graphics Utilities
Math - Math Functions
nuSys - NuSystem
os - N64 Operating System
sp - Sprite Library Functions
uh - Host to Target IO
64DD - N64 Disk Drive

Nintendo® Confidential

   

gSPObjRenderMode

Format
gSPObjRenderMode(Gfx *gdl, u32 mode)
gsSPObjRenderMode(u32 mode)
Arguments
  • gdl is the pointer to the display list
  • mode is the object render mode
What This Macro Does
It is an S2DEX microcode macro that sets or changes the object render mode of the RSP. Usually, the object render mode is set based on the display mode.

Many drawing parameters exist in the RDP to control sprite and BG drawing. Depending on the RDP mode, polygon drawing and rectangle drawing processes are affected in some subtle ways. For example, by setting bilinear interpolation on and off, texture coordinates will vary by 0.5. S2DEX microcode has been designed to correct these effects at the RSP to make it easier for you to get around these problems. The RSP�s correction process corresponds to the RDP�s mode. We call the RSP�s correction mode "object render mode" (or OBJ render mode).

Automatic selection of this mode will increase the processing overhead of the RSP; so currently Copy Mode and 1,2CycleMode have the benefit of automatic operation. For other modes, you need to use this macro to let the RSP know which mode you want. The current object render mode has an independent rendering function in addition to the capability to correct the effects caused by changing the RDP�s mode.

The flags you can use to set the object render mode are listed below. If multiple settings are required, connect the conditions using the OR operator. However, G_OBJRM_SHRINKSIZE_1 and G_OBJRM_SHRINKSIZE_2 can not be used at the same time.
  • G_OBJRM_NOTXCLAMP - does not perform clamp operation for peripheral part of the texture
  • G_OBJRM_BILERP - switches to on for bilinear interpolation
  • G_OBJRM_SHRINKSIZE_1 - cuts 0.5 texel around the image
  • G_OBJRM_SHRINKSIZE_2 - cuts 1.0 texel around the image
  • G_OBJRM_WIDEN - expands the image by 3/8 texel
For a detailed explanation of each flag, please see the "S2DEX Microcode" area of the N64 Programming Manual.

See Also
S2DEX Microcode
guS2DInitBg


Nintendo® Confidential

Warning: all information in this document is confidential and covered by a non-disclosure agreement. You are responsible for keeping this information confidential and protected. Nintendo will vigorously enforce this responsibility.


Copyright © 1998
Nintendo of America Inc. All rights reserved
Nintendo and N64 are registered trademarks of Nintendo
Last updated January 1998