diff options
Diffstat (limited to 'video/avi_decoder.h')
-rw-r--r-- | video/avi_decoder.h | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/video/avi_decoder.h b/video/avi_decoder.h index 4461e537c5..8941ff4e75 100644 --- a/video/avi_decoder.h +++ b/video/avi_decoder.h @@ -215,7 +215,9 @@ protected: virtual void queueSound(Common::SeekableReadStream *stream); Audio::Mixer::SoundType getSoundType() const { return _soundType; } void skipAudio(const Audio::Timestamp &time, const Audio::Timestamp &frameTime); - void resetStream(); + virtual void resetStream(); + uint32 getCurChunk() const { return _curChunk; } + void setCurChunk(uint32 chunk) { _curChunk = chunk; } bool isRewindable() const { return true; } bool rewind(); @@ -238,6 +240,15 @@ protected: Audio::Mixer::SoundType _soundType; Audio::QueuingAudioStream *_audStream; Audio::QueuingAudioStream *createAudioStream(); + uint32 _curChunk; + }; + + struct TrackStatus { + TrackStatus(); + + Track *track; + uint32 index; + uint32 chunkSearchOffset; }; AVIHeader _header; @@ -260,9 +271,12 @@ protected: void handleStreamHeader(uint32 size); uint16 getStreamType(uint32 tag) const { return tag & 0xFFFF; } byte getStreamIndex(uint32 tag) const; - void forceVideoEnd(); void checkTruemotion1(); + void handleNextPacket(TrackStatus& status); + bool shouldQueueAudio(TrackStatus& status); + Common::Array<TrackStatus> _videoTracks, _audioTracks; + public: virtual AVIAudioTrack *createAudioTrack(AVIStreamHeader sHeader, PCMWaveFormat wvInfo); }; |