aboutsummaryrefslogtreecommitdiff
path: root/sword1
diff options
context:
space:
mode:
authorMax Horn2004-11-27 15:58:18 +0000
committerMax Horn2004-11-27 15:58:18 +0000
commitba74a8e7f657cf795046a5cf6a7ead701fd4194e (patch)
tree0d05c0dfa38e10542ca83ffeeb37ddd782c56ef7 /sword1
parentb78ac6a18b2cb851718ef84b04557f7fba8d399a (diff)
downloadscummvm-rg350-ba74a8e7f657cf795046a5cf6a7ead701fd4194e.tar.gz
scummvm-rg350-ba74a8e7f657cf795046a5cf6a7ead701fd4194e.tar.bz2
scummvm-rg350-ba74a8e7f657cf795046a5cf6a7ead701fd4194e.zip
Added some more mixer doxygen docs; cleaned up Mixer API a bit, removing some very specialised methods
svn-id: r15914
Diffstat (limited to 'sword1')
-rw-r--r--sword1/sound.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/sword1/sound.cpp b/sword1/sound.cpp
index 7438a876d2..c9b5806f5a 100644
--- a/sword1/sound.cpp
+++ b/sword1/sound.cpp
@@ -26,6 +26,9 @@
#include "sword1/logic.h"
#include "sword1/sword1.h"
+#include "sound/mp3.h"
+#include "sound/vorbis.h"
+
namespace Sword1 {
#define SOUND_SPEECH_ID 1
@@ -191,7 +194,7 @@ bool Sound::startSpeech(uint16 roomNo, uint16 localNo) {
#ifdef USE_MAD
else if (_cowMode == CowMp3) {
_cowFile.seek(index);
- _mixer->playMP3(&_speechHandle, &_cowFile, sampleSize, speechVol, speechPan, SOUND_SPEECH_ID);
+ _mixer->playInputStream(&_speechHandle, makeMP3Stream(&_cowFile, sampleSize), false, speechVol, speechPan, SOUND_SPEECH_ID);
// with compressed audio, we can't calculate the wave volume.
// so default to talking.
for (int cnt = 0; cnt < 480; cnt++)
@@ -202,7 +205,7 @@ bool Sound::startSpeech(uint16 roomNo, uint16 localNo) {
#ifdef USE_VORBIS
else if (_cowMode == CowVorbis) {
_cowFile.seek(index);
- _mixer->playVorbis(&_speechHandle, &_cowFile, sampleSize, speechVol, speechPan, SOUND_SPEECH_ID);
+ _mixer->playInputStream(&_speechHandle, makeVorbisStream(&_cowFile, sampleSize), false, speechVol, speechPan, SOUND_SPEECH_ID);
for (int cnt = 0; cnt < 480; cnt++)
_waveVolume[cnt] = true;
_waveVolPos = 0;