diff options
author | Sven Hesse | 2008-05-26 05:17:21 +0000 |
---|---|---|
committer | Sven Hesse | 2008-05-26 05:17:21 +0000 |
commit | d94bfc66ad903b3c2cd677e1d481bca69f70eb12 (patch) | |
tree | 425615077b09f97b2cf33d640cad35c91d88bb19 /engines/gob | |
parent | 2862a30dac114fd728e80669a15f315fe21bc8d6 (diff) | |
download | scummvm-rg350-d94bfc66ad903b3c2cd677e1d481bca69f70eb12.tar.gz scummvm-rg350-d94bfc66ad903b3c2cd677e1d481bca69f70eb12.tar.bz2 scummvm-rg350-d94bfc66ad903b3c2cd677e1d481bca69f70eb12.zip |
Ooops, made frame skipping for A/V sync correction work again (instead of locking up)
svn-id: r32276
Diffstat (limited to 'engines/gob')
-rw-r--r-- | engines/gob/coktelvideo.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/engines/gob/coktelvideo.cpp b/engines/gob/coktelvideo.cpp index be639fae9f..415790e67b 100644 --- a/engines/gob/coktelvideo.cpp +++ b/engines/gob/coktelvideo.cpp @@ -326,11 +326,11 @@ void Imd::waitEndFrame() { return; if (_skipFrames == 0) { - int32 waitTime = ((_curFrame * _soundSliceLength) - - ((g_system->getMillis() - _soundStartTime) << 16)) >> 16; + int32 waitTime = (int16) (((_curFrame * _soundSliceLength) - + ((g_system->getMillis() - _soundStartTime) << 16)) >> 16); if (waitTime < 0) { - _skipFrames = -waitTime / _soundSliceLength; + _skipFrames = -waitTime / (_soundSliceLength >> 16); warning("Video A/V sync broken, skipping %d frame(s)", _skipFrames + 1); } else if (waitTime > 0) g_system->delayMillis(waitTime); |