From dbb8ad9da18a4289071bec086f64b8e79f92fb19 Mon Sep 17 00:00:00 2001 From: Torbjörn Andersson Date: Mon, 16 Feb 2009 21:57:22 +0000 Subject: If the DXA cutscene audio fails to play for whatever reason (shouldn't happen in BS1 since all the cutscenes have an audio track), assume audio and video are in sync. svn-id: r38384 --- engines/sword1/animation.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/engines/sword1/animation.cpp b/engines/sword1/animation.cpp index 47997b6810..76e29394e6 100644 --- a/engines/sword1/animation.cpp +++ b/engines/sword1/animation.cpp @@ -236,6 +236,9 @@ int32 DXAPlayerWithSound::getAudioLag() { if (!_fileStream) return 0; + if (!_mixer->isSoundHandleActive(*_bgSoundHandle)) + return 0; + int32 frameDelay = getFrameDelay(); int32 videoTime = _videoInfo.currentFrame * frameDelay; int32 audioTime; -- cgit v1.2.3