In a Linux system (Fedora 31) with VAAPI and hardware video acceleration enabled ( #ignore-gpu-blacklist ), if a webpage has a video encoded in VP9 format, the video playback is stuck. Hardware-accelerated video playback works normally for h624-encoded videos.
This means that either you play all videos in software-mode or only play h264-encoded videos when hardware acceleration is available.
chromium-vaapi in the same test scenarioIn chromium, despite having #ignore-gpu-blacklist and accelerated video playback, it doesn't affect VP9. So, chromium is not affected
This leads that the underling Chromium that Brave is using is missing some library/feature/compilation flag.
sudo dnf install libva libva-utils intel-media-driver libva-intel-driverVideo playback is stuck.
brave://media-internals/
render_id: 9
player_id: 41
origin_url: https://www.youtube.com/
kFrameUrl: https://www.youtube.com/watch?v=MZEUGR3Q21I
kFrameTitle: YouTube
url: blob:https://www.youtube.com/500eda88-a298-41e4-a3d6-874d47deecfd
info: Selected MojoVideoDecoder for video decoding, config: codec: vp9, profile: vp9 profile0, alpha_mode: is_opaque, coded size: [640,360], visible rect: [0,0,640,360], natural size: [640,360], has extra data: false, encryption scheme: Unencrypted, rotation: 0掳, flipped: 0, color space: {primaries:BT709, transfer:BT709, matrix:BT709, range:LIMITED}
pipeline_state: kPlaying
kVideoTracks: [object Object]
kAudioTracks: [object Object]
kIsAudioDecryptingDemuxerStream: false
kAudioDecoderName: FFmpegAudioDecoder
kIsPlatformAudioDecoder: false
event: PLAY
kIsVideoDecryptingDemuxerStream: false
kVideoDecoderName: MojoVideoDecoder
kIsPlatformVideoDecoder: true
audio_buffering_state: BUFFERING_HAVE_ENOUGH
duration: 169.821
Videos playing normally with hardware acceleration enabled
Every time
Brave | 1.4.96 Chromium: 80.0.3987.132聽(Official Build)聽(64-bit)
-- | --
Revision | fcea73228632975e052eb90fcf6cd1752d3b42b4-refs/branch-heads/3987@{#974}
OS | Linux
JavaScript | V8聽8.0.426.26
Flash | (Disabled)
User Agent | Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.132 Safari/537.36
Command Line | /opt/brave.com/brave/brave --enable-dom-distiller --disable-domain-reliability --no-pings --extension-content-verification=enforce_strict --extensions-install-verification=enforce --sync-url=https://no-thanks.invalid --enable-features=PasswordImport,WebUIDarkMode,SimplifyHttpsIndicator --disable-features=AutofillServerCommunication,AllowPopupsDuringPageUnload,NotificationTriggers,AudioServiceOutOfProcess,SmsReceiver,LookalikeUrlNavigationSuggestionsUI,WebXR,VideoPlaybackQuality,WebXrGamepadModule --flag-switches-begin --ignore-gpu-blacklist --flag-switches-end --disable-webrtc-apm-in-audio-service --disable-sync
Executable Path | /opt/brave.com/brave/brave
Profile Path | /home/gjc/.config/BraveSoftware/Brave-Browser/Default
Related bugs: #1024 and #7706
Some chromium-vaapi articles in the Fedora/Linux world:
vainfo:
libva info: VA-API version 1.6.0
libva info: va_getDriverName() returns 0
libva info: Trying to open /usr/lib64/dri/i965_drv_video.so
libva info: Found init function __vaDriverInit_1_6
libva info: va_openDriver() returns 0
vainfo: VA-API version: 1.6 (libva 2.6.0.pre1)
vainfo: Driver version: Intel iHD driver - 1.0.0
vainfo: Supported profile and entrypoints
VAProfileNone : VAEntrypointVideoProc
VAProfileNone : VAEntrypointStats
VAProfileMPEG2Simple : VAEntrypointVLD
VAProfileMPEG2Simple : VAEntrypointEncSlice
VAProfileMPEG2Main : VAEntrypointVLD
VAProfileMPEG2Main : VAEntrypointEncSlice
VAProfileH264Main : VAEntrypointVLD
VAProfileH264Main : VAEntrypointEncSlice
VAProfileH264Main : VAEntrypointFEI
VAProfileH264Main : VAEntrypointEncSliceLP
VAProfileH264High : VAEntrypointVLD
VAProfileH264High : VAEntrypointEncSlice
VAProfileH264High : VAEntrypointFEI
VAProfileH264High : VAEntrypointEncSliceLP
VAProfileVC1Simple : VAEntrypointVLD
VAProfileVC1Main : VAEntrypointVLD
VAProfileVC1Advanced : VAEntrypointVLD
VAProfileJPEGBaseline : VAEntrypointVLD
VAProfileJPEGBaseline : VAEntrypointEncPicture
VAProfileH264ConstrainedBaseline: VAEntrypointVLD
VAProfileH264ConstrainedBaseline: VAEntrypointEncSlice
VAProfileH264ConstrainedBaseline: VAEntrypointFEI
VAProfileH264ConstrainedBaseline: VAEntrypointEncSliceLP
VAProfileVP8Version0_3 : VAEntrypointVLD
VAProfileVP8Version0_3 : VAEntrypointEncSlice
VAProfileHEVCMain : VAEntrypointVLD
VAProfileHEVCMain : VAEntrypointEncSlice
VAProfileHEVCMain : VAEntrypointFEI
VAProfileHEVCMain10 : VAEntrypointVLD
VAProfileHEVCMain10 : VAEntrypointEncSlice
VAProfileVP9Profile0 : VAEntrypointVLD
VAProfileVP9Profile2 : VAEntrypointVLD
This is funny because for me it is exactly the other way around.
With HW acceleration enabled I can watch VP9 videos, but h264 video content is severely broken #7706
It is true that Chromium with enabled HW accel has no issues, so it is Brave specific.
@Nuc1eoN can you share some system details? Which GPU do you have? what does vainfo return?
vainfo: VA-API version: 1.6 (libva 2.6.0)
vainfo: Driver version: Mesa Gallium driver 19.3.4 for AMD Radeon (TM) RX 470 Graphics (POLARIS10, DRM 3.36.0, 5.5.11-arch1-1, LLVM 9.0.1)
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
VAProfileJPEGBaseline : VAEntrypointVLD
VAProfileNone : VAEntrypointVideoProc
I do not have the new chromium-vaapi package installed though (ArchLinux) if you are referring to that. Do I need it?
However Brave clearly misbehaves only when HW accel is active in settings, so I guess it makes use of some functionality :thinking:
I do not have the new
chromium-vaapipackage installed though (ArchLinux) if you are referring to that. Do I need it?
No. Chromium with vaapi enabled has different names according to the distro. Since I'm using Fedora the package name is chromium-freeworld provided by rpmfusion.
In Archlinux is available as chromium-vaapi from AUR (as described in chromium archlinux wiki page here)
Any of the packages should provide a solid base to update Brave patching/enabling of VAAPI for Linux users.
I'm having the same issue described here, couldn't test chromium-vaapi myself because the binaries are not available in the AUR anymore and I don't really want to download all the necessary dependencies to build it.
Any changes so far? Did you get working?
No progress on my side. Going to re-test once 1.7.x is out
Someone need to add this patch to brave. It will fix the Intel VP9 issue. Honestly there are many issues with chromium atm. (egl backend is busted in the current build and issue with Mesa).
@Nuc1eoN Your issue is with mesa rgb10 configs. You need to disable it. Add export allow_rgb10_configs=false in your environment and relaunch.
Humm according to their tree they need 3 patches?
About stability: I have zero issues with chromium-freeworld and it is a lot better on cpu/laptop battery than Brave is. hum
chromium-enable-vaapi.patch
This is not required.
Hey, is there any kind of process we can follow to accelerate the revision of this issue?
This patch chromium-fix-vaapi-on-intel.patch seems to be being applied virtually everywhere (Ubuntu, Fedora, Arch) and the lack of acceleration is a bit of a PITA.
Thanks!
I use an extension to force x264 in youtube (https://chrome.google.com/webstore/detail/h264ify/aleakchihdccplidncghkekgioiakgal) as a workaround and it works great (lower cpu usage).
Would this also enable VP9 hardware acceleration in WebRTC (google meet?) since that would be a huge advantage...
On arch linux https://aur.archlinux.org/packages/chromium-vaapi/ (last updated: 2020-07-07) gives me vp9 acceleration, while the latest chromium packages don't (only x264 acceleration).
Most helpful comment
This is funny because for me it is exactly the other way around.
With HW acceleration enabled I can watch VP9 videos, but h264 video content is severely broken #7706
It is true that Chromium with enabled HW accel has no issues, so it is Brave specific.