22 #ifndef VIDEO_DECODER_H 23 #define VIDEO_DECODER_H 25 #include "audio/mixer.h" 26 #include "audio/timestamp.h" 27 #include "common/array.h" 28 #include "common/path.h" 29 #include "common/rational.h" 30 #include "common/str.h" 31 #include "graphics/pixelformat.h" 32 #include "image/codec-options.h" 36 class RewindableAudioStream;
37 class SeekableAudioStream;
41 class SeekableReadStream;
96 bool isVideoLoaded()
const;
143 bool isPlaying()
const;
149 virtual bool isRewindable()
const;
159 virtual bool rewind();
165 virtual bool isSeekable()
const;
186 virtual bool seekToFrame(uint frame);
199 void pauseVideo(
bool pause);
224 void setEndFrame(uint frame);
234 void resetStartTime();
245 bool endOfVideo()
const;
251 int getCurFrame()
const;
257 uint32 getFrameCount()
const;
273 uint32 getTime()
const;
289 virtual uint16 getWidth()
const;
300 virtual uint16 getHeight()
const;
326 const byte *getPalette();
337 void delayMillis(uint msecs);
342 uint32 getTimeToNextFrame()
const;
349 bool needsUpdate()
const;
378 bool setReverse(
bool reverse);
397 bool setDitheringPalette(
const byte *palette);
413 virtual void setVideoCodecAccuracy(Image::CodecAccuracy accuracy);
432 void setVolume(byte volume);
447 void setBalance(int8 balance);
481 bool setAudioTrack(
int index);
486 uint getAudioTrackCount()
const;
510 virtual TrackType getTrackType()
const = 0;
515 virtual bool endOfTrack()
const = 0;
523 virtual bool isRewindable()
const;
533 virtual bool rewind();
550 void pause(
bool shouldPause);
583 virtual bool endOfTrack()
const;
588 virtual uint16 getWidth()
const = 0;
593 virtual uint16 getHeight()
const = 0;
615 virtual int getCurFrame()
const = 0;
630 virtual uint32 getNextFrameStartTime()
const = 0;
691 uint32 getNextFrameStartTime()
const;
718 virtual bool endOfTrack()
const;
740 void setVolume(byte volume);
750 void setRate(uint32 rate);
766 void setBalance(int8 balance);
782 uint32 getRunningTime()
const;
787 void setMute(
bool mute);
790 void pauseIntern(
bool shouldPause);
877 void resetPauseStartTime();
896 void addTrack(
Track *track,
bool isExternal =
false);
910 Track *getTrack(uint track);
917 const Track *getTrack(uint track)
const;
925 bool endOfVideoTracks()
const;
953 void eraseTrack(
Track *track);
986 TrackList _internalTracks;
987 TrackList _externalTracks;
996 mutable bool _dirtyPalette;
997 const byte *_palette;
1001 bool _canSetDefaultFormat;
1009 bool hasFramesLeft()
const;
1010 bool hasAudio()
const;
1017 Image::CodecAccuracy _videoCodecAccuracy;
1021 uint32 _pauseStartTime;
virtual AudioTrack * getAudioTrack(int index)
Definition: video_decoder.h:981
byte getVolume() const
Definition: video_decoder.h:423
TrackListIterator getTrackListBegin()
Definition: video_decoder.h:943
Definition: video_decoder.h:493
byte getVolume() const
Definition: video_decoder.h:735
virtual bool hasDirtyPalette() const
Definition: video_decoder.h:645
int8 getBalance() const
Definition: video_decoder.h:438
Definition: video_decoder.h:686
Common::Array< Track * > TrackList
Definition: video_decoder.h:937
virtual bool useAudioSync() const
Definition: video_decoder.h:903
virtual int getFrameCount() const
Definition: video_decoder.h:624
Definition: video_decoder.h:711
T * iterator
Definition: array.h:54
Definition: timestamp.h:83
virtual bool supportsAudioTrackSwitching() const
Definition: video_decoder.h:971
virtual bool isSeekable() const
Definition: video_decoder.h:538
Definition: rational.h:40
Definition: video_decoder.h:856
Audio::Timestamp getEndTime() const
Definition: video_decoder.h:229
Definition: audiostream.h:212
virtual bool setReverse(bool reverse)
Definition: video_decoder.h:663
uint32 getRate() const
Definition: video_decoder.h:745
void setSoundType(Audio::Mixer::SoundType soundType)
Definition: video_decoder.h:776
SoundType
Definition: mixer.h:62
TrackType getTrackType() const
Definition: video_decoder.h:582
Definition: video_decoder.h:53
virtual void pauseIntern(bool shouldPause)
Definition: video_decoder.h:568
bool isPaused() const
Definition: video_decoder.h:555
Definition: algorithm.h:29
Definition: formatinfo.h:28
TrackType
Definition: video_decoder.h:501
Definition: audiostream.h:50
bool hasDirtyPalette() const
Definition: video_decoder.h:331
virtual void setDither(const byte *palette)
Definition: video_decoder.h:678
virtual void setCodecAccuracy(Image::CodecAccuracy accuracy)
Definition: video_decoder.h:608
Definition: video_decoder.h:810
virtual bool isReversed() const
Definition: video_decoder.h:668
bool isRewindable() const
Definition: video_decoder.h:815
TrackListIterator getTrackListEnd()
Definition: video_decoder.h:948
bool isSeekable() const
Definition: video_decoder.h:837
Definition: audiostream.h:109
virtual bool seek(const Audio::Timestamp &time)
Definition: video_decoder.h:545
virtual bool canDither() const
Definition: video_decoder.h:673
int8 getBalance() const
Definition: video_decoder.h:761
Audio::Mixer::SoundType getSoundType() const
Definition: video_decoder.h:771
virtual bool setOutputPixelFormat(const Graphics::PixelFormat &format)
Definition: video_decoder.h:603
virtual void readNextPacket()
Definition: video_decoder.h:886
bool isPaused() const
Definition: video_decoder.h:204
TrackType getTrackType() const
Definition: video_decoder.h:716
Audio::SeekableAudioStream * getSeekableAudioStream() const
Definition: video_decoder.h:871
Definition: avi_frames.h:36
Definition: video_decoder.h:832
Common::Rational getRate() const
Definition: video_decoder.h:133
virtual const byte * getPalette() const
Definition: video_decoder.h:640
Definition: video_decoder.h:577