diff options
author | Max Horn | 2009-03-04 08:04:28 +0000 |
---|---|---|
committer | Max Horn | 2009-03-04 08:04:28 +0000 |
commit | 2a7eef19c0722752200713d3834f53637a2ecd5e (patch) | |
tree | 8efc944cf3aef33a01e9a56f38ca8f4e01a69bdf /engines/sci/sfx/player | |
parent | dbb59ce3a1a7e3981e7a1193bdca753759bd2141 (diff) | |
download | scummvm-rg350-2a7eef19c0722752200713d3834f53637a2ecd5e.tar.gz scummvm-rg350-2a7eef19c0722752200713d3834f53637a2ecd5e.tar.bz2 scummvm-rg350-2a7eef19c0722752200713d3834f53637a2ecd5e.zip |
SCI: Removed unused FEED_MODE_DEAD, extended FIXME comment for FEED_MODE_RESTART
svn-id: r39119
Diffstat (limited to 'engines/sci/sfx/player')
-rw-r--r-- | engines/sci/sfx/player/polled.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/engines/sci/sfx/player/polled.cpp b/engines/sci/sfx/player/polled.cpp index ad00825c72..58322f4aa7 100644 --- a/engines/sci/sfx/player/polled.cpp +++ b/engines/sci/sfx/player/polled.cpp @@ -57,7 +57,6 @@ protected: enum FeedMode { FEED_MODE_ALIVE, FEED_MODE_IDLE, - FEED_MODE_DEAD, FEED_MODE_RESTART }; @@ -90,7 +89,7 @@ public: virtual bool isStereo() const { return _conf.stereo; } virtual int getRate() const { return _conf.rate; } - virtual bool endOfData() const { return _mode == FEED_MODE_DEAD; } + virtual bool endOfData() const { return false; } protected: void queryTimestamp(); @@ -121,7 +120,9 @@ void PolledPlayerAudioStream::queryTimestamp() { // I may have added this as a workaround for not being able to come // up with a convenient way to implement mixer->pause() and mixer->resume() // on DC." - // That makes some sense. + // That makes some sense. However, maybe it is sufficient to just + // go to FEED_MODE_ALIVE ? With the current code, the player will + // permanently get stuck in FEED_MODE_RESTART if we ever get here... _mode = FEED_MODE_RESTART; _time = Audio::Timestamp(g_system->getMillis(), _conf.rate); _gap = stamp.frameDiff(_time); @@ -163,7 +164,7 @@ int PolledPlayerAudioStream::readBuffer(int16 *buffer, const int numSamples) { if (_mode == FEED_MODE_IDLE) queryTimestamp(); - if (_mode == FEED_MODE_IDLE || _mode == FEED_MODE_DEAD) { + if (_mode == FEED_MODE_IDLE) { memset(buf_pos, 0, frames_left * channels * 2); _time = _time.addFrames(frames_left); |