Page MenuHomeSolus

Update libplacebo to 3.120.2 & switch from glslang to shaderc
Needs ReviewPublic

Authored by aleksvor on Sat, Apr 3, 3:08 PM.

Details

Reviewers
None
Group Reviewers
Triage Team
Summary

Summarized changelog for 3.120.2:

  • Changes:
    • pl_dispatch no longer grows infinitely, but prunes stale cache entries after a certain threshold.
    • Improve logging of GPU capabilities (including format capabilities).
  • Fixes and performance improvements:
    • Omit redundant identity matrices in pl_shader_decode_color.
    • Improve handling of asynchronous texture uploads in utils/libav.h.

Full changelog here.

Summarized changelog for 3.120.1:

  • Changes:
    • Hexadecimal strings in custom shaders may now include whitespace.
    • Added 16-bit half float formats to the dummy pl_gpu.
  • Fixes and performance improvements:
    • Fixed an integer overflow in a texture bounds check.
    • Fixed some minor issues with various outdated comments.

Full changelog here.

Summarized changelog for 3.120.0:

  • Additions:
    • Add asynchronous GPU callbacks, specifically to pl_tex_transfer, allowing for non-blocking host memory transfer operations.
    • Add pl_shared_mem.stride_w/h to control dmabuf pitch.
    • Add pl_render_image_mix to blend multiple frames into a single output image, given relative timestamp information.
    • Add the pl_filter_mitchell_clamp filter preset.
    • Add pl_render_params.preserve_mixing_cache to speed up redraws after renderer size changes when frame mixing is active.
    • Add <libplacebo/utils/dav1d.h> to help with Dav1dPicture mapping.
    • Implement PL_HANDLE_HOST_PTR for the OpenGL backend.
    • Implement DRM format modifiers for Vulkan.
    • Add a new field pl_fmt.modifiers for DRM format modifier negotiation.
    • Add new header <libplacebo/shaders/lut.h> to load custom LUTs (currently only supporting the .cube format).
    • Add a new header <libplacebo/utils/frame_queue.h> to assist in taking a stream of (Frame, PTS) pairs as well as a list of VSync times and turning them into a stream of pl_frame_mix structs.
  • Changes:
    • pl_3dlut_update/apply have been renamed to pl_icc_update/apply and moved to a (conditionally installed) new header <libplacebo/shaders/icc.h>.
  • Fixes and performance improvements:
    • Fix buffer overflow in custom shader STORAGE blocks.
    • Actually enable shader subgroup operations for HDR peak detection. (packager's note: we already had this patched)
    • Fix locale dependence of shader parsing primitives.
    • Fix wrong color space selection in pl_vulkan_create_swapchain.
    • Fix suboptimal mutex destruction code.
    • Skip peak detection when outputting to HDR displays.
    • Avoid redundant scaling passes when scaling anamorphic content.
    • Merge similar planes before dispatching heavy shaders (e.g. debanding, hooks).
    • Entirely avoid processing unneeded components when dispatching scalers.
    • Avoid using more components than necessary for intermediate FBOs.
    • Avoid thrashing the shader cache when reinitializing OpenGL FBOs.
    • Fix undefined behaviour / GPU hangs in HDR peak detection shader.
    • Fix handling of custom shader COMPUTE blocks.
    • Correctly apply hue and saturation controls for non-YCbCr color spaces.

Full changelog here.

Packaging change:

  • Switch shader compiler backend to shaderc, as it's preferred by upstream and provides more stable API than glslang.

Depends on D10741.

Test Plan
  1. Rebuilt mpv and vlc against it.
  2. Tested Vulkan video output in mpv using mpv --vo=gpu --gpu-api=vulkan.
  3. Tested HDR-to-SDR gamut conversion in VLC by watching HDR video on display without "real" HDR support.

Diff Detail

Repository
R4851 libplacebo
Branch
master
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 69
Build 69: arc lint + arc unit

Event Timeline

aleksvor created this revision.Sat, Apr 3, 3:08 PM
aleksvor requested review of this revision.Sat, Apr 3, 3:08 PM
aleksvor edited the summary of this revision. (Show Details)Sat, Apr 3, 3:12 PM
aleksvor updated this revision to Diff 26009.Sat, Apr 3, 3:13 PM

Remove unneeded patch.

aleksvor updated this revision to Diff 26026.Tue, Apr 6, 7:11 AM

Update to 3.120.1.

aleksvor retitled this revision from Update libplacebo to 3.120.0 & switch from glslang to shaderc to Update libplacebo to 3.120.1 & switch from glslang to shaderc.Tue, Apr 6, 7:14 AM
aleksvor edited the summary of this revision. (Show Details)
aleksvor updated this revision to Diff 26164.Mon, Apr 19, 10:36 AM

Update to 3.120.2.

aleksvor retitled this revision from Update libplacebo to 3.120.1 & switch from glslang to shaderc to Update libplacebo to 3.120.2 & switch from glslang to shaderc.Mon, Apr 19, 10:40 AM
aleksvor edited the summary of this revision. (Show Details)