#include <revolution/gx.h>
void GXSetDrawDone( void )
None
None
This is part of a synchronization function. GXSetDrawDone will send a DrawDone command down the graphics processor's pipeline. When all previous commands have been processed and the pipeline is empty, a DrawDone status bit will be set, and an interrupt will occur. You can receive notification of this event by installing a callback on the interrupt with GXSetDrawDoneCallback, or you can poll the status bit with GXWaitDrawDone. GXSetDrawDone flushes the write-gather FIFO in the CPU to make sure that all commands are sent to the graphics processor.
This function is normally used in multibuffer-mode, see GXSetCPUFifo. In immediate-mode, the GXDrawDone command can be used, which both sends the command and passes time until the DrawDone status is true.
Note: Once the interrupt has fired, command processing will continue. In immediate-mode, this is not an issue since there should be no further commands in the FIFO. However, in multi-buffer mode, you may need to place a breakpoint after calling GXSetDrawDone to ensure that commands for subsequent frames are not executed.
2006/03/01 Initial version.
CONFIDENTIAL