Feature Request - setGain() for all sounds

liquidllama

08-03-2008 01:45:46

I have been using OgreAL for a school project, and it has done everything we need it to so far! Thanks so much for a great wrapper!

However, the way we designed our game, each character object holds references to the sounds that it uses, for easy access; but the SoundManager class I made to extend the OgreAL::SoundManager doesn't have any easy way to reference these sounds, unless I'm missing something.

Is there any easy way to setGain() on a sound without a pointer reference or any knowledge of its name? Basically I'm just looking to implement something like a masterVolume level, which would just set the gain of every sound loaded to whatever value is passed in.

Thanks so much in advance!

CaseyB

08-03-2008 10:27:48

The way to do this is to get the Listener and set the gain on that. This will effect all sounds and you can get a pointer to the Listener from the SoundManager.

liquidllama

08-03-2008 18:08:12

Ah! Thank you very much for the quick reply :) I knew there had to be an easier way to do it...