Skip to content

qtmux: fix byte order for opus extension

The "Encapsulation of Opus in ISO Base Media File Format" [1] specifications, § 4.3.2 Opus Specific Box, indicates that data must be stored as big-endian.

In build_opus_extension, gst_byte_writer_put*_le () variants were used, causing audio streams conversion to Opus in mp4 to offset samples due to the PreSkip field incorrect value (29ms early in our test cases).

In qtdemux, the rate field is should be a big-endian.

[1] https://opus-codec.org/docs/opus_in_isobmff.html#4.3.2

Edited by François Laignel

Merge request reports