Tao.Sdl SDK Documentation |
|
SdlMixer.Mix_GroupChannels Method
Assign several consecutive channels to a group
[Visual Basic]
Public Shared Function Mix_GroupChannels( _
ByVal
from As
Integer, _
ByVal
to As
Integer, _
ByVal
tag As
Integer _
) As
Integer
[C#]
public static
int Mix_GroupChannels(
int from,
int to,
int tag);
Parameters
-
from
- First Channel number of channels to assign tag to. Must be less or equal to to.
-
to
- Last Channel number of channels to assign tag to. Must be greater or equal to from.
-
tag
- A group number. Any positive numbers (including zero). -1 is the default group. Use -1 to remove a group tag essentially.
Return Value
The number of tagged channels on success. If that number is less than to-from+1 then some channels were no tagged because they didn't exist.
Remarks
Add channels starting at from up through to to group tag, or reset it's group to the default group tag (-1).
Binds to C-function in SDL_mixer.h
int Mix_GroupChannels(int from, int to, int tag)
Example
// add channels 0 through 7 to group 1
if(Mix_GroupChannels(0,7,1)!=8)
{
// some bad channels, apparently some channels aren't allocated
}
See Also
SdlMixer Class | Tao.Sdl Namespace | Mix_GroupChannel | Mix_AllocateChannels