Music and Sound Channels
by Nikos Beck · in Technical Issues · 10/01/2008 (9:00 am) · 2 replies
I have two audio descriptions: Music and Sound.
new AudioDescription(Music)
{
Type = $GuiAudioType; //defined in the engine
IsLooping = true;
Is3D = false;
};
new AudioDescription(Sound)
{
Type = $GuiAudioType; //defined in the engine
IsLooping = false;
Is3D = false;
};
Right now they are both on channel zero. I can adjust the volume with
alxSetChannelVolume(0, 0.5); //50% volume on channel 0
...but everything is on channel zero. When I set the channel volume it does affect all currently playing sounds. How can I play audio on a particular channel. If I can keep music on channel zero and sound on channel one then I can adjust their volumes separately.
I haven't managed to find anything that would let me pick a channel. Any help would be greatly appreciated.
new AudioDescription(Music)
{
Type = $GuiAudioType; //defined in the engine
IsLooping = true;
Is3D = false;
};
new AudioDescription(Sound)
{
Type = $GuiAudioType; //defined in the engine
IsLooping = false;
Is3D = false;
};
Right now they are both on channel zero. I can adjust the volume with
alxSetChannelVolume(0, 0.5); //50% volume on channel 0
...but everything is on channel zero. When I set the channel volume it does affect all currently playing sounds. How can I play audio on a particular channel. If I can keep music on channel zero and sound on channel one then I can adjust their volumes separately.
I haven't managed to find anything that would let me pick a channel. Any help would be greatly appreciated.
About the author
#2
Oh my. Thank you so much. I was hoping it'd be that simple. I had no idea that $GuiAudioType was the variable I should be looking at. Thanks DALQ.
I tried it and it works exactly as I wanted.
10/01/2008 (1:59 pm)
*jaw dropped*Oh my. Thank you so much. I was hoping it'd be that simple. I had no idea that $GuiAudioType was the variable I should be looking at. Thanks DALQ.
I tried it and it works exactly as I wanted.
Torque 3D Owner DALO
Does this answer your question?