audio_sync_group_debug

Toggle on or off the audio sync group debug overlay.

Syntax:

audio_sync_group_debug(group_index);


ArgumentDescription
group_index The group index to debug, or -1 to switch off the debugging.


Returns: N/A


Description

This function can be used to display debug information about any given sync group (the group index is the value returned when the group was created using the function audio_create_sync_group()). You can call the function with a value of -1 to switch off the overlay.

When you are debugging the audio sync groups, the overlay will show Which sync groups is debugging

  1. How many channels are in it
  2. How many times the sync group has failed (this means it's tried to do too much work)
  3. A list of the channels
  4. A profiling bar that shows what work the decoding thread is doing

Note that for general debugging of audio, you also have the function audio_debug().


Example:

if (debug_mode)
   {
   audio_sync_group_debug(sg);
   }
else
   {
   audio_sync_group_debug(-1);
   }

The above code will switch on or off the audio sync group debug overlay showing the sync group indexed in the variable "sg" depending on whether the game is run in debug mode or not.


Back: Audio Synchronisation
Next: audio_sync_group_is_playing

© Copyright YoYo Games Ltd. 2018 All Rights Reserved