[Scummvm-git-logs] scummvm master -> c88d19dc443c7d4d218b32dfc7bfdf91f57efdbb
lephilousophe
noreply at scummvm.org
Sun Feb 1 10:28:31 UTC 2026
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://api.github.com/repos/scummvm/scummvm .
Summary:
c88d19dc44 VIDEO: Fix seeking to a keyframe in BINK videos
Commit: c88d19dc443c7d4d218b32dfc7bfdf91f57efdbb
https://github.com/scummvm/scummvm/commit/c88d19dc443c7d4d218b32dfc7bfdf91f57efdbb
Author: antoniou79 (a.antoniou79 at gmail.com)
Date: 2026-02-01T11:28:27+01:00
Commit Message:
VIDEO: Fix seeking to a keyframe in BINK videos
When seeking to a keyframe, that is not the first frame of the video, audio should not break or desync
The special code in BinkDecoder::BinkAudioTrack::seek() for fixing audio underrun should apply in the case of key frames as well
A test case for this issue can be constructed in MYST3, if the video at the start (10002), when Catherine is sitting on the bench with the baby and talks to the stranger, is set to start at frame 1 instead of 2.
Changed paths:
video/bink_decoder.cpp
diff --git a/video/bink_decoder.cpp b/video/bink_decoder.cpp
index abb979154e7..07d635fd059 100644
--- a/video/bink_decoder.cpp
+++ b/video/bink_decoder.cpp
@@ -345,17 +345,17 @@ bool BinkDecoder::seekIntern(const Audio::Timestamp &time) {
// Adjust the video track to use for seeking
findNextVideoTrack();
- if (frame == keyFrame) {
- // We're already good, no need to go further
- return true;
- }
-
// Seek the audio tracks
for (uint32 i = 0; i < _audioTracks.size(); i++) {
BinkAudioTrack *audioTrack = (BinkAudioTrack *)getTrack(i + 1);
audioTrack->seek(videoTrack->getFrameTime(keyFrame));
}
+ if (frame == keyFrame) {
+ // We're already good, no need to go further
+ return true;
+ }
+
while (getCurFrame() < (int32)frame - 1)
decodeNextFrame();
More information about the Scummvm-git-logs
mailing list