Firefox - 60fps online (twitch, youtube) videos are playing with heavy stuttering or freezing

Hello,

As title says but only happens in Firefox. Chrome and Brave browser playing same content without an issue so it is not network related.
If video is 60fps 720p or 30fps 1080p Firefox plays without a problem.
Win11 on same computer plays all 60fps content with Firefox without a problem.

Anyone got an idea how to fix this? I really don’t want to switch browser just for this issue.
Edit: OK, I think it is all about codecs Firefox is using. So somehow I have to change them.
Any ideas are welcome.

Things I’ve tried:

  • Disabled / Enabled all Firefox plugins.
  • Disabled / Enabled Firefox hardware acceleration.

Computer Info:
Operating System: Fedora Linux 40 Wayland Gnome (Workstation Edition)
Kernel: Linux 6.8.9-300.fc40.x86_64
Hardware Model: ThinkPad E495
CPU: AMD Ryzen 5 3500U with Radeon Vega 8 Mobile Gfx
CPU:
Info: quad core model: AMD Ryzen 5 3500U with Radeon Vega Mobile Gfx
Graphics:
Device-1: AMD Picasso/Raven 2 [Radeon Vega Series / Radeon Mobile Series]
vendor: Lenovo ThinkPad E595 driver: amdgpu v: kernel arch: GCN-5 pcie:
Display: wayland server: X.org v: 1.20.14 with: Xwayland v: 23.2.6
compositor: gnome-shell driver: gpu: amdgpu display-ID: 0
API: OpenGL v: 4.6 vendor: amd mesa v: 24.0.7 glx-v: 1.4 es-v: 3.2
direct-render: yes renderer: AMD Radeon Vega 8 Graphics (radeonsi raven
LLVM 18.1.1 DRM 3.57 6.8.9-300.fc40.x86_64) device-ID: 1002:15d8
display-ID: :0.0

Firefox info:
Version 125.0.3
Build ID 20240501044531
Distribution ID fedora
Window Device Pixel Ratios 1
Compositing WebRender
WebGL 1 Driver Renderer AMD – AMD Radeon Vega 8 Graphics (radeonsi, raven, LLVM 18.1.1, DRM 3.57, 6.8.9-300.fc40.x86_64)
WebGL 1 Driver Version 4.6 (Compatibility Profile) Mesa 24.0.7
WebGL 2 Driver Renderer AMD – AMD Radeon Vega 8 Graphics (radeonsi, raven, LLVM 18.1.1, DRM 3.57, 6.8.9-300.fc40.x86_64)
WebGL 2 Driver Version 4.6 (Core Profile) Mesa 24.0.7
Description AMD Radeon Vega 8 Graphics (radeonsi, raven, LLVM 18.1.1, DRM 3.57, 6.8.9-300.fc40.x86_64)
Vendor ID 0x1002
Device ID 0x15d8
Driver Vendor mesa/radeonsi
Driver Version 24.0.7.0

Audio Backend pulse-rust
Max Channels 2
Preferred Sample Rate 48000
Roundtrip latency (standard deviation) 72.40ms (8.99)
Codec Support Information
Codec Name Software Decoding Hardware Decoding
H264 Supported Unsupported
VP9 Supported Supported
VP8 Supported Unsupported
AV1 Supported Unsupported
HEVC Unsupported Unsupported
Theora Supported Unsupported
AAC Supported Unsupported
MP3 Supported Unsupported
Opus Supported Unsupported
Vorbis Supported Unsupported
FLAC Supported Unsupported
Wave Supported Unsupported

vainfo output:
Trying display: wayland
libva info: VA-API version 1.21.0
libva info: Trying to open /usr/lib64/dri-nonfree/radeonsi_drv_video.so
libva info: Trying to open /usr/lib64/dri-freeworld/radeonsi_drv_video.so
libva info: Trying to open /usr/lib64/dri/radeonsi_drv_video.so
libva info: Found init function __vaDriverInit_1_21
libva info: va_openDriver() returns 0
vainfo: VA-API version: 1.21 (libva 2.21.0)
vainfo: Driver version: Mesa Gallium driver 24.0.7 for AMD Radeon Vega 8 Graphics (radeonsi, raven, LLVM 18.1.1, DRM 3.57, 6.8.9-300.fc40.x86_64)
vainfo: Supported profile and entrypoints
VAProfileMPEG2Simple : VAEntrypointVLD
VAProfileMPEG2Main : VAEntrypointVLD
VAProfileJPEGBaseline : VAEntrypointVLD
VAProfileVP9Profile0 : VAEntrypointVLD
VAProfileVP9Profile2 : VAEntrypointVLD
VAProfileNone : VAEntrypointVideoProc

1 Like

Found the solution.

enable rpm fusion repos.

sudo dnf install \
  https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm

You might try the options --best --allowerasing to that; and the same for the ffmpeg swap.

sudo dnf install libheif-freeworld.x86_64
sudo dnf swap libavcodec-free libavcodec-freeworld
sudo dnf swap ffmpeg-free ffmpeg

2 Likes