You are not logged in.
Thank you!
Offline
sorry maybe off-topic, but is it possible to enable vaapi in electron apps like signal-desktop?
It used to work with Freetube.
So as long as you match the right flags/hardware/electron-release( so its chromium associated release) combination, it could work just as Chromium.
Offline
Not a single problem after 120 release (ungoogled-chromium) on Intel. Dumping flags here, some of them are redundant at this point:
--disable-gpu-driver-bug-workarounds
--enable-features=VaapiVideoDecodeLinuxGL,UseChromeOSDirectVideoDecoder,CanvasOopRasterization,WebUIDarkMode
--enable-gpu-rasterization
--ignore-gpu-blocklist
--ozone-platform=wayland
Last edited by matt3us (2024-09-06 15:48:06)
Offline
Not a single problem after 120 release (ungoogled-chromium) on Intel. Dumping flags here, some of them are redundant at this point:
--disable-gpu-driver-bug-workarounds --enable-features=VaapiVideoDecodeLinuxGL,UseChromeOSDirectVideoDecoder,CanvasOopRasterization,WebUIDarkMode --enable-gpu-rasterization --ignore-gpu-blocklist --ozone-platform=wayland
I guess it's for newer intel generations. My ivy bridge doesn't manage.
Offline
On my HD 4000 (Ivy Bridge Mobile) (with some flags) in chrome://gpu everything seems alright. But when playing actual video in chrome://media-internals, I can see warnings about falling back and error:
VaapiVideoDecoder: failed initializing the frame pool
Video acceleration itself works on my OS (I tested it with mpv). If somebody could get it working on ivy, please tell how.
Last edited by skajmer (2024-10-06 18:18:57)
Offline
I enabled hardware accelerated video decoding on Chromium with the following configuration:
i7-1355U
Gnome, Wayland
Installed packages: intel-media-driver, vulkan-intel
~/.config/chromium-flags.conf:
--enable-features=Vulkan,DefaultANGLEVulkan,VulkanFromANGLE
I didn't explicitly enable video decoding, but it just works with Vulkan enabled. Seems like the most modern configuration to me. Didn't experience any issues so far from short usage.
I also use flag --ozone-platform=wayland but it is not necessary for video decoding.
EDIT: turned out this is not very stable for me. If I would turn display off for some time, browser becomes frozen and i takes around a minute for it to return back. It's not crashing itself, but according to the logs, GPU process or something like that is crashed and probably being restarted.
Last edited by vbezhenar (2024-11-06 00:58:53)
Offline
After update to 131, I got this regression (errors show up in chrome://gpu):
[6049:6049:1113/220408.223558:ERROR:gl_display.cc(497)] : EGL Driver message (Error) eglCreateContext: Requested version is not supported
[6049:6049:1113/220648.819176:ERROR:gl_display.cc(497)] : EGL Driver message (Error) eglCreateContext: Requested version is not supported
and of course I got no video acceleration. Anyone having similar problems?
Offline
After update to 131, I got this regression (errors show up in chrome://gpu):
[6049:6049:1113/220408.223558:ERROR:gl_display.cc(497)] : EGL Driver message (Error) eglCreateContext: Requested version is not supported [6049:6049:1113/220648.819176:ERROR:gl_display.cc(497)] : EGL Driver message (Error) eglCreateContext: Requested version is not supported
and of course I got no video acceleration. Anyone having similar problems?
The same error log shows on my amdgpu setup, but vaapi is working normally. Besides, there is also the following error log
[4867:4867:1114/174017.770009:ERROR:wayland_surface_factory.cc(241)] : '--ozone-platform=wayland' is not compatible with Vulkan. Consider switching to '--ozone-platform=x11' or disabling Vulkan
while vulkan wayland seems also working fine..
Offline
Sorry, false alarm: apparently I just have to change "VaapiVideoDecode" to "AcceleratedVideoDecode". The old flag is no longer recognized
Offline
On a site note though, has anyone got Chrome running on Vulkan backend with NVIDIA drivers? 'cos I can't. Seems that only AMD GPUs work at the moment?
Offline
Sorry, false alarm: apparently I just have to change "VaapiVideoDecode" to "AcceleratedVideoDecode". The old flag is no longer recognized
Sure?
How have you checked? I use " sudo intel_gpu_top" ( I use Intel Xe GPU).
Id doesn't work for me with neither "AcceleratedVideoDecode" nor "AcceleratedVideoDecoder" (trailing "r").
For me it simply doesn't work.
But it works with 130.
Have you also enabled any flag in chrome:flags?
Last edited by 0BADC0DE (2024-11-15 12:14:32)
Maybe Computers Will Never Become As Intelligent
As Humans. Surely They Won't Ever Become So Stupid.
Offline
xuanrui wrote:Sorry, false alarm: apparently I just have to change "VaapiVideoDecode" to "AcceleratedVideoDecode". The old flag is no longer recognized
Sure?
How have you checked? I use " sudo intel_gpu_top" ( I use Intel Xe GPU).
Id doesn't work for me with neither "AcceleratedVideoDecode" nor "AcceleratedVideoDecoder" (trailing "r").
For me it simply doesn't work.
But it works with 130.
Have you also enabled any flag in chrome:flags?
Well, it used to be VaapiVideoDecodeLinuxGL,VaapiDecodeLinuxZeroCopyGL, now you just replace "Vaapi" with "Accelerated": AcceleratedVideoDecodeLinuxGL,AcceleratedVideoDecodeLinuxZeroCopyGL
Offline
Have you also enabled any flag in chrome:flags?
For reference, u can check the flag commands here.
By the way, i find
VaapiIgnoreDriverChecks
is also necessary on my amdgpu setup to make hw decode working.
Last edited by Bzzz_56 (2024-11-15 12:27:07)
Offline
0BADC0DE wrote:xuanrui wrote:Sorry, false alarm: apparently I just have to change "VaapiVideoDecode" to "AcceleratedVideoDecode". The old flag is no longer recognized
Sure?
How have you checked? I use " sudo intel_gpu_top" ( I use Intel Xe GPU).
Id doesn't work for me with neither "AcceleratedVideoDecode" nor "AcceleratedVideoDecoder" (trailing "r").
For me it simply doesn't work.
But it works with 130.
Have you also enabled any flag in chrome:flags?Well, it used to be VaapiVideoDecodeLinuxGL,VaapiDecodeLinuxZeroCopyGL, now you just replace "Vaapi" with "Accelerated": AcceleratedVideoDecodeLinuxGL,AcceleratedVideoDecodeLinuxZeroCopyGL
NOw it is ok. But "AcceleratedVideoDecodeLinuxZeroCopyGL" prevents you for using the "VideoEnhance" feature from the GPU.
Is there anything for accelerated video encode ?
Maybe Computers Will Never Become As Intelligent
As Humans. Surely They Won't Ever Become So Stupid.
Offline
0BADC0DE wrote:Have you also enabled any flag in chrome:flags?
For reference, u can check the flag commands here.
Super!!! Thanks @Bzzz_56!
Maybe Computers Will Never Become As Intelligent
As Humans. Surely They Won't Ever Become So Stupid.
Offline
xuanrui wrote:0BADC0DE wrote:Sure?
How have you checked? I use " sudo intel_gpu_top" ( I use Intel Xe GPU).
Id doesn't work for me with neither "AcceleratedVideoDecode" nor "AcceleratedVideoDecoder" (trailing "r").
For me it simply doesn't work.
But it works with 130.
Have you also enabled any flag in chrome:flags?Well, it used to be VaapiVideoDecodeLinuxGL,VaapiDecodeLinuxZeroCopyGL, now you just replace "Vaapi" with "Accelerated": AcceleratedVideoDecodeLinuxGL,AcceleratedVideoDecodeLinuxZeroCopyGL
NOw it is ok. But "AcceleratedVideoDecodeLinuxZeroCopyGL" prevents you for using the "VideoEnhance" feature from the GPU.
Is there anything for accelerated video encode ?
--enable-features=AcceleratedVideoEncoder
Offline
Full Vilkan support on native Wayland:
--ozone-platform=wayland --use-vulkan --enable-features=Vulkan,VulkanFromANGLE,DefaultANGLEVulkan
Optional hint for Vulkan:
--use-gl=angle --use-angle=vulkan
--enable-features=UseOzonePlatform
Optional Wayland hint:
--enable-features=WaylandWindowDecorations
VAAPI Decode (basic):
--enable-features=AcceleratedVideoDecodeLinuxGL
also zero copy variant:
--enable-features=AcceleratedVideoDecodeLinuxZeroCopyGL
VAAPI Decode (more options, not guarantee to work on new versions):
--enable-features=VaapiIgnoreDriverChecks,UseMultiPlaneFormatForHardwareVideo,PlatformHEVCDecoderSupport
VAAPI Encode:
--enable-features=AcceleratedVideoEncoder
also some other old options:
--enable-accelerated-mjpeg-decode --enable-global-vaapi-lock --use-gpu-scheduler-dfs --cast-streaming-hardware-h264
Other "performance" options
--enable-zero-copy --canvas-oop-rasterization --enable-gpu-rasterization
--enable-features=CanvasOopRasterization
Enabling Web GPU (only with unsafe option):
--enable-gpu --enable-unsafe-webgpu
Also a lot of workaround options like:
--disable-gpu-driver-bug-workarounds --ignore-gpu-blocklist
But they are for situations when "nothing helped"
!!! Do not try to enable Skia Graphite with Vulkan -- you will get neither Vulkan, nor Skia Graphite working !!!
!!! RawDraw with Vulkan "works" but you'll get content with all text disappeared !!!
Last edited by chaos-dremel (2024-11-20 16:36:36)
Offline
I got hardware acceleration to work, and playing upto 4K@60fps videos on YouTube, Netflix, Jellyfin... all seem to show up on `chrome://media-internals/` with `VaapiVideoDecoder` as the decoder.
Issue really only steps in on 8k videos, where the video buffers every 2-3 seconds, whereas there is a smooth playback on Windows. Media Internals report the decoder as `Dav1dVideoDecoder`. From what I can tell, both Jellyfin and YouTube is supplying a AV1 codec at 8k (7680x4320, 8k[16:9]). I've only gotten `Dav1dVideoDecoder` to be the decoder during any 8K stream, otherwise `VaapiVideoDecoder` is used.
vainfo:
==============================
Trying display: wayland
vainfo: VA-API version: 1.22 (libva 2.22.0)
vainfo: Driver version: Mesa Gallium driver 24.2.7-arch1.1 for AMD Radeon Graphics (radeonsi, renoir, LLVM 18.1.8, DRM 3.59, 6.11.7-zen1-1-zen)
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
chrome://gpu/:
Graphics Feature Status
==============================
* Canvas: Hardware accelerated
* Canvas out-of-process rasterization: Enabled
* Direct Rendering Display Compositor: Disabled
* Compositing: Hardware accelerated
* Multiple Raster Threads: Enabled
* OpenGL: Enabled
* Rasterization: Hardware accelerated on all pages
* Raw Draw: Disabled
* Skia Graphite: Disabled
* Video Decode: Hardware accelerated
* Video Encode: Hardware accelerated
* Vulkan: Enabled
* WebGL: Hardware accelerated
* WebGL2: Hardware accelerated
* WebGPU: Hardware accelerated
* WebNN: Enabled
Video Acceleration Information:
==============================
Decoding
Decode h264 baseline 64x64 to 4096x4096 pixels
Decode h264 main 64x64 to 4096x4096 pixels
Decode h264 high 64x64 to 4096x4096 pixels
Decode vp9 profile0 64x64 to 8192x4352 pixels
Decode vp9 profile2 64x64 to 8192x4352 pixels
Decode hevc main 64x64 to 8192x4352 pixels
Decode hevc main 10 64x64 to 8192x4352 pixels
Decode hevc main still-picture 64x64 to 8192x4352 pixels
Encoding
Encode h264 baseline 321x241 to 4096x2304 pixels, and/or 30.000 fps.
Encode h264 main 321x241 to 4096x2304 pixels, and/or 30.000 fps.
Encode h264 high 321x241 to 4096x2304 pixels, and/or 30.000 fps.
Offline
I got hardware acceleration to work, and playing upto 4K@60fps videos on YouTube, Netflix, Jellyfin... all seem to show up on `chrome://media-internals/` with `VaapiVideoDecoder` as the decoder.
Issue really only steps in on 8k videos, where the video buffers every 2-3 seconds, whereas there is a smooth playback on Windows. Media Internals report the decoder as `Dav1dVideoDecoder`. From what I can tell, both Jellyfin and YouTube is supplying a AV1 codec at 8k (7680x4320, 8k[16:9]). I've only gotten `Dav1dVideoDecoder` to be the decoder during any 8K stream, otherwise `VaapiVideoDecoder` is used.
Does Firefox work better on the same system?
Offline
Working Wayland + Ozone + Vulkan + Vaapi decode and encode with AMD!
--use-gl=angle
--use-angle=vulkan
--enable-features=Vulkan,VulkanFromANGLE,DefaultANGLEVulkan,AcceleratedVideoDecodeLinuxZeroCopyGL,AcceleratedVideoEncoder,VaapiIgnoreDriverChecks,UseMultiPlaneFormatForHardwareVideo
--ozone-platform-hint=auto
Tested on brave/chromium with 7900XTX and Radeon 880M (Strix Point) and RX Vega 7 (Renoir) fully working. On the first two 8k@60fps (AV1) Youtube with no dropped frames. It is imho a really big leap for Linux desktop since hardware acceleration increases performance and lowers power comsumption on a laptop in a BIG way!
Let's hope it will not break again and will be activated by default soon.
Offline