0
0

Either I’m doing something wrong (likely) or ChannelGroup->setVolume appears to be doing nothing. Here’s an edited example of my test case:
[code:1ew621gj]
system->playSound( FMOD_CHANNEL_FREE, aSnd, true, &channel );

FMOD::DSP *channelDSPHead;
FMOD::DSP *wetChannelGroupDSPHead;
channel->getDSPHead( &channelDSPHead );
channelDSPHead->disconnectAll( false, true );
wetChannelGroupDSPHead->addInput( channelDSPHead, 0 );

// so now the only connection channel has is through wetChannelGroup

wetChannelGroup->setVolume( 0.0 );
channel->setPaused( false ); // sound is still audible
[/code:1ew621gj]

  • You must to post comments
0
0

First thing I notice is that wetChannelGroupDSPHead is unitialized. The addInput function should be returning FMOD_ERR_INVALID_HANDLE. There could be some other invalid handles which may explain the behaviour you’re seeing. Make sure that you check the FMOD_RESULT returned from every FMOD function call. :)

  • You must to post comments
0
0

Sorry, should have made it clear: wetChannelGroupDSPHead has been initialised elsewhere, and errorchecking everything doesn’t throw up anything unexpected. This is more of a quick illustration of my problem, rather than actual code 😉

  • You must to post comments
0
0

Please post the actual code, that will help us locate the real problem. I can assure you that ChannelGroup::setVolume behaves as expected with normal usage.

  • You must to post comments
0
0

Hm. Have solved the problem using DSPConnection->setMix(). Sorry, should think harder before posting. Thanks for the reply.

  • You must to post comments
0
0

Glad to hear it’s all working for you. DSPConnection::setMix is a good way to set the volume when you’re working at the DSP level.

  • You must to post comments
Showing 5 results
Your Answer

Please first to submit.