Closed
Bug 1227153
Opened 9 years ago
Closed 8 years ago
Cannot play 24kHz opus audio stream inside a webm file
Categories
(Core :: Audio/Video: Playback, defect, P1)
Tracking
()
RESOLVED
INVALID
People
(Reporter: przemyslaw.sobala, Assigned: mozbugz)
References
Details
Attachments
(1 file, 1 obsolete file)
37.17 KB,
video/webm
|
Details |
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:42.0) Gecko/20100101 Firefox/42.0 Build ID: 20151029151421 Steps to reproduce: I used FFmpeg to create a webm file with a 24kHz sampled audio stream encoded with opus audio codec, eg: ffmpeg -i http://www.soundsnap.com/audio/play/72210%3A1448291371%3Ab4326304c013a3a61b3b87d83158c91b -c:a libopus -b:a 64k -ar 24000 /tmp/tmp.webm Actual results: When opening the webm file with Firefox (eg. file:///tmp/tmp.webm) browser reports an error. It happens regardless of input file. When I encode with sample rate = 48000 (ffmpeg -i http://www.soundsnap.com/audio/play/72210%3A1448291371%3Ab4326304c013a3a61b3b87d83158c91b -c:a libopus -b:a 64k -ar 48000 /tmp/tmp.webm) the result is playable.
Updated•9 years ago
|
Component: Untriaged → Audio/Video: Playback
Product: Firefox → Core
Updated•9 years ago
|
Priority: -- → P1
Assignee | ||
Comment 1•8 years ago
|
||
There's a sanity check in the OpusDataDecoder that fails because it's using the wrong rate. Working on a patch now.
Assignee: nobody → gsquelart
Assignee | ||
Comment 2•8 years ago
|
||
Use nominal rate in Opus sanity check. The OpusDataDecoder checks that the 'codecDelay' (in microseconds) configuration matches the time to skip "pre-skip" frames. However the latter was calculated using the OpusParser rate (which is always 48kHz) instead of the nominal rate (actually used in the file).
Attachment #8703467 -
Flags: review?(kinetik)
Comment 3•8 years ago
|
||
Maybe I am confused, but the pre-skip value stored in the header is always stored at the 48 kHz rate. We should not be using the nominal rate here. If the value stored in CodecDelay was computed from the header's pre-skip field using the nominal rate, then that value is broken and we are correct to reject the file. I.e., the bug here may be in FFmpeg, not in Firefox.
Assignee | ||
Comment 4•8 years ago
|
||
Comment on attachment 8703467 [details] [diff] [review] 1227153-check-nominal-rate.patch (In reply to Timothy B. Terriberry (:derf) from comment #3) > Maybe I am confused, but the pre-skip value stored in the header is always > stored at the 48 kHz rate. We should not be using the nominal rate here. If > the value stored in CodecDelay was computed from the header's pre-skip field > using the nominal rate, then that value is broken and we are correct to > reject the file. > > I.e., the bug here may be in FFmpeg, not in Firefox. Thank you Timothy, you are most certainly correct, pre-skip refers to 48kHz frames.
Attachment #8703467 -
Attachment is obsolete: true
Attachment #8703467 -
Flags: review?(kinetik)
Assignee | ||
Comment 5•8 years ago
|
||
As per comment 3, it looks like FFmpeg is producing an incorrect Opus file, with a 'pre-skip' value using the nominal rate instead of the expected 48 kHz. CC:Michael, could you please have a look?
Status: UNCONFIRMED → RESOLVED
Closed: 8 years ago
Resolution: --- → INVALID
Reporter | ||
Comment 6•8 years ago
|
||
Created ticket at FFmpeg's bugtracker: https://trac.ffmpeg.org/ticket/5121
You need to log in
before you can comment on or make changes to this bug.
Description
•