From a467247e6ed972e0a13bf26af07811dda55bd69a Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Wed, 22 Feb 2006 13:26:13 +0000 Subject: Fix bug #1386333: "FT DEMO: assertion triggered when playing movie". svn-id: r20812 --- engines/scumm/smush/smush_player.cpp | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'engines') diff --git a/engines/scumm/smush/smush_player.cpp b/engines/scumm/smush/smush_player.cpp index 740aeb0239..2a3a4527aa 100644 --- a/engines/scumm/smush/smush_player.cpp +++ b/engines/scumm/smush/smush_player.cpp @@ -1329,9 +1329,19 @@ void SmushPlayer::play(const char *filename, int32 offset, int32 startFrame) { } if (_updateNeeded) { uint32 end_time, start_time; + int w = _width, h = _height; start_time = _vm->_system->getMillis(); - _vm->_system->copyRectToScreen(_dst, _width, 0, 0, _width, _height); + + // Workaround for bug #1386333: "FT DEMO: assertion triggered + // when playing movie". Some frames there are 384 x 224 + if (w > _vm->_screenWidth) + w = _vm->_screenWidth; + + if (h > _vm->_screenHeight) + h = _vm->_screenHeight; + + _vm->_system->copyRectToScreen(_dst, _width, 0, 0, w, h); _vm->_system->updateScreen(); _updateNeeded = false; #ifdef _WIN32_WCE -- cgit v1.2.3