aboutsummaryrefslogtreecommitdiff
path: root/engines/titanic/support
diff options
context:
space:
mode:
authorPaul Gilbert2016-10-03 22:11:48 -0400
committerPaul Gilbert2016-10-03 22:11:48 -0400
commitad355ec79d49bfe0a2c2ce329f9bf691d46a1950 (patch)
treed72dccf428817bad2b4732963202feb815d3e687 /engines/titanic/support
parentab0bd3e2275bd08b62fc0b1aebb1e80afbcc0642 (diff)
downloadscummvm-rg350-ad355ec79d49bfe0a2c2ce329f9bf691d46a1950.tar.gz
scummvm-rg350-ad355ec79d49bfe0a2c2ce329f9bf691d46a1950.tar.bz2
scummvm-rg350-ad355ec79d49bfe0a2c2ce329f9bf691d46a1950.zip
TITANIC: Fix playback of single-stream videos
Diffstat (limited to 'engines/titanic/support')
-rw-r--r--engines/titanic/support/avi_surface.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/engines/titanic/support/avi_surface.cpp b/engines/titanic/support/avi_surface.cpp
index 38f44271f4..5b11c7799e 100644
--- a/engines/titanic/support/avi_surface.cpp
+++ b/engines/titanic/support/avi_surface.cpp
@@ -221,7 +221,8 @@ void AVISurface::setupDecompressor() {
_decoder->getVideoTrack(idx).getPixelFormat());
bool flag = false;
- if (idx == 0 && _videoSurface) {
+ if (idx == 0 && _videoSurface &&
+ _videoSurface->getPitch() == _movieFrameSurface[idx]->pitch) {
const Graphics::PixelFormat &ff = _decoder->getVideoTrack(0).getPixelFormat();
const int vDepth = _videoSurface->getPixelDepth();
@@ -293,11 +294,10 @@ bool AVISurface::renderFrame() {
if (!_framePixels) {
if (_videoSurface->lock()) {
- if (_streamCount == 1) {
- // Original seems to call a stubbed empty method here.
- // Likely this form of blitting to surface wasn't needed
- }
-
+ // Blit the frame directly to the video surface
+ assert(_streamCount == 1);
+ _videoSurface->blitFrom(Point(0, 0), &_movieFrameSurface[0]->rawSurface());
+
_videoSurface->unlock();
}
} else {