Repository navigation
Conversation
Convert empty edit durations from the movie timescale to the track timescale before applying composition offsets. Reject missing timescales and unrepresentable offsets instead of ignoring the edit. Add regression coverage for scale conversion and invalid values, and correct the bipbop sample table expectations to include its scaled empty edit. Fixes bug 2082877.
|
Thanks for the swift fix! Note that the segment_duration field is always in the movie timescale, regardless of if its empty or not, so the description might be a little misleading. The two relevant fields, from ISO/IEC 14496-12:
|
|
Sorry which description is a little misleading? Do we need to adjust a comment that I missed? Thanks for the report in any case. |
|
Oh, it was just a nit about the PR description: "Empty edit durations use the movie timescale" sounded like only the empty ones use the movie timescale, not all. |
Empty edit durations use the movie timescale, but
get_indice_tableapplied them directly as track ticks. Convert before computing the composition offset; the file in bug 2082877 should start video at 1/60 second rather than 16 seconds. This fixes the sample-table path left unchanged by #407.Adds regression coverage for unequal timescales, negative offsets, large values and invalid conversions, and corrects existing sample-table expectations that encoded the same bug.
Validation:
cargo test --workspace(219 passed, 1 ignored),cargo fmt --all -- --check, andgit diff --check. The new regression failed before the fix (960 ticks instead of 1).