Open Bug 1622425 Opened 7 months ago Updated 23 days ago

flatpak: Couldn't find ffmpeg VA-API decoder

Categories

(Core :: Audio/Video: Playback, defect, P5)

75 Branch
x86_64
Linux
defect

Tracking

()

Tracking Status
firefox-esr68 --- unaffected
firefox73 --- unaffected
firefox74 --- unaffected
firefox75 --- disabled
firefox76 --- disabled

People

(Reporter: okias, Unassigned)

References

(Blocks 2 open bugs)

Details

User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:73.0) Gecko/20100101 Firefox/73.0

Steps to reproduce:

Version 75.0b3

  • flatpak install --user https://flathub.org/beta-repo/appstream/org.mozilla.firefox.flatpakref
  • flatpak override --user --socket=wayland --env=GDK_BACKEND=wayland org.mozilla.firefox
    Compositing WebRender
    Window Protocol wayland/drm
    Desktop Environment gnome
    Description Mesa DRI Intel(R) HD Graphics 520 (Skylake GT2)
    WEBRENDER
    opt-in by default: WebRender is an opt-in feature
    available by user: Force enabled by pref

Actual results:

flatpak run --branch=beta org.mozilla.firefox
Gdk-Message: 22:03:20.836: Unable to load hand2 from the cursor theme
Gdk-Message: 22:03:21.012: Unable to load hand2 from the cursor theme
[Child 72: Main Thread]: D/PlatformDecoderModule Couldn't load function avcodec_get_hw_config
[Child 72: Main Thread]: D/PlatformDecoderModule Couldn't load function av_hwdevice_ctx_create
[Child 72: Main Thread]: D/PlatformDecoderModule Couldn't load function av_hwframe_transfer_get_formats
[Child 72: Main Thread]: D/PlatformDecoderModule Couldn't load function av_hwdevice_ctx_create_derived
[Child 72: Main Thread]: D/PlatformDecoderModule Sandbox decoder rejects requested type
[Child 72: Main Thread]: D/PlatformDecoderModule Sandbox decoder rejects requested type
[Child 72: Main Thread]: D/PlatformDecoderModule Sandbox decoder rejects requested type
[Child 72: Main Thread]: D/PlatformDecoderModule Sandbox decoder rejects requested type
[Child 72: Main Thread]: D/PlatformDecoderModule Sandbox decoder supports requested type
[Child 72: Main Thread]: D/PlatformDecoderModule Sandbox decoder supports requested type
[Child 72: Main Thread]: D/PlatformDecoderModule Sandbox decoder supports requested type
[Child 72: Main Thread]: D/PlatformDecoderModule Sandbox decoder rejects requested type

...

[Child 72: Main Thread]: D/PlatformDecoderModule Sandbox decoder rejects requested type
[Child 72: Main Thread]: D/PlatformDecoderModule Sandbox decoder rejects requested type
[Child 72: Main Thread]: D/PlatformDecoderModule Sandbox decoder supports requested type
[Child 72: Main Thread]: D/PlatformDecoderModule Sandbox decoder supports requested type
[Child 72: Main Thread]: D/PlatformDecoderModule Sandbox decoder rejects requested type
[Child 72: Main Thread]: D/PlatformDecoderModule Sandbox decoder rejects requested type
[Child 72: Main Thread]: D/PlatformDecoderModule Sandbox decoder rejects requested type
[Child 72: Main Thread]: D/PlatformDecoderModule Sandbox decoder rejects requested type
[Child 72: Main Thread]: D/PlatformDecoderModule Sandbox decoder supports requested type
[Child 72: Main Thread]: D/PlatformDecoderModule Sandbox decoder rejects requested type
[Child 72: Main Thread]: D/PlatformDecoderModule Sandbox decoder rejects requested type
[Child 72: MediaPlayback #1]: D/PlatformDecoderModule Sandbox decoder rejects requested type
[Child 72: MediaPlayback #1]: D/PlatformDecoderModule Sandbox decoder supports requested type
[Child 72: MediaPlayback #2]: D/PlatformDecoderModule Sandbox decoder supports requested type
xcb_connection_has_error() returned true
[Child 72: MediaPlayback #1]: D/PlatformDecoderModule Sandbox decoder rejects requested type
[Child 72: MediaPDecoder #1]: D/PlatformDecoderModule Initialising VA-API FFmpeg decoder
[Child 72: MediaPDecoder #2]: D/PlatformDecoderModule AudioTrimmer[0x7f350e4553e0] ::operator(): sample[0,21000] no trimming information
[RDD 222: MediaPDecoder #1]: D/PlatformDecoderModule OpusDataDecoder[0x7fa6acb3b3c0] ::ProcessDecode: Opus decoder skipping 312 of 960 frames
[Child 72: MediaPDecoder #2]: D/PlatformDecoderModule AudioTrimmer[0x7f350e4553e0] ::HandleDecodedResult: sample[0,21000] (decoded[0,13500] no trimming needed
[Child 72: MediaPDecoder #1]: D/PlatformDecoderModule Decoder does not support VAAPI device type
[Child 72: MediaPDecoder #1]: D/PlatformDecoderModule Couldn't find ffmpeg VA-API decoder
[Child 72: MediaPDecoder #1]: D/PlatformDecoderModule Initialising FFmpeg decoder.

Expected results:

VAAPI decoding should work under flatpak.

Bugbug thinks this bug should belong to this component, but please revert this change in case of error.

Component: Untriaged → Graphics: WebRender
Product: Firefox → Core
Component: Graphics: WebRender → Untriaged
Product: Core → Firefox
Component: Untriaged → Audio/Video: Playback
OS: Unspecified → Linux
Product: Firefox → Core
Hardware: Unspecified → x86_64
Version: 73 Branch → 75 Branch
Duplicate of this bug: 1623438
Blocks: flatpak
Summary: VAAPI fails when flatpak beta is used → flatpak: Couldn't find ffmpeg VA-API decoder
Duplicate of this bug: 1628407
Status: UNCONFIRMED → NEW
Ever confirmed: true

Bug 1630754 may also affect this one.

Depends on: 1630754

Howdie,

I'm still seeing this issue with stable flatpak 78.0.2 (64-bit) even after following this guide: https://mastransky.wordpress.com/2020/06/03/firefox-on-fedora-finally-gets-va-api-on-wayland/

about:support:

  • Compositing: WebRender
  • Window Protocol: wayland/drm

about:config:

  • widget.wayland-dmabuf-vaapi.enabled: true
  • media.ffvpx.enabled: false

e.g. this Instagram video: https://www.instagram.com/tv/CCs-N1Eh2Z5/

Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [Child 520: Main Thread]: D/PlatformDecoderModule Sandbox decoder rejects requested type
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [Child 520: Main Thread]: D/PlatformDecoderModule Sandbox decoder rejects requested type
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [Child 520: MediaPlayback #1]: D/PlatformDecoderModule Sandbox decoder rejects requested type
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [Child 520: MediaPlayback #1]: D/PlatformDecoderModule Sandbox decoder rejects requested type
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [Child 520: MediaPlayback #1]: D/PlatformDecoderModule Sandbox decoder rejects requested type
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [Child 520: MediaPlayback #1]: D/PlatformDecoderModule Sandbox decoder rejects requested type
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [Child 520: MediaPDecoder #1]: D/PlatformDecoderModule Initialising FFmpeg decoder.
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [Child 520: MediaPDecoder #1]: D/PlatformDecoderModule FFmpeg init successful.
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [Child 520: MediaPDecoder #1]: D/PlatformDecoderModule Initialising VA-API FFmpeg decoder
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [Child 520: MediaPDecoder #1]: D/PlatformDecoderModule Decoder does not support VAAPI device type
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [Child 520: MediaPDecoder #1]: D/PlatformDecoderModule Couldn't find ffmpeg VA-API decoder
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [Child 520: MediaPDecoder #1]: D/PlatformDecoderModule Initialising FFmpeg decoder.
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [Child 520: MediaPDecoder #2]: D/PlatformDecoderModule AudioTrimmer[0x7f41eadd2600] ::operator(): sample[0,21333] no trimming information
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [libfdk_aac @ 0x7f41e9c32800] 2 channels - front:2 side:0 back:0 lfe:0 top:0
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [OpenH264] this = 0x0x7f41e9ee6000, Info:CWelsDecoder::SetOption():DECODER_OPTION_TRACE_CALLBACK callback = 0x7f41e9494360.
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [libopenh264 @ 0x7f41e9c37800] [OpenH264] this = 0x0x7f41e9ee6000, Info:CWelsDecoder::init_decoder(), openh264 codec version = d13f170, ParseOnly = 0
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [Child 520: MediaPDecoder #2]: D/PlatformDecoderModule AudioTrimmer[0x7f41eadd2600] ::HandleDecodedResult: sample[0,21333] (decoded[0,21333] no trimming needed
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [libopenh264 @ 0x7f41e9c37800] [OpenH264] this = 0x0x7f41e9ee6000, Info:CWelsDecoder::init_decoder(), openh264 codec version = d13f170, ParseOnly = 0
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [libopenh264 @ 0x7f41e9c37800] [OpenH264] this = 0x0x7f41e9ee6000, Info:eVideoType: 1
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [Child 520: MediaPDecoder #1]: D/PlatformDecoderModule FFmpeg init successful.
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [libopenh264 @ 0x7f41e9c37800] [OpenH264] this = 0x0x7f41e9ee6000, Warning:the total count of mb exceeds the level limits!
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [libopenh264 @ 0x7f41e9c37800] [OpenH264] this = 0x0x7f41e9ee6000, Warning: max_num_ref_frames exceeds level limits!
Jul 21 04:21:04 hellmouth org.mozilla.firefox.desktop[18784]: [libopenh264 @ 0x7f41e9c37800] [OpenH264] this = 0x0x7f41e9ee6000, Info:WelsRequestMem(): memory alloc size = 1152 * 656, ref list size = 6

But outside of flatpak, on the terminal, I get:

❯ ffmpeg -version
ffmpeg version n4.3.1 Copyright (c) 2000-2020 the FFmpeg developers
built with gcc 10.1.0 (GCC)
configuration: --prefix=/usr --disable-debug --disable-static --disable-stripping --enable-avisynth --enable-fontconfig --enable-gmp --enable-gnutls --enable-gpl --enable-ladspa --enable-libaom --enable-libass --enable-libbluray --enable-libdav1d --enable-libdrm --enable-libfreetype --enable-libfribidi --enable-libgsm --enable-libiec61883 --enable-libjack --enable-libmfx --enable-libmodplug --enable-libmp3lame --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-librav1e --enable-libsoxr --enable-libspeex --enable-libsrt --enable-libssh --enable-libtheora --enable-libv4l2 --enable-libvidstab --enable-libvmaf --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxcb --enable-libxml2 --enable-libxvid --enable-nvdec --enable-nvenc --enable-omx --enable-shared --enable-version3
libavutil 56. 51.100 / 56. 51.100
libavcodec 58. 91.100 / 58. 91.100
libavformat 58. 45.100 / 58. 45.100
libavdevice 58. 10.100 / 58. 10.100
libavfilter 7. 85.100 / 7. 85.100
libswscale 5. 7.100 / 5. 7.100
libswresample 3. 7.100 / 3. 7.100
libpostproc 55. 7.100 / 55. 7.100

❯ vainfo
vainfo: VA-API version: 1.8 (libva 2.8.0)
vainfo: Driver version: Mesa Gallium driver 20.1.3 for AMD Radeon RX 5700 XT (NAVI10, DRM 3.37.0, 5.7.9-arch1-1, LLVM 10.0.0)
vainfo: Supported profile and entrypoints
VAProfileMPEG2Simple : VAEntrypointVLD
VAProfileMPEG2Main : VAEntrypointVLD
VAProfileVC1Simple : VAEntrypointVLD
VAProfileVC1Main : VAEntrypointVLD
VAProfileVC1Advanced : VAEntrypointVLD
VAProfileH264ConstrainedBaseline: VAEntrypointVLD
VAProfileH264ConstrainedBaseline: VAEntrypointEncSlice
VAProfileH264Main : VAEntrypointVLD
VAProfileH264Main : VAEntrypointEncSlice
VAProfileH264High : VAEntrypointVLD
VAProfileH264High : VAEntrypointEncSlice
VAProfileHEVCMain : VAEntrypointVLD
VAProfileHEVCMain : VAEntrypointEncSlice
VAProfileHEVCMain10 : VAEntrypointVLD
VAProfileHEVCMain10 : VAEntrypointEncSlice
VAProfileJPEGBaseline : VAEntrypointVLD
VAProfileVP9Profile0 : VAEntrypointVLD
VAProfileVP9Profile2 : VAEntrypointVLD
VAProfileNone : VAEntrypointVideoProc

Any suggestions for what I can try next? Or any additional information that you'd like me to provide to help figure this out?

Cheers!

You need to log in before you can comment on or make changes to this bug.