30 #ifndef VIDEO_QT_DECODER_H 31 #define VIDEO_QT_DECODER_H 33 #include "audio/decoders/quicktime_intern.h" 34 #include "common/keyboard.h" 35 #include "common/scummsys.h" 37 #include "graphics/palette.h" 38 #include "graphics/transform_tools.h" 40 #include "video/video_decoder.h" 79 void enableEditListBoundsCheckQuirk(
bool enable) { _enableEditListBoundsCheckQuirk = enable; }
85 void setTargetSize(uint16 w, uint16 h);
86 void setOrigin(
int left,
int top) { _origin =
Common::Point(left, top); }
88 void handleMouseMove(int16 x, int16 y);
89 void handleMouseButton(
bool isDown, int16 x = -1, int16 y = -1,
bool repeat =
false);
95 float getPanAngle()
const {
return _panAngle; }
96 void setPanAngle(
float panAngle);
97 float getTiltAngle()
const {
return _tiltAngle; }
98 void setTiltAngle(
float tiltAngle);
99 float getFOV()
const {
return _fov; }
100 float getHFOV()
const {
return _hfov; }
101 bool setFOV(
float fov);
102 int getCurrentNodeID() {
return _currentSample == -1 ? 0 : _panoTrack->panoSamples[_currentSample].hdr.nodeID; }
105 int getCurrentRow() {
return _nextVideoTrack->getCurFrame() / _nav.columns; }
106 void setCurrentRow(
int row);
107 int getCurrentColumn() {
return _nextVideoTrack->getCurFrame() % _nav.columns; }
108 void setCurrentColumn(
int column);
110 int getZoomState() {
return _zoomState; }
112 const PanoHotSpot *getRolloverHotspot() {
return _rolloverHotspot; }
113 int getRolloverHotspotID() {
return _rolloverHotspotID; }
114 const PanoHotSpot *getClickedHotspot() {
return _clickedHotspot; }
115 int getClickedHotspotID() {
return _clickedHotspotID; }
120 void setClickedHotSpot(
int id);
126 bool isVR()
const {
return _isVR; }
127 QTVRType getQTVRType()
const {
return _qtvrType; }
129 int getWarpMode()
const {
return _warpMode; }
130 void setWarpMode(
int warpMode);
131 float getQuality()
const {
return _quality; }
132 void setQuality(
float quality);
133 Common::String getTransitionMode()
const {
return _transitionMode == kTransitionModeNormal ?
"normal" :
"swing"; }
135 float getTransitionSpeed()
const {
return _transitionSpeed; }
136 void setTransitionSpeed(
float speed);
140 void renderHotspots(
bool mode);
158 NodeData getNodeData(uint32 nodeID);
159 void goToNode(uint32 nodeID);
168 void updateAudioBuffer();
170 void handleObjectMouseMove(int16 x, int16 y);
171 void handleObjectMouseButton(
bool isDown, int16 x, int16 y,
bool repeat);
172 void handlePanoMouseMove(int16 x, int16 y);
173 void handlePanoMouseButton(
bool isDown, int16 x, int16 y,
bool repeat);
180 void lookupHotspot(int16 x, int16 y);
181 void updateQTVRCursor(int16 x, int16 y);
182 void setCursor(
int curId);
183 void cleanupCursors();
184 void computeInteractivityZones();
186 uint16 _width, _height;
194 int _currentSample = -1;
196 bool _isMouseButtonDown =
false;
199 bool _isKeyDown =
false;
209 kTransitionModeNormal,
210 kTransitionModeSwing,
213 kUpdateModeUpdateBoth,
214 kUpdateModeOffscreenOnly,
215 kUpdateModeFromOffscreen,
216 kUpdateModeDirectToScreen,
222 int _currentQTVRCursor = -1;
225 int _cursorDirMap[256];
230 float _quality = 0.0f;
231 int _transitionMode = kTransitionModeNormal;
232 float _transitionSpeed = 1.0f;
233 int _updateMode = kUpdateModeNormal;
235 float _panAngle = 0.0f;
236 float _tiltAngle = 0.0f;
239 int _zoomState = kZoomNone;
240 bool _repeatTimerActive =
false;
243 int _rolloverHotspotID = 0;
245 int _clickedHotspotID = 0;
246 bool _renderHotspots =
false;
252 bool _enableEditListBoundsCheckQuirk;
262 uint16 _bitsPerSample;
264 uint16 _colorTableId;
294 int32 _loResSceneTrackID;
295 byte _reserved3[4 * 6];
296 int32 _hotSpotTrackID;
297 byte _reserved4[4 * 9];
311 int16 _sceneNumFramesX;
312 int16 _sceneNumFramesY;
313 int16 _sceneColorDepth;
319 int16 _hotSpotNumFramesX;
320 int16 _hotSpotNumFramesY;
321 int16 _hotSpotColorDepth;
330 ~VideoTrackHandler();
332 bool endOfTrack()
const;
333 bool isSeekable()
const {
return true; }
337 uint16 getWidth()
const;
338 uint16 getHeight()
const;
341 int getCurFrame()
const {
return _curFrame; }
342 void setCurFrame(int32 curFrame) { _curFrame = curFrame; }
343 int getFrameCount()
const;
344 uint32 getNextFrameStartTime()
const;
347 const byte *getPalette()
const;
348 bool hasDirtyPalette()
const {
return _dirtyPalette; }
349 bool setReverse(
bool reverse);
350 bool isReversed()
const {
return _reversed; }
351 bool canDither()
const;
352 void setDither(
const byte *palette);
364 int32 _delayedFrameToBufferTo;
365 uint32 _nextFrameStartTime;
367 int32 _durationOverride;
368 const byte *_curPalette;
369 mutable bool _dirtyPalette;
373 uint32 getCurFrameDuration();
374 uint32 findKeyFrame(uint32 frame)
const;
375 bool isEmptyEdit()
const;
376 void enterNewEditListEntry(
bool bufferFrames,
bool intializingTrack =
false);
377 uint32 getRateAdjustedFrameTime()
const;
378 uint32 getCurEditTimeOffset()
const;
379 uint32 getCurEditTrackDuration()
const;
380 bool atLastEdit()
const;
381 bool endOfCurEdit()
const;
382 void checkEditListBounds();
390 bool endOfTrack()
const {
return false; }
391 uint16 getWidth()
const;
392 uint16 getHeight()
const;
393 int getCurFrame()
const {
return 1; }
394 uint32 getNextFrameStartTime()
const {
return 0; }
402 void constructPanorama();
407 void setDirty() { _dirty =
true; }
413 void projectPanorama(uint8 scaleFactor,
float fov,
float hfov,
float panAngle,
float tiltAngle);
414 void swingTransitionHandler();
431 uint8 _upscaleLevel = 0;
436 float _currentFOV = 0;
437 float _currentHFOV = 0;
438 float _currentPanAngle = 0;
439 float _currentTiltAngle = 0;
442 bool _isPanoConstructed;
Definition: quicktime_intern.h:65
Definition: quicktime.h:265
Definition: qt_decoder.h:66
Definition: quicktime.h:134
Definition: timestamp.h:83
Definition: rational.h:40
Definition: quicktime.h:201
Definition: quicktime.h:300
Definition: audiostream.h:212
Definition: archive.h:141
Definition: quicktime_intern.h:47
Definition: atari-cursor.h:35
Definition: video_decoder.h:53
Audio::Timestamp getDuration() const
Definition: qt_decoder.h:77
Definition: algorithm.h:29
Definition: formatinfo.h:28
uint16 getWidth() const
Definition: qt_decoder.h:74
Definition: transform_tools.h:32
Definition: qt_decoder.h:142
Definition: keyboard.h:294
Simple class for handling a palette data.
Definition: palette.h:55
Definition: avi_frames.h:36
Definition: video_decoder.h:844
Definition: movie_decoder.h:32
uint16 getHeight() const
Definition: qt_decoder.h:75
Definition: video_decoder.h:589