Reserve channels

From Bennu Wiki
Jump to navigation Jump to search


Definition

INT reserve_channels ( <INT num_channels> )

This functions reserves the indicated number of sound channels from the default sound mixing setup. This is usefull if you want to create groups of sound channels, so that you can devide them for different tasks. When you indicate a 0, all reservations are removed. The channels are reserved starting from channel 0 to num_channels -1. Normally SDL_mixer starts without any channels reserved.


Parameters

INT num_channels - The number of channels to reserve.

Returns

INT : Status.

>0 - The number of reserved channels.
-1 - Error: sound inactive.



Sound Functions
Fade_music_in()Fade_music_off()Is_playing_song()Is_playing_wav()Load_song()Load_wav()Pause_song()Pause_wav()Play_song()Play_wav()Reserve_channels()Resume_song()Resume_wav()Reverse_stereo()Set_channel_volume()Set_distance()Set_music_position()Set_panning()Set_position()Set_song_volume()Set_Wav_Volume()Sound_close()Sound_init()Stop_song()Stop_wav()Unload_song()Unload_wav()