Function

nuGfxTaskStart

Syntax
void nuGfxTaskStart(Gfx *gfxList_ptr, u32 gfxListSize, u32 ucode, u32 flag)

Arguments

Return Value
None

Explanation
Start the graphics task.

When this function is called, the graphics task structure is created and the task message is sent to the graphics task thread. The ucode is the microcode to be used. When the microcode registered by the nuGfxInit function is used, the following macros are specified.

Macro Microcode
NU_GFX_UCODE_F3DEX gspF3DEX.fifo
NU_GFX_UCODE_F3DEX_NON gspF3DEX.NoN.fifo
NU_GFX_UCODE_F3DLX gspF3DLX.fifo
NU_GFX_UCODE_F3DLX_NON gspF3DLXNoN.fifo
NU_GFX_UCODE_F3DLX_REJ gspF3DLX.Rej.fifo
NU_GFX_UCODE_L3DLP_REJ gspL3DLP.Rej.fifo
NU_GFX_UCODE_S2DEX gspS2DEX.fifo
NU_GFX_UCODE_S2DEX_D gspS2DEX.fifo_d

When using a microcode registered by the nuGfxInitEX2 function or when F3DEX_GBI_2 is defined, specify one of the following macros.


Macro Microcode
NU_GFX_UCODE_F3DEX2 gspF3DEX2.fifo
NU_GFX_UCODE_F3DEX2_NON gspF3DEX2.NoN.fifo
NU_GFX_UCODE_F3DEX2_REJ gspF3DEX2.Rej.fifo
NU_GFX_UCODE_F3DLX2_REJ gspF3DLX2.Rej.fifo
NU_GFX_UCODE_L3DEX2 gspL3DEX2.fifo
NU_GFX_UCODE_S2DEX2 gspS2DEX2.fifo

When the microcode table is registered using the nuGfxSetUcode function, the table number is specified.

It is possible to specify whether or not the frame buffer is to be transferred to the VI when completing the task using the flag.

The call back function which is registered by the nuGfxSwapCfbFuncSet function is executed when NU_SC_SWAPBUFFER is specified. Normally, as the nuGfxSwapCfb function is registered by the nuGfxInit function, the frame buffer will be displayed on the screen at the next retrace. Therefore, when the multiple graphics tasks are to be started against one frame buffer, specify NU_SC_SWAPBUFFER for the last task.

The call back function which is registered by the nuGfxTaskEndFuncSet function is executed when NU_SC_NOSWAPBUFFER is specified. Normally, nothing is registered.

NU_SC_NORDP is specified for microcode such as ZSort, which only uses the RSP. In this case, it does not wait for the completion of the RDP event. NU_SC_NORDP can be specified at the same time as NU_SC_NOSWAPBUFFER or NU_SC_SWAPBUFFER.

The flag which is to be handed over, when the graphics task has been executed, can be specified in the most significant 16 bits of the flag. Depending upon the type of microcode used and the microcode execution sequence, there are cases where flags are necessary. Normally, there is no need to specify flags when executing a task.

Example


	Gfx	gfxList[0x100];		/* display list buffer */
	Gfx*	gfxList_ptr;		/* pointer to display list buffer */

	gfxList_ptr = gfxList;
	gSPDisplayList(gfxList_ptr++, OS_K0_TO_PHYSICAL(rdpstateinit_dl));
	gDPFullSync(gfxList_ptr++); gSPEndDisplayList(gfxList_ptr++);
	nuGfxTaskStart(gfxList, (s32)(gfxList_ptr - gfxList) * sizeof (Gfx),
		 NU_GFX_UCODE_F3DEX , NU_SC_NOSWAPBUFFER);

See Also
nuGfxInit
nuGfxSetUcode
nuGfxSwapCfbFuncSet
nuGfxSwapCfb
nuGfxTaskEndFuncSet


Revision History
2/1/1999   Added text regarding F3DEX2. Added text regarding flag.