Closed Bug 1233340 Opened 7 years ago Closed 7 years ago

Firefox 43 fails to play (some) H264 video with FFmpeg 2.8.3


(Firefox :: General, defect)

43 Branch
Not set



Firefox 46
Tracking Status
firefox43 --- wontfix
firefox44 + fixed
firefox45 --- fixed
firefox46 --- fixed


(Reporter: evangelos, Assigned: jya)





(1 file)

Using Firefox 43 with system FFmpeg 2.8.3 on Arch Linux, some H264 videos appear to have playback issues. The example YouTube video linked at the end fails with "An error occurred. Please try again later." [1] This happens with the official Firefox 43 binaries as well as the Arch Firefox 43 package.

The following errors are printed to the terminal when opening the example YouTube video page:

  [h264 @ 0x7f2f607ce000] decode_slice_header error
  [h264 @ 0x7f2f607ce000] no frame!
  [h264 @ 0x7f2f607d3000] decode_slice_header error
  [h264 @ 0x7f2f607d3000] no frame!
  [h264 @ 0x7f2f607d2800] decode_slice_header error
  [h264 @ 0x7f2f607d2800] no frame!
  [h264 @ 0x7f2f607d7000] decode_slice_header error
  [h264 @ 0x7f2f607d7000] no frame!
  [h264 @ 0x7f2f60c2b000] decode_slice_header error
  [h264 @ 0x7f2f60c2b000] no frame!
  [h264 @ 0x7f2f60c33000] decode_slice_header error
  [h264 @ 0x7f2f60c33000] no frame!

According to the YouTube player, the video is of type 'video/mp4; codecs="avc1.640028"', though other YouTube videos with the same codec play without issues.

Note: With newer Firefox versions YouTube seems to serve WebM/VP9 video which works fine. If trying to repro the issue, use this user agent string: "Mozilla/5.0 (X11; Linux x86_64; rv:43.0) Gecko/20100101 Firefox/43.0".

Also reproducible on Ubuntu 15.10 (FFmpeg 2.7.3); same error in the terminal.
Chris, does it ring a bell?
Flags: needinfo?(cpearce)
Jean-Yves - this video doesn't play (e.g. on 720p) on Linux but plays fine on Mac. It also plays with ffplay.
Flags: needinfo?(jyavenard)
Assignee: nobody → jyavenard
Flags: needinfo?(jyavenard)
If YouTube properly served webm/vp9 like they used to that would get around the problem :(
See Also: → 1233970
The video is encoded with format yuvj420p not your typcal yuv420p...
YUV420J is 12bpp YUV420P.
Comment on attachment 8700436 [details] [diff] [review]
[ffmpeg] Support YUV420J pixel format.

hmmm wonder why the review flag wasn't set ...
Attachment #8700436 - Flags: review?(ajones)
Attachment #8700436 - Flags: review?(ajones) → review+
[Tracking Requested - why for this release]: This prevents to play some mp4 videos (youtube and likely others).
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 46
Reproduced this bug with Firefox 43.0.2 ; (Build ID: 20151221130713) on Linux, 64 Bit

This Bug is now verified as fixed on Latest Firefox Nightly 46.0a1 (2015-12-24)

Build ID: 20151224030228
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:46.0) Gecko/20100101 Firefox/46.0
QA Whiteboard: [bugday-20151223]
Comment on attachment 8700436 [details] [diff] [review]
[ffmpeg] Support YUV420J pixel format.

Approval Request Comment
[Feature/regressing bug #]:1233340
[User impact if declined]: some YouTube videos won't play on Linux. 
[Describe test coverage new/current, TreeHerder]: in central, manually verified as fixed
[Risks and why]: very low, adding detection of a video output format rarely used. 
[String/UUID change made/needed]: none.
Attachment #8700436 - Flags: approval-mozilla-beta?
Attachment #8700436 - Flags: approval-mozilla-aurora?
Comment on attachment 8700436 [details] [diff] [review]
[ffmpeg] Support YUV420J pixel format.

Sure, let's take that!
Attachment #8700436 - Flags: approval-mozilla-beta?
Attachment #8700436 - Flags: approval-mozilla-beta+
Attachment #8700436 - Flags: approval-mozilla-aurora?
Attachment #8700436 - Flags: approval-mozilla-aurora+
Ffmpeg usent used in B2G
Flags: needinfo?(cpearce)
See Also: → 1247041


STR: Not clear.
Developer specific testing

Name			Firefox
Version			46.0b9
Build ID		20160322075646
Update Channel	beta
User Agent		Mozilla/5.0 (Windows NT 6.1; WOW64; rv:46.0) Gecko/20100101 Firefox/46.0
OS				Windows 7 SP1 x86_64

Expected Results: 
Developer specific testing

Actual Results: 
As expected
This is a Linux bug when using ffmpeg 2.8. Using Windows 7 to reproduce the bug isn't going to take you very far.
I'm using ffmpeg 2.8.6 with Firefox 47 on Linux and this is still a problem with youtube videos.  The only workaround that worked for me was to set media.fragmented-mp4.gmp.enabled to false so that it uses gstreamer instead of ffmpeg.  This bug should NOT be marked as fixed.
If you are having an issue, then please open a new bug. It's unlikely the issue you are experiencing is the same as what has been discussed in this bug.
thank you
BTW, there's no gstreamer support in Firefox 47. and the pref media.fragmented-mp4.gmp.enabled does nothing as it was removed in FF 43.
It seems I had enabled it before.  Resetting it back to default fixed the problem for me.  So I guess the setting is still there in Firefox 47 and enabling it still causes playback problems.
I checked about:config again and now it appears to be gone.  That's quite strange.  So I guess what happened is the user modified setting persisted even though the property was removed in Firefox 43 which still caused Firefox 47 to malfunction.  So the question is why doesn't removing the property in Firefox 43 also remove user modified properties?
we never delete things user created.

the use media.fragmented-mp4.gmp.enabled wouldn't have enabled gmp. It would have however seriously broken playback. Some few "guides" used to mentioned that this was required even though it was a terrible advice.
I must have enabled it a while back to get html5 playback to work in youtube and forgot I had enabled it.  I must have not realized it was terrible advice at the time.  Thanks for the clarification.
You need to log in before you can comment on or make changes to this bug.