Logo Search packages:      
Sourcecode: scummvm version File versions  Download package

bool Audio::Mixer::isSoundHandleActive ( SoundHandle  handle  ) 

Check if a sound with the given handle is active.

handle sound to query
true if the sound is active

Definition at line 337 of file mixer.cpp.

References Audio::Channel::_handle, and Audio::SoundHandle::_val.

Referenced by Kyra::SoundDigital::isPlaying(), Kyra::Sound::voiceIsPlaying(), and Kyra::Sound::voiceStop().

      Common::StackLock lock(_mutex);
      const int index = handle._val % NUM_CHANNELS;
      return _channels[index] && _channels[index]->_handle._val == handle._val;

Generated by  Doxygen 1.6.0   Back to index