Important: The information in this document is obsolete and should not be used for new development.
DoVBLTask
Slot interrupt handlers for video cards should call theDoVBLTaskfunction to handle the execution of VBL tasks.
FUNCTION DoVBLTask (theSlot: Integer): OSErr;
theSlot- Slot number corresponding to the vertical retrace queue whose tasks are to be executed.
DESCRIPTION
TheDoVBLTaskfunction decrements thevblCountfield of each task in the vertical retrace queue corresponding to thetheSlotparameter (except for tasks whosevblCountfield already contains the value 0). The function executes a task if decrementing thevblCountfield for a task record results in a value of 0.If
theSlotdesignates the slot of the primary video device, the position of the cursor is also updated.Slot interrupt handlers for video cards need to call this function to execute any tasks in the queue for that slot. You can also call this function if you need to simulate vertical retrace interrupts.
ASSEMBLY-LANGUAGE INFORMATION
The registers on entry and exit forDoVBLTaskare
Registers on entry D0 Slot number
Registers on exit D0 Result code To reduce overhead at interrupt time, instead of executing the
_DoVBLTasktrap, you can load the jump vectorjDoVBLTaskinto an address register and execute aJSRinstruction using that register.RESULT CODES
noErr 0 No error slotNumErr -360 Invalid slot number