You are not logged in.

#401 2020-09-02 20:39:50

tmathmeyer
Member
From: Kirkland, WA
Registered: 2013-09-17
Posts: 20

Re: chromium: hardware video acceleration with VA-API

sadboi777 wrote:

Wow we have actual chromium devs in this forum. Man I love this distro. The decision to switch to AVGLE on chromium 85 on Linux is kinda weird as WebGL and other graphics acceleration also doesn't work now on Linux by default. --use-gl=desktop is a must rn.

I'd be careful, AVGLE is... something else.

I'm not on the graphics team, but my understanding is that the switch to ANGLE is to make it easier to write GL code that works across the multiple OS targets that chromium supports, which at this point includes I think two-four linux distros, multiple windows, chromeos, android, fuchsia, and probably a few more I don't even know about. I'm also not aware of ANGLE breaking webgl acceleration, but that might just be me not being cc'd on a bug, since that's not my team anyway.

liewkj wrote:

Using --use-gl=egl does not work for official extra/chromium because of the upstream bug. AUR chromium-vaapi patched it out for Wayland/EGL. Regardless of X.Org or Wayland session, --use-gl=egl simply doesn't work until the bug was fixed.

I don't think its safe to say that bug is going to be fixed any time soon, but I'll probably assign it to hiroh@ since it was his change in the first place. Using --use-gl=egl on linux is probably not going to get much official patch support unfortunately.

Offline

#402 2020-09-05 10:29:07

frankieboy
Member
Registered: 2009-04-12
Posts: 65

Re: chromium: hardware video acceleration with VA-API

Hi All,

Just to let you know, the latest version of chromium (85.0.4183.83) runs perfectly with hardware video acceleration under gnome wayland with the --use-gl=egl switch, on a nvidia optimus laptop (dell xps 15 7590) using the intel graphic card, battery consumption is much lower (12 mw) than firefox (24-30 mw) with webrender playing a 4k youtube video. It's perfect, thank you for the developers and packagers.

Offline

#403 2020-09-08 16:13:16

digitalone
Member
Registered: 2011-08-19
Posts: 350

Re: chromium: hardware video acceleration with VA-API

I'm surprised to notice that the latest version of Chromium is using lower cpu resources while gpu decoding is enabled compared to Firefox.

How is this possible? I didn't use Chromium from July which was producing stuttering on 1080p60 h264 videos while other formats were playing smooth.

Now on Gnome Wayland with my old radeon card it's only working with use-gl=desktop, with both upstream and liewkj versions.

Maybe because that flag is disabling Angle? Anyway, use-gl=egl never worked to me since I began using Wayland in June.

Last edited by digitalone (2020-09-08 19:59:09)

Offline

#404 2020-09-12 06:52:33

digitalone
Member
Registered: 2011-08-19
Posts: 350

Re: chromium: hardware video acceleration with VA-API

use-gl=desktop

GL_VENDOR X.Org

AMD KABINI (DRM 3.38.0, 5.8.8-xanmod1-1, LLVM 10.0.1)

4.6 (Core Profile) Mesa 20.1.7

GL_AMD_conservative_depth GL_AMD_depth_clamp_separate GL_AMD_draw_buffers_blend GL_AMD_framebuffer_multisample_advanced GL_AMD_gpu_shader_int64 GL_AMD_multi_draw_indirect GL_AMD_performance_monitor GL_AMD_pinned_memory GL_AMD_query_buffer_object GL_AMD_seamless_cubemap_per_texture GL_AMD_shader_stencil_export GL_AMD_shader_trinary_minmax GL_AMD_texture_texture4 GL_AMD_vertex_shader_layer GL_AMD_vertex_shader_viewport_index GL_ANGLE_texture_compression_dxt3 GL_ANGLE_texture_compression_dxt5 GL_ARB_ES2_compatibility GL_ARB_ES3_1_compatibility GL_ARB_ES3_2_compatibility 
GL_ARB_ES3_compatibility GL_ARB_arrays_of_arrays GL_ARB_base_instance GL_ARB_bindless_texture GL_ARB_blend_func_extended GL_ARB_buffer_storage GL_ARB_clear_buffer_object GL_ARB_clear_texture GL_ARB_clip_control GL_ARB_color_buffer_float GL_ARB_compressed_texture_pixel_storage GL_ARB_compute_shader GL_ARB_compute_variable_group_size GL_ARB_conditional_render_inverted GL_ARB_conservative_depth GL_ARB_copy_buffer GL_ARB_copy_image GL_ARB_cull_distance GL_ARB_debug_output GL_ARB_depth_buffer_float GL_ARB_depth_clamp GL_ARB_derivative_control GL_ARB_direct_state_access GL_ARB_draw_buffers GL_ARB_draw_buffers_blend GL_ARB_draw_elements_base_vertex 
GL_ARB_draw_indirect GL_ARB_draw_instanced GL_ARB_enhanced_layouts GL_ARB_explicit_attrib_location GL_ARB_explicit_uniform_location GL_ARB_fragment_coord_conventions GL_ARB_fragment_layer_viewport GL_ARB_fragment_shader GL_ARB_framebuffer_no_attachments GL_ARB_framebuffer_object GL_ARB_framebuffer_sRGB GL_ARB_get_program_binary GL_ARB_get_texture_sub_image GL_ARB_gl_spirv GL_ARB_gpu_shader5 GL_ARB_gpu_shader_fp64 GL_ARB_gpu_shader_int64 GL_ARB_half_float_pixel GL_ARB_half_float_vertex GL_ARB_indirect_parameters GL_ARB_instanced_arrays GL_ARB_internalformat_query GL_ARB_internalformat_query2 GL_ARB_invalidate_subdata GL_ARB_map_buffer_alignment 
GL_ARB_map_buffer_range GL_ARB_multi_bind GL_ARB_multi_draw_indirect GL_ARB_occlusion_query2 GL_ARB_parallel_shader_compile GL_ARB_pipeline_statistics_query GL_ARB_pixel_buffer_object GL_ARB_point_sprite GL_ARB_polygon_offset_clamp GL_ARB_program_interface_query GL_ARB_provoking_vertex GL_ARB_query_buffer_object GL_ARB_robust_buffer_access_behavior GL_ARB_robustness GL_ARB_sample_shading GL_ARB_sampler_objects GL_ARB_seamless_cube_map GL_ARB_seamless_cubemap_per_texture GL_ARB_separate_shader_objects GL_ARB_shader_atomic_counter_ops GL_ARB_shader_atomic_counters GL_ARB_shader_ballot GL_ARB_shader_bit_encoding GL_ARB_shader_clock 
GL_ARB_shader_draw_parameters GL_ARB_shader_group_vote GL_ARB_shader_image_load_store GL_ARB_shader_image_size GL_ARB_shader_objects GL_ARB_shader_precision GL_ARB_shader_stencil_export GL_ARB_shader_storage_buffer_object GL_ARB_shader_subroutine GL_ARB_shader_texture_image_samples GL_ARB_shader_texture_lod GL_ARB_shader_viewport_layer_array GL_ARB_shading_language_420pack GL_ARB_shading_language_include GL_ARB_shading_language_packing GL_ARB_sparse_buffer GL_ARB_spirv_extensions GL_ARB_stencil_texturing GL_ARB_sync GL_ARB_tessellation_shader GL_ARB_texture_barrier GL_ARB_texture_buffer_object 
GL_ARB_texture_buffer_object_rgb32 GL_ARB_texture_buffer_range GL_ARB_texture_compression_bptc GL_ARB_texture_compression_rgtc GL_ARB_texture_cube_map_array GL_ARB_texture_filter_anisotropic GL_ARB_texture_float GL_ARB_texture_gather GL_ARB_texture_mirror_clamp_to_edge GL_ARB_texture_multisample GL_ARB_texture_non_power_of_two GL_ARB_texture_query_levels GL_ARB_texture_query_lod GL_ARB_texture_rectangle GL_ARB_texture_rg GL_ARB_texture_rgb10_a2ui GL_ARB_texture_stencil8 GL_ARB_texture_storage GL_ARB_texture_storage_multisample GL_ARB_texture_swizzle GL_ARB_texture_view GL_ARB_timer_query 
GL_ARB_transform_feedback2 GL_ARB_transform_feedback3 GL_ARB_transform_feedback_instanced GL_ARB_transform_feedback_overflow_query GL_ARB_uniform_buffer_object GL_ARB_vertex_array_bgra GL_ARB_vertex_array_object GL_ARB_vertex_attrib_64bit GL_ARB_vertex_attrib_binding GL_ARB_vertex_buffer_object GL_ARB_vertex_shader GL_ARB_vertex_type_10f_11f_11f_rev GL_ARB_vertex_type_2_10_10_10_rev GL_ARB_viewport_array GL_ATI_blend_equation_separate GL_ATI_meminfo GL_ATI_texture_float GL_ATI_texture_mirror_once GL_EXT_EGL_image_storage GL_EXT_EGL_sync GL_EXT_abgr GL_EXT_blend_equation_separate GL_EXT_depth_bounds_test GL_EXT_draw_buffers2 
GL_EXT_draw_instanced GL_EXT_framebuffer_blit GL_EXT_framebuffer_multisample GL_EXT_framebuffer_multisample_blit_scaled GL_EXT_framebuffer_object GL_EXT_framebuffer_sRGB GL_EXT_memory_object GL_EXT_memory_object_fd GL_EXT_packed_depth_stencil GL_EXT_packed_float GL_EXT_pixel_buffer_object GL_EXT_polygon_offset_clamp GL_EXT_provoking_vertex GL_EXT_semaphore GL_EXT_semaphore_fd GL_EXT_shader_image_load_formatted GL_EXT_shader_image_load_store GL_EXT_shader_integer_mix GL_EXT_shader_samples_identical GL_EXT_texture_array GL_EXT_texture_compression_dxt1 GL_EXT_texture_compression_rgtc GL_EXT_texture_compression_s3tc 
GL_EXT_texture_filter_anisotropic GL_EXT_texture_integer GL_EXT_texture_mirror_clamp GL_EXT_texture_sRGB GL_EXT_texture_sRGB_R8 GL_EXT_texture_sRGB_decode GL_EXT_texture_shadow_lod GL_EXT_texture_shared_exponent GL_EXT_texture_snorm GL_EXT_texture_swizzle GL_EXT_timer_query GL_EXT_transform_feedback GL_EXT_vertex_array_bgra GL_EXT_vertex_attrib_64bit GL_EXT_window_rectangles GL_IBM_multimode_draw_arrays GL_KHR_blend_equation_advanced GL_KHR_context_flush_control GL_KHR_debug GL_KHR_no_error GL_KHR_parallel_shader_compile GL_KHR_robust_buffer_access_behavior GL_KHR_robustness GL_KHR_texture_compression_astc_ldr 
GL_KHR_texture_compression_astc_sliced_3d GL_MESA_framebuffer_flip_y GL_MESA_pack_invert GL_MESA_shader_integer_functions GL_MESA_texture_signed_rgba GL_NVX_gpu_memory_info GL_NV_alpha_to_coverage_dither_control GL_NV_conditional_render GL_NV_copy_image GL_NV_depth_clamp GL_NV_packed_depth_stencil GL_NV_texture_barrier GL_NV_vdpau_interop GL_OES_EGL_image GL_S3_s3tc

use-gl=egl

GL_VENDOR X.Org

AMD KABINI (DRM 3.38.0, 5.8.8-xanmod1-1, LLVM 10.0.1)

OpenGL ES 3.2 Mesa 20.1.7

GL_EXT_blend_minmax GL_EXT_multi_draw_arrays GL_EXT_texture_filter_anisotropic GL_EXT_texture_compression_s3tc GL_EXT_texture_compression_dxt1 GL_EXT_texture_compression_rgtc GL_EXT_texture_format_BGRA8888 GL_OES_compressed_ETC1_RGB8_texture GL_OES_depth24 GL_OES_element_index_uint GL_OES_fbo_render_mipmap GL_OES_mapbuffer GL_OES_rgb8_rgba8 GL_OES_standard_derivatives GL_OES_stencil8 GL_OES_texture_3D GL_OES_texture_float GL_OES_texture_float_linear GL_OES_texture_half_float GL_OES_texture_half_float_linear GL_OES_texture_npot GL_OES_vertex_half_float GL_EXT_draw_instanced 
GL_EXT_texture_sRGB_decode GL_OES_EGL_image GL_OES_depth_texture GL_AMD_performance_monitor GL_OES_packed_depth_stencil GL_EXT_texture_type_2_10_10_10_REV GL_NV_conditional_render GL_OES_get_program_binary GL_APPLE_texture_max_level GL_EXT_discard_framebuffer GL_EXT_read_format_bgra GL_EXT_frag_depth GL_NV_fbo_color_attachments GL_OES_EGL_image_external GL_OES_EGL_sync GL_OES_vertex_array_object GL_OES_viewport_array GL_ANGLE_texture_compression_dxt3 GL_ANGLE_texture_compression_dxt5 GL_EXT_occlusion_query_boolean GL_EXT_robustness GL_EXT_texture_rg GL_EXT_unpack_subimage GL_NV_draw_buffers GL_NV_read_buffer 
GL_NV_read_depth GL_NV_read_depth_stencil GL_NV_read_stencil GL_EXT_draw_buffers GL_EXT_map_buffer_range GL_KHR_debug GL_KHR_robustness GL_KHR_texture_compression_astc_ldr GL_NV_pixel_buffer_object GL_OES_depth_texture_cube_map GL_OES_required_internalformat GL_OES_surfaceless_context GL_EXT_color_buffer_float GL_EXT_sRGB_write_control GL_EXT_separate_shader_objects GL_EXT_shader_implicit_conversions GL_EXT_shader_integer_mix GL_EXT_tessellation_point_size GL_EXT_tessellation_shader GL_ANDROID_extension_pack_es31a GL_EXT_base_instance GL_EXT_compressed_ETC1_RGB8_sub_texture GL_EXT_copy_image 
GL_EXT_draw_buffers_indexed GL_EXT_draw_elements_base_vertex GL_EXT_gpu_shader5 GL_EXT_polygon_offset_clamp GL_EXT_primitive_bounding_box GL_EXT_render_snorm GL_EXT_shader_io_blocks GL_EXT_texture_border_clamp GL_EXT_texture_buffer GL_EXT_texture_cube_map_array GL_EXT_texture_norm16 GL_EXT_texture_view GL_KHR_blend_equation_advanced GL_KHR_context_flush_control GL_KHR_robust_buffer_access_behavior GL_NV_image_formats GL_OES_copy_image GL_OES_draw_buffers_indexed GL_OES_draw_elements_base_vertex GL_OES_gpu_shader5 GL_OES_primitive_bounding_box GL_OES_sample_shading GL_OES_sample_variables GL_OES_shader_io_blocks 
GL_OES_shader_multisample_interpolation GL_OES_tessellation_point_size GL_OES_tessellation_shader GL_OES_texture_border_clamp GL_OES_texture_buffer GL_OES_texture_cube_map_array GL_OES_texture_stencil8 GL_OES_texture_storage_multisample_2d_array GL_OES_texture_view GL_EXT_blend_func_extended GL_EXT_buffer_storage GL_EXT_float_blend GL_EXT_geometry_point_size GL_EXT_geometry_shader GL_EXT_shader_samples_identical GL_KHR_no_error GL_KHR_texture_compression_astc_sliced_3d GL_OES_EGL_image_external_essl3 GL_OES_geometry_point_size GL_OES_geometry_shader GL_OES_shader_image_atomic GL_EXT_clip_cull_distance GL_EXT_disjoint_timer_query 
GL_EXT_texture_compression_s3tc_srgb GL_EXT_window_rectangles GL_MESA_shader_integer_functions GL_EXT_clip_control GL_EXT_memory_object GL_EXT_memory_object_fd GL_EXT_semaphore GL_EXT_semaphore_fd GL_EXT_texture_compression_bptc GL_KHR_parallel_shader_compile GL_NV_alpha_to_coverage_dither_control GL_AMD_framebuffer_multisample_advanced GL_EXT_EGL_image_storage GL_EXT_texture_sRGB_R8 GL_EXT_texture_shadow_lod GL_MESA_framebuffer_flip_y GL_EXT_depth_clamp GL_EXT_texture_query_lod

use-gl not specified

GL_VENDOR Google Inc.

ANGLE (X.Org, AMD KABINI (DRM 3.38.0, 5.8.8-xanmod1-1, LLVM 10.0.1), OpenGL 4.6 core)

OpenGL ES 2.0.0 (ANGLE 2.1.0.unknown hash)

GL_ANGLE_base_vertex_base_instance GL_ANGLE_client_arrays GL_ANGLE_depth_texture GL_ANGLE_explicit_context GL_ANGLE_explicit_context_gles1 GL_ANGLE_framebuffer_blit GL_ANGLE_framebuffer_multisample GL_ANGLE_instanced_arrays GL_ANGLE_memory_size GL_ANGLE_multi_draw GL_ANGLE_multiview_multisample GL_ANGLE_program_cache_control GL_ANGLE_provoking_vertex GL_ANGLE_request_extension GL_ANGLE_robust_client_memory GL_ANGLE_texture_compression_dxt3 GL_ANGLE_texture_compression_dxt5 GL_ANGLE_texture_external_update GL_ANGLE_texture_rectangle GL_ANGLE_translated_shader_source GL_APPLE_clip_distance GL_ARB_sync 
GL_CHROMIUM_bind_generates_resource GL_CHROMIUM_bind_uniform_location GL_CHROMIUM_color_buffer_float_rgb GL_CHROMIUM_color_buffer_float_rgba GL_CHROMIUM_copy_texture GL_CHROMIUM_lose_context GL_CHROMIUM_sync_query GL_EXT_blend_minmax GL_EXT_color_buffer_half_float GL_EXT_debug_marker GL_EXT_discard_framebuffer GL_EXT_disjoint_timer_query GL_EXT_draw_buffers GL_EXT_draw_elements_base_vertex GL_EXT_float_blend GL_EXT_frag_depth GL_EXT_gpu_shader5 GL_EXT_instanced_arrays GL_EXT_map_buffer_range GL_EXT_memory_object GL_EXT_memory_object_fd GL_EXT_multisample_compatibility GL_EXT_occlusion_query_boolean 
GL_EXT_read_format_bgra GL_EXT_robustness GL_EXT_sRGB GL_EXT_sRGB_write_control GL_EXT_semaphore GL_EXT_semaphore_fd GL_EXT_shader_texture_lod GL_EXT_texture_compression_bptc GL_EXT_texture_compression_dxt1 GL_EXT_texture_compression_rgtc GL_EXT_texture_compression_s3tc_srgb GL_EXT_texture_cube_map_array GL_EXT_texture_filter_anisotropic GL_EXT_texture_format_BGRA8888 GL_EXT_texture_rg GL_EXT_texture_sRGB_decode GL_EXT_texture_storage GL_EXT_unpack_subimage GL_KHR_debug GL_KHR_parallel_shader_compile GL_KHR_texture_compression_astc_ldr GL_KHR_texture_compression_astc_sliced_3d GL_NV_depth_buffer_float2 GL_NV_fence 
GL_NV_pack_subimage GL_NV_pixel_buffer_object GL_NV_read_depth GL_NV_read_stencil GL_NV_shader_noperspective_interpolation GL_OES_compressed_EAC_R11_signed_texture GL_OES_compressed_EAC_R11_unsigned_texture GL_OES_compressed_EAC_RG11_signed_texture GL_OES_compressed_EAC_RG11_unsigned_texture GL_OES_compressed_ETC1_RGB8_texture GL_OES_compressed_ETC2_RGB8_texture GL_OES_compressed_ETC2_RGBA8_texture GL_OES_compressed_ETC2_punchthroughA_RGBA8_texture GL_OES_compressed_ETC2_punchthroughA_sRGB8_alpha_texture GL_OES_compressed_ETC2_sRGB8_alpha8_texture 
GL_OES_compressed_ETC2_sRGB8_texture GL_OES_depth24 GL_OES_depth32 GL_OES_depth_texture GL_OES_draw_elements_base_vertex GL_OES_element_index_uint GL_OES_fbo_render_mipmap GL_OES_get_program_binary GL_OES_mapbuffer GL_OES_packed_depth_stencil GL_OES_rgb8_rgba8 GL_OES_standard_derivatives GL_OES_surfaceless_context GL_OES_texture_3D GL_OES_texture_border_clamp GL_OES_texture_cube_map_array GL_OES_texture_float GL_OES_texture_float_linear GL_OES_texture_half_float GL_OES_texture_half_float_linear GL_OES_texture_npot GL_OES_vertex_array_object GL_WEBGL_video_texture

So use-gl disables ANGLE and I confirm `desktop` is the only option enabling hardware acceleration on my system with Gnome Wayland.

Unfortunately, sometime I keep getting stuttering on 1080p60 h264 playback while it's not happening in Firefox, but generally Firefox uses more cpu while hardware decoding is enabled, even on lower formats.

Hardware decoding is good on Firefox on every site I tried, except on Twitch where it stops randomly. The website itself is having compatibility issues with Firefox while that's not happening with Chromium.

Offline

#405 2020-09-26 18:09:55

blispx
Member
Registered: 2017-11-29
Posts: 53

Re: chromium: hardware video acceleration with VA-API

I can't compile chromium-vaapi, gn from official repo

ERROR at //third_party/webrtc/BUILD.gn:417:12: Unsupported value in libs.
  libs = [ "Foundation.framework" ]
           ^---------------------
Use frameworks to list framework dependencies.
See //third_party/webrtc/webrtc.gni:318:22: which caused the file to be included.
rtc_prod_configs = [ webrtc_root + ":rtc_prod_config" ]

Offline

#406 2020-09-27 07:05:19

foutrelis
Developer
From: Athens, Greece
Registered: 2008-07-28
Posts: 705
Website

Re: chromium: hardware video acceleration with VA-API

blispx wrote:

I can't compile chromium-vaapi, gn from official repo

extra/gn is currently targeting Chromium 86. It's usually backward compatible but it does seem to have broken Chromium<86 builds.

As an immediate fix, you can change the gn dependency to gn-m85 (and the "gn gen ..." call to "gn-m85 gen ...") to build Chromium 85.

Offline

#407 2020-09-27 08:04:41

blispx
Member
Registered: 2017-11-29
Posts: 53

Re: chromium: hardware video acceleration with VA-API

wow it works thanks so much

edit

HW in chromium-vaapi works for some time on nvidia, after some time gpu_compositing turns off, it seems it is not the fault of the patches but of the chromium code for the angle:

[48072:48072:0928/235931.087235:ERROR:gl_surface_glx.cc(621)] : XGetWindowAttributes failed for window 25166037.
[48072:48332:0928/235931.119257:ERROR:x11_software_bitmap_presenter.cc(136)] : XGetWindowAttributes failed for window 25166037

Last edited by blispx (2020-09-28 22:01:39)

Offline

#408 2020-09-28 08:19:07

DAC324
Member
Registered: 2020-03-12
Posts: 80

Re: chromium: hardware video acceleration with VA-API

foutrelis wrote:
blispx wrote:

I can't compile chromium-vaapi, gn from official repo

extra/gn is currently targeting Chromium 86. It's usually backward compatible but it does seem to have broken Chromium<86 builds.

As an immediate fix, you can change the gn dependency to gn-m85 (and the "gn gen ..." call to "gn-m85 gen ...") to build Chromium 85.

Please let me kindly ask you for a hint. How do I accomplish that for a package downloaded from the repo? I assume that all files are overwritten anyway when I run the package manager, aren't they?

Plus,I was only able to find 'gn' in the 'makedepends' section of PKGBUILD.

As expected, if I change the gn dependency and the gn call as advised, I get

makepkg --syncdeps
==> Making package: chromium-vaapi 85.0.4183.121-1 (Mon Sep 28 11:43:28 2020)
==> Checking runtime dependencies...
==> Checking buildtime dependencies...
==> Installing missing dependencies...
error: target not found: gn-m85
==> ERROR: 'pacman' failed to install missing dependencies.
==> Missing dependencies:
  -> gn-m85
==> ERROR: Could not resolve all dependencies.

as a consequence. So it looks like there is something missing.

There is, btw. a package named chromium-dev in AUR which appears to be based on Chromium 87.
Hence, it should avoid at least that gn related error.

But how will it be possible to include vaapi as well as vdpau support in this package?

Last edited by DAC324 (2020-09-28 11:17:20)

Offline

#409 2020-10-03 06:17:00

xuanrui
Member
Registered: 2018-09-27
Posts: 52

Re: chromium: hardware video acceleration with VA-API

blispx wrote:

wow it works thanks so much

edit

HW in chromium-vaapi works for some time on nvidia, after some time gpu_compositing turns off, it seems it is not the fault of the patches but of the chromium code for the angle:

[48072:48072:0928/235931.087235:ERROR:gl_surface_glx.cc(621)] : XGetWindowAttributes failed for window 25166037.
[48072:48332:0928/235931.119257:ERROR:x11_software_bitmap_presenter.cc(136)] : XGetWindowAttributes failed for window 25166037

I encounter this bug too. It seems that --disable-gpu-driver-bug-workarounds fixes it?

UPDATE: OK, not really. It seems that Ubuntu has a fix? (https://bugs.launchpad.net/ubuntu/+sour … ug/1893415)

Last edited by xuanrui (2020-10-03 06:55:20)

Online

#410 2020-10-04 10:12:11

blispx
Member
Registered: 2017-11-29
Posts: 53

Re: chromium: hardware video acceleration with VA-API

xuanrui wrote:

UPDATE: OK, not really. It seems that Ubuntu has a fix? (https://bugs.launchpad.net/ubuntu/+sour … ug/1893415)

Bingo, maybe it will work, I'll check later, thanks

for now, the only version that works with --use-gl=desktop is 87 dev

edit

@xuanrui this patch is for snap,  she won't do anything here

Last edited by blispx (2020-10-06 11:45:53)

Offline

#411 2020-10-06 05:26:40

liewkj
Member
Registered: 2019-07-08
Posts: 210

Re: chromium: hardware video acceleration with VA-API

Really BAD news for AMD!
The just-released mesa-20.2.0, libva-mesa-drivers radeonsi is busted. Chromium-vaapi crashed hard when anything touched VA-API in the browser and dmesg was flooded with amdgpu/iommu error and timeout. Went back to 20.1.8 and everything was nice and working.
However, gstreamer-vaapi works with libva-mesa-drivers 20.2.0 through gst-play-1.0, so it is hard to tell who to blame at this point, Chromium or MESA VA. Intel GPUs do not use MESA VA drivers, they maintain their own drivers and everything works fine with chromium-vaapi, gstreamer-vaapi and mesa-20.2.0. It is really just AMD users are impacted.

Nouveau also requires libva-mesa-drivers, I am going to check it out next to figure out if this is just radeonsi or affects all flavors of MESA VA drivers. This could be something that will take a long time to resolve, unfortunately....

Offline

#412 2020-10-06 08:53:11

TheWeirdDev
Member
Registered: 2020-10-06
Posts: 11

Re: chromium: hardware video acceleration with VA-API

blispx wrote:

wow it works thanks so much

edit

HW in chromium-vaapi works for some time on nvidia, after some time gpu_compositing turns off, it seems it is not the fault of the patches but of the chromium code for the angle:

[48072:48072:0928/235931.087235:ERROR:gl_surface_glx.cc(621)] : XGetWindowAttributes failed for window 25166037.
[48072:48332:0928/235931.119257:ERROR:x11_software_bitmap_presenter.cc(136)] : XGetWindowAttributes failed for window 25166037

I have this problem on chromium 85. gpu_compositing turns off whenever i drag and drop text

Offline

#413 2020-10-06 12:00:40

blispx
Member
Registered: 2017-11-29
Posts: 53

Re: chromium: hardware video acceleration with VA-API

What do you have GTK, QT or other?

it seems to me that GTK3 is incompatible with chromium

Last edited by blispx (2020-10-06 15:43:49)

Offline

#414 2020-10-07 07:45:07

TheWeirdDev
Member
Registered: 2020-10-06
Posts: 11

Re: chromium: hardware video acceleration with VA-API

blispx wrote:

What do you have GTK, QT or other?

it seems to me that GTK3 is incompatible with chromium

I use Gtk3

Offline

#415 2020-10-07 15:39:47

blispx
Member
Registered: 2017-11-29
Posts: 53

Re: chromium: hardware video acceleration with VA-API

like i said it's not a problem with vaapi patch but with the angle support on the chromium side

Offline

#416 2020-10-07 21:15:40

liewkj
Member
Registered: 2019-07-08
Posts: 210

Re: chromium: hardware video acceleration with VA-API

AUR chromium-vaapi was not built with ANGLE. Chromium 85 ANGLE does not support VA-API at all on Linux. ANGLE support for VA-API will arrive by Chromium 86, we shall see.

ANGLE is just an OpenGL ES 2.0 middleware abstraction so that the upper level software always talk OpenGL ES 2.0 while ANGLE manages the lower level display/graphics implementation for ChromeOS, Windows and Linux, or any re-targetable platforms in future. ANGLE exposes several undocumented, unregistered extensions and sometimes the upper level software simply forgot about it and use them without considering non-ANGLE implementation as with `--use-gl=desktop` and `--use-gl=egl`. This is when things break.

It seems that ANGLE has been shaping up over the years and desktop GL and EGL are en-route for deprecation.

Offline

#417 2020-10-07 22:34:35

blispx
Member
Registered: 2017-11-29
Posts: 53

Re: chromium: hardware video acceleration with VA-API

chromium 86 no longer needs patching, supports vaapi, let's see if it works stably

Offline

#418 2020-10-08 06:37:54

TheWeirdDev
Member
Registered: 2020-10-06
Posts: 11

Re: chromium: hardware video acceleration with VA-API

I updated chromium to v86 and the drag and drop bug is fixed.
But now i get:

Video Decode: Software only. Hardware acceleration disabled

and

Accelerated video decode has been disabled, either via blocklist, about:flags or the command line.
Disabled Features: video_decode

I removed all command line arguments and reset flags but i still get the same error. Maybe because i'm using Nvidia?

Last edited by TheWeirdDev (2020-10-08 06:47:28)

Offline

#419 2020-10-08 08:26:38

wooque
Member
Registered: 2016-10-13
Posts: 14

Re: chromium: hardware video acceleration with VA-API

I removed --ignore-gpu-blacklist and --use-gl=desktop, and added --enable-accelerated-video-decode to get acceleration on v86.

Offline

#420 2020-10-08 09:06:58

TheWeirdDev
Member
Registered: 2020-10-06
Posts: 11

Re: chromium: hardware video acceleration with VA-API

wooque wrote:

I removed --ignore-gpu-blacklist and --use-gl=desktop, and added --enable-accelerated-video-decode to get acceleration on v86.

Thanks! Adding that option worked.

Offline

#421 2020-10-08 09:24:46

coxackie
Member
Registered: 2019-11-10
Posts: 8

Re: chromium: hardware video acceleration with VA-API

For NVIDIA, added both added --enable-accelerated-video-decode and --ignore-gpu-blocklist for my system to work. Using chromium 86 and libva-vdpau-driver-chromium; but only getting h264 (baseline, main, high) decoding. Is this normal, or should there also be v8 / v9 entries?

Offline

#422 2020-10-08 10:45:37

blispx
Member
Registered: 2017-11-29
Posts: 53

Re: chromium: hardware video acceleration with VA-API

for VP9 support build libva-vdpau-driver-vp9 with AUR

unfortunately at this level only VP9 profile 0 will be supported

Offline

#423 2020-10-08 14:34:48

xuanrui
Member
Registered: 2018-09-27
Posts: 52

Re: chromium: hardware video acceleration with VA-API

Hmmm, I still need --use-gl=desktop, otherwise I get this error:

 [96685:96685:1008/233232.904355:ERROR:gl_implementation.cc(286)] : Failed to load /usr/lib/chromium/libGLESv2.so: /usr/lib/chromium/libGLESv2.so: cannot open shared object file: No such file or directory

I'm using the NVIDIA drivers.

EDIT: just realized I'm using chromium-vaapi not chromium. which seems to be actually the broken one now! chromium works just fine, so just stick to extra/chromium.

Last edited by xuanrui (2020-10-08 15:37:40)

Online

#424 2020-10-09 23:59:42

liewkj
Member
Registered: 2019-07-08
Posts: 210

Re: chromium: hardware video acceleration with VA-API

Some updates.....

Chromium 86 defaults to ANGLE, the Google's OpenGL ES 2.0 emulation layer. It seems that ANGLE default to desktop GL backend ie. GLX, but there is command line argument that allows that to be changed, `--use-angle=gles` or `--use-angle=gl-egl`. I am not sure what the difference between the 2 but they don't seem to work as well as GLX.

Since the ANGLE default backend is GLX, it failed to work on Wayland session (through XWayland) for VA drivers without DRI3, such as the Intel i965 and iHD. It is the same problem that Display handle obtained from vaGetDisplayGLX() cannot be used on Wayland session. MESA VA drivers support DRI3 so they work fine with ANGLE GLX backend. Unfortunately, MESA 20.2.0 screwed up radeonsi, so for VA-API to work for radeonsi on Wayland session one should defer MESA upgrade and stick to 20.1.8 (notably mesa and libva-mesa-driver).

Good news for NVIDIA, the upstream commit that enabled VA-API for ANGLE somehow removed VPP for no reason. It broke the native EGL code path which is essential for Wayland and so helped NVIDIA VDPAU wrapper which lacks implementation for VPP. Chromium VA-API now works on NVIDIA GPUs without the need to go for AUR.

I updated AUR chromium-vaapi to restore VA-API for Wayland/EGL while keeping NVIDIA support intact. VA-API on Wayland works for Intel and MESA VA drivers (nouveau, r600). Hopefully, radeonsi issues would be resolved in future.

It is likely that upstream Chromium will ignore Wayland support and continue tearing EGL code path apart en-route for deprecation. If this is the case, then it is very unfortunate and I hope not.

Offline

#425 2020-10-10 17:53:04

digitalone
Member
Registered: 2011-08-19
Posts: 350

Re: chromium: hardware video acceleration with VA-API

liewkj wrote:

However, gstreamer-vaapi works with libva-mesa-drivers 20.2.0 through gst-play-1.0

On which hardware? AMD?

Anyway, the latest mesa is not causing issues on Firefox vaapi decoding (wayland).

Offline

Board footer

Powered by FluxBB