Repository navigation
fix(demux): repair missing composition offsets across a seek onto an open GOP (#699) - #707
Merged
Merged
Conversation
…open GOP (#699) Two defects behind the software host's resume reading decode order on HEVC MP4s without ctts (reported on #699 after 7.27.3): - The repair verdict was reached at the first read. The software host seeks to its resume position before that read, so the sample started on the landing CRA, whose picture order is not 0, and the classifier refused. A seek before the first read now settles the verdict at the head first. - After any seek the rewriter anchored the landing keyframe as the first picture displayed. An open GOP's CRA is displayed after the leading pictures decoded behind it, so the axis sat one slot early per leading picture and B pictures fell below their decode time and went out untouched. The session now holds from the landing to the first trailing picture, counts the leading pictures, and anchors with that count. Twin fixture with a CRA and four RASL pictures at frame 30; each half fails the new tests without the other. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01WJcXkGQrMiBPixVEFTSBJS
4 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow-up to #699 / 7.27.3, from the device report in #699 (software-path resume onto a CRA left in decode order).
1. Verdict before the first seek.
Demuxerarmed the #409 repair at the first read.SoftwarePlaybackHostseeks to its resume position before reading, so the sample began on the landing CRA (picture order != 0) andclassifyreturnedinconclusive. Every demuxer seek now goes throughnoteCompositionRepairSeekLocked(), which settles the verdict at the head first when nothing has been read yet. The held head sample is dropped by the existingnoteSeek().2. Leading pictures at the landing. The rewriter re-anchored a post-seek keyframe as if it were the first picture displayed. A CRA with leading pictures is displayed
Lslots after its decode slot, so the whole axis satLslots early, and B pictures that then fell below their own decode time went out untouched (duplicate PTS). This affects every seek on such files, native path included. After a seek the session now holds packets (all streams, bounded by the existing ceilings) from the landing keyframe to the first trailing picture, countsL, and anchors with it.Tests.
CompositionOffsetRepairFirstSeekTests: libx265 open-GOP twin (CRA + 4 RASL at frame 30,setts=pts=DTSfor the broken twin). Resume-shaped seek and mid-playback seek both match the healthy twin packet for packet. Without part 1 the resume test fails; without part 2 both fail. Fullswift testgreen.🤖 Generated with Claude Code
https://claude.ai/code/session_01WJcXkGQrMiBPixVEFTSBJS