Function SetUserPreVsyncCallback

From Uzebox Wiki
Jump to: navigation, search
Prototype

void SetUserPreVsyncCallback(VsyncCallBackFunc);

Description

Sets a function that will be called 60 times per second by the kernel *before* VSYNC tasks begin. Note that the VSYNC tasks execute in the following order:

1. Process user pre callback

2. Invoke video mode tasks

3. Refresh buttons/mouse state

4. Process music (music & mixing)

5. Process user post callback

Parameters
  • VsyncCallBackFunc: pointer to a function that will be invoked by the kernel.
Returns

Void

Video Modes

All

Since

V3.3

See Also

SetUserPostVsyncCallback

Example:

...
void VsyncCallBack(void){
    mmc_processMixer();
}
...
int main(){
    SetUserPreVsyncCallback(&VsyncCallBack);
    ...
}