aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorSven Hesse2010-08-08 00:44:33 +0000
committerSven Hesse2010-08-08 00:44:33 +0000
commit2296aad042aad1c9983b4a9bf2e187912c361407 (patch)
tree15951e4b16b520be3bc28376fa045a155bad38bb /engines
parent2bcc02a27a5261fab4d769e3160ff490573a6be1 (diff)
downloadscummvm-rg350-2296aad042aad1c9983b4a9bf2e187912c361407.tar.gz
scummvm-rg350-2296aad042aad1c9983b4a9bf2e187912c361407.tar.bz2
scummvm-rg350-2296aad042aad1c9983b4a9bf2e187912c361407.zip
VIDEO/GOB: Fix IMD playing
Fix IMD playing for some fringe cases, especially when seeking beforehand. svn-id: r51871
Diffstat (limited to 'engines')
-rw-r--r--engines/gob/mult_v2.cpp9
-rw-r--r--engines/gob/videoplayer.h4
2 files changed, 9 insertions, 4 deletions
diff --git a/engines/gob/mult_v2.cpp b/engines/gob/mult_v2.cpp
index 8c58183b3c..d9e94199c3 100644
--- a/engines/gob/mult_v2.cpp
+++ b/engines/gob/mult_v2.cpp
@@ -1129,6 +1129,8 @@ void Mult_v2::playImd(const char *imdFile, Mult::Mult_ImdKey &key, int16 dir,
return;
}
+ _vm->_vidPlayer->evaluateFlags(props);
+
int slot;
if ((slot = _vm->_vidPlayer->openVideo(true, imdFile, props)) < 0)
return;
@@ -1141,13 +1143,16 @@ void Mult_v2::playImd(const char *imdFile, Mult::Mult_ImdKey &key, int16 dir,
uint32 baseFrame = startFrame % (props.lastFrame - props.palFrame + 1);
+ props.endFrame = props.lastFrame;
props.startFrame = baseFrame + props.palFrame;
props.lastFrame = baseFrame + props.palFrame;
+ props.flags &= 0x7F;
+
debugC(2, kDebugVideo, "Playing mult video \"%s\" @ %d+%d, frame %d, "
- "paletteCmd %d (%d - %d), flags %X", imdFile,
+ "paletteCmd %d (%d - %d; %d), flags %X", imdFile,
props.x, props.y, props.startFrame,
- props.palCmd, props.palStart, props.palEnd, props.flags);
+ props.palCmd, props.palStart, props.palEnd, props.endFrame, props.flags);
_vm->_vidPlayer->play(slot, props);
}
diff --git a/engines/gob/videoplayer.h b/engines/gob/videoplayer.h
index f1245bca48..1b60e7ffd6 100644
--- a/engines/gob/videoplayer.h
+++ b/engines/gob/videoplayer.h
@@ -79,8 +79,8 @@ public:
int16 breakKey; ///< Keycode of the break/abort key.
uint16 palCmd; ///< Palette command.
- uint16 palStart; ///< Palette entry to start with.
- uint16 palEnd; ///< Palette entry to end at.
+ int16 palStart; ///< Palette entry to start with.
+ int16 palEnd; ///< Palette entry to end at.
int32 palFrame; ///< Frame to apply the palette command at.
bool fade; ///< Fade in?