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

virtual void Audio::Mixer::playStream ( SoundType  type,
SoundHandle handle,
AudioStream stream,
int  id = -1,
byte  volume = kMaxChannelVolume,
int8  balance = 0,
DisposeAfterUse::Flag  autofreeStream = DisposeAfterUse::YES,
bool  permanent = false,
bool  reverseStereo = false 
) [pure virtual]

Start playing the given audio stream.

Note that the sound id assigned below is unique. At most one stream with a given id can play at any given time. Trying to play a sound with an id that is already in use causes the new sound to be not played.

typethe type (voice/sfx/music) of the stream
handlea SoundHandle which can be used to reference and control the stream via suitable mixer methods
streamthe actual AudioStream to be played
ida unique id assigned to this stream
volumethe volume with which to play the sound, ranging from 0 to 255
balancethe balance with which to play the sound, ranging from -128 to 127
autofreeStreama flag indicating whether the stream should be freed after playback finished
permanenta flag indicating whether a plain stopAll call should not stop this particular stream
reverseStereoa flag indicating whether left and right channels shall be swapped

Implemented in Audio::MixerImpl.

Referenced by Graphics::SmackerDecoder::decodeNextFrame(), Graphics::AviDecoder::load(), Sci::MidiDriver_AmigaMac::open(), Queen::AdLibMidiDriver::open(), MidiDriver_ADLIB::open(), Sword2::Sound::playCompSpeech(), Sword2::Sound::playMovieSound(), Kyra::SoundDigital::playSound(), Kyra::SoundAmiga::playSoundEffect(), Kyra::SoundAmiga::playTrack(), TeenAgent::TeenAgentEngine::run(), and Kyra::SoundTownsPC98_v2::voicePlay().

Here is the caller graph for this function:

Generated by  Doxygen 1.6.0   Back to index