User defined synchronizer callback function.
void CALLBACK SyncProc( HSYNC handle, DWORD channel, DWORD data, void *user );
handle | The sync that has occurred. |
channel | The channel that the sync occurred on. |
data | Additional data associated with the sync's occurrence. |
user | The user instance data given when BASS_ChannelSetSync was called. |
Unless the BASS_SYNC_THREAD flag is used, mixtime syncs are not executed in the sync thread but rather immediately in whichever thread triggers them. In most cases that will be an update thread. BASS_ChannelSetPosition may be used in such a callback to implement custom looping, eg. set a sync at the loop end position and seek to the loop start position in the callback. BASS_ChannelStop can also be used to end the channel at its current position.