Seeking of some media codecs not working
Categories
(Core :: Audio/Video, defect)
Tracking
()
People
(Reporter: bergraymond, Unassigned)
Details
Steps to reproduce:
Open the resulting file in fenix. For me, the first one (m4a) will start to play fine, however seeking to e.g. 30min will load forever.
yt-dlp -f bestaudio[ext=m4a] --get-url https://www.youtube.com/watch?v=iCk16sC3dP0
However when using opus it works fine:
yt-dlp -f "bestaudio[acodec=opus]" --get-url https://www.youtube.com/watch?v=iCk16sC3dP0
Similar situation with h264 and vp09. vp09 works fine, but h264 seems to need to download the entire content before the seeked timestamp, before it can play it.
Actual results:
Seeking is not working correctly
Expected results:
Seeking should work fine
| Reporter | ||
Comment 1•2 years ago
|
||
Open the resulting file
I meant the resulting URL (of the yt-dlp command), not file - When the file is local, delays due to (apparently) needing to download the previous content might not be noticeable anymore
Comment 2•1 year ago
|
||
The severity field is not set for this bug.
:titouan, could you have a look please?
For more information, please visit BugBot documentation.
Comment 3•1 year ago
|
||
I can reproduce the bug on Firefox Desktop too, using this URL produced by yt-dlp -f "bestaudio[ext=m4a]" --get-url https://www.youtube.com/watch?v=iCk16sC3dP0
I'll move it to Core / Audio/Video.
Comment 4•1 year ago
|
||
The severity field is not set for this bug.
:jimm, could you have a look please?
For more information, please visit BugBot documentation.
Updated•1 year ago
|
Comment 5•1 year ago
|
||
The url here is dead, but I'm curious -
Similar situation with h264 and vp09. vp09 works fine, but h264 seems to need to download the entire content before the seeked timestamp, before it can play it.
Is this expected?
Comment 6•1 year ago
•
|
||
I can reproduce this on mac too. It seems the site throttles the download speed. (curl shows ~30kps.)
When seeking fragmented MP4, the parser checks each moof box to determine whether the target has been reached, so it is blocked until the fragment is downloaded. On the other hand, WebM has all CuePoints at the beginning of file so it can find the position of seek target more quickly and use a range request to jump to the target directly.
Loading the yt-dlp URLs in Firefox and checking Network Monitor in DevTools shows the difference. For the m4a URL, seeking doesn't generate additional request but for the opus URL, seeking the audio generates range request.
With the exception of youtube most video platforms just break playback on firefox if you seek.
Some examples:
- reddit: https://www.reddit.com/r/Unexpected/comments/1jn9ycg/kiss_cam/
- vimeo: https://vimeo.com/groups/114/videos/1017406920
Trying to seek on both will just make them load forever or simply throw a player error in firefox while it works fine on anything chromium based.
I assume there's already an ancient unfixed issue of which this one is a duplicate but it's damn impossible to find it in bugzilla, so hope the bug triage folks will eventually link this to it.
Description
•