Skip to content
Tags give the ability to mark specific points in history as being important
  • v6.338.2
    64c19545 · meson: bump fix version ·
    v6.338.2
    
    This release fixes a number of minor issues with v6.338.1, in particular
    a fix for the new caching subsystem when using custom cache callbacks.
    
    Fixes and performance improvements:
    - properly align AVFrame planes when using oddly-sized pixels
    - correct some reported GPU buffer size limits
    - properly report texture transfer failures
    - avoid ICC-related error spam
    - avoid using some deprecated APIs and syntax
    - fix pl_find_filter_* missing symbols
    - fix duplicate initialization of vulkan debug layers
    - fix assertion when using custom cache allocator API
    - avoid redundant scale shader variable declarations
    - avoid redundant linearization step when using sigmoid scaling
    - avoid generating redundant dependency on xxhash
    - fix possible integer overflow on 32-bit textures
    - fix cropped frame dimensions when using vulkan hwframes
    
  • v6.338.1
    2805a0d0 · meson: bump fix version ·
    v6.338.1
    
    This release fixes a number of minor issues with v6.338.0, as well as a
    major regression of the frame mixing code.
    
    Fixes and performance enhancements:
    - fix H.274 grain database PRNG
    - fix compilation on FreeBSD
    - fix unnatural peak detection flicker on mostly black samples
    - fix plplay 'Use detected luminance' checkbox
    - fix unnecessary recompilation when changing antiring strength
    - properly disable anti-ringing for non-negative filters
    - fix double-callback on sliced texture uploads
    - dispatch callback slightly sooner in pointer texture upload fallback
    - slightly improve saturation when tone mapping by large factors
    - various improvements to the benchmark
    - fix regression when frame mixing low FPS sources
    - update various misleading comments
    
  • v6.338.0
    v6.338.0
    
    This release focuses on several major "quality of life" improvements for
    downstream users. These include an all-new options system, a new unified cache
    layer, and a new filter configuration API, as well as improvements to tone and
    gamut mapping, scaling and HDR peak detection.
    
    The new options system greatly simplifies usage of the pl_render_params API,
    and allows saving/loading parameter presets at runtime, as well as exposing
    advanced options in a programmatic way.
    
    The new cache layer unifies the old dispatch/renderer/icc cache systems into a
    single file which can be more easily saved/loaded at runtime, and also includes
    support for internal size limits, book-keeping and garbage collection.
    
    The new filter API greatly simplifies the process of configuring custom filter
    kernels, and also augments each filter entry by extra metadata which can be
    used to make this API more understandable and simpler for end users. The
    default scalers have also been overhauled, and multiple scalers have been
    fixed, made faster, or otherwise improved.
    
    In addition to this, libplacebo now uses a custom GLSL preprocessor to
    significantly speed up the runtime generation of complex shaders, faster
    built-in functions for parsing and printing numbers, as well as a significantly
    faster generic hash routine.
    
    Additions:
    - add pl_test_pixfmt_caps to test AVPixelFormat<->GPU capabilities
    - add pl_vulkan_swapchain_params.disable_10bit_sdr to work around bugs
    - add pl_queue_estimate_fps/vps, pl_queue_num_frames and pl_queue_peek
    - add pl_tone_map_linear_light
    - add pl_gamut_map_softclip (equivalent to old pl_gamut_map_perceptual)
    - add pl_primaries_compatible and pl_primaries_clip
    - add pl_gamut_map_params.gamut_expansion
    - add helper macros to struct pl_color_adjustment and pl_icc_profile
    - add pl_filter_function.name and pl_filter_config.name/description
    - add pl_filter_config.radius/params/wparams/antiring
    - add pl_filter_config.allowed/recommended usage hints
    - add pl_filter_functions and pl_filter_configs
    - add pl_filter.radius_zero (size of main lobe)
    - add pl_filter_ewa_lanczossharp and pl_filter_ewa_lanczos4sharpest
    - add pl_hook_par.names and TYPE ENUM named parameters
    - add new options system in <libplacebo/options.h>
    - add pl_gamut_map_params.constants and pl_color_map_params.gamut_constants
    - add pl_tone_map_params.constants and pl_color_map_params.tone_constants
    - add pl_renderer_get_hdr_metadata
    - add new unified cache system in <libplacebo/cache.h>
    - add pl_gpu_set_cache
    - add pl_render_params.correct_subpixel_offsets
    - add pl_icc_update to update pl_icc_object more efficiently
    - add pl_frame.icc to eventually replace pl_frame.profile
    - add pl_frame_mix_nearest/current
    - add pl_frames_infer and pl_frames_infer_mix
    - add pl_shader_sample_hermite/gaussian
    - add pl_tex_transfer_params.no_import to bypass host pointer import
    - add new 'multigpu' demo to allow benchmarking GPU->GPU transfers,
      including roundtrips through a single GPU
    
    Changes:
    - pl_source_frame.pts and pl_queue_params.pts are now `double`
    - anti-ringing now works for polar (EWA) filters
    - pl_deband_default_params.threshold lowered to 2.0 (TODO)
    - pl_icc_params.size_r/g/b are now `int`
    - pl_filter_config and pl_filter_function have been substantially refactored
    - deprecate/remove pl_filter_function_preset and pl_filter_preset
    - pl_peak_detect_params.smoothing_period == 0 now disables smoothing
    - deprecate pl_color_map_params.tone_mapping_param and pl_tone_map_params.param
    - remove pl_peak_detect_params.minimum_peak
    - pl_tone_map_auto is now an alias for pl_tone_map_spline
    - change pl_peak_detect_params.scene_threshold_low/high and smoothing_period
      default values to make peak detection much more responsive
    - remove pl_filter_config.filter_scale (set filter blur instead)
    - default to pl_filter_ewa_lanczossharp in high quality preset
    - default to pl_filter_lanczos in default preset
    - default to pl_filter_hermite for downscaling
    - make pl_render_high_quality_params.frame_mixer consistent with default
    - require C++20 for building
    - remove pl_pass_params.cached_program (use pl_cache instead)
    - deprecate pl_dispatch_save/load (use pl_cache instead)
    - deprecate pl_renderer_save/load (use pl_cache instead)
    - depreciate pl_frame.profile in favor of pl_frame.icc
    - remove pl_render_params.icc_params and ignore_icc_profiles
    - remove the redundant pl_filter_function_{bcspline,catmull_rom,mitchell,
      robidoux,robidouxsharp,bicubic} family of cubic splines, and instead add
      a single tunable pl_filter_function_cubic to replace them
    - remove pl_{render,sample_filter}_params.{lut_entries,polar_cutoff}
    - pl_filter.radius now always holds the true radius (after blurring/cutoff)
    - slightly adjust pl_deband_default_params.threshold/grain
    - `plplay` now has a new, and much better, options parsing code
    - `pl_filter_nearest` can now only be used for upscaling
    - `pl_filter_box` is now a separate filter instead of an alias for
      `pl_filter_nearest`
    
    Fixes and performance enhancements:
    - shader stripping is now enabled by default
    - greatly improve performance of complex shader generation
    - fix some bugs related to pl_swapchain_colorspace_hint
    - fix meson picking wrong python version sometimes
    - fix contrast recovery sometimes producing illegal values
    - fix pl_filter_function_box radius to be more useful, and make
      pl_filter_nearest radius 0.5 instead
    - fix error using vulkan on system with broken synchronization2 layers
    - fix AV1 film grain for 4:4:4 files
    - fix build issues with UCRT on windows
    - fix allocation of large pages (e.g. very large images) on vulkan
    - fix runtime checks on windows 8+
    - fix CHROMA/ALPHA_SCALED hooks not working
    - fix pl_tex_transfer_params.buf_offset in texel fallback path
    - automatically split large texture transfers into slices
    - fix overly strict garbage collection on high FPS displays
    - fix crash on pl_queue_update with no frames
    - fix peak detection not working for files with buggy HDR10 metadata
    - fix peak detection not applying when HDR10+ metadata is present
    - fix peak detection luma coefficients
    - make peak detection ignore entirely black pixels (e.g. black bars)
    - fix calculation of filter blurs not correctly scaling the window
    - fix leaking vulkan headers path in pkg-config file
    - improve performance and correctness of numerical parsing/printing
    - fix textureLod error when using external or rectangle samplers
    - greatly improve performance of built-in hashing function
    - improve LUT generation performance by caching all shader LUTs
    - halve in-memory size of gamut mapping 3DLUTs
    - fix rendering of overlays when target has an ICC profile set
    - fix incorrect subpixel offset on multi-pass prescalers (e.g. NNEDI3)
    - fix pl_filter_function_hermite and pl_filter_hermite values
    - fix scaling of kaiser/quadratic/bicubic windows
    - improve performance of ortho scaling with all-positive filter kernels
    - improve performance and LUT accuracy when scaling with prematurely windowed
      (or heavily sharpened) filters
    - improve performance of gaussian and hermite scaling
    - improve accuracy of all scaler LUTs
    - frame mixers are now properly blurred when reducing FPS
    
  • v6.337.0-rc1
    v6.337.0-rc1
    
    This release focuses on several major "quality of life" improvements for
    downstream users. These include an all-new options system, a new unified cache
    layer, and a new filter configuration API, as well as improvements to tone and
    gamut mapping, scaling and HDR peak detection.
    
    The new options system greatly simplifies usage of the pl_render_params API,
    and allows saving/loading parameter presets at runtime, as well as exposing
    advanced options in a programmatic way.
    
    The new cache layer unifies the old dispatch/renderer/icc cache systems into a
    single file which can be more easily saved/loaded at runtime, and also includes
    support for internal size limits, book-keeping and garbage collection.
    
    The new filter API greatly simplifies the process of configuring custom filter
    kernels, and also augments each filter entry by extra metadata which can be
    used to make this API more understandable and simpler for end users. The
    default scalers have also been overhauled, and multiple scalers have been
    fixed, made faster, or otherwise improved.
    
    In addition to this, libplacebo now uses a custom GLSL preprocessor to
    significantly speed up the runtime generation of complex shaders, faster
    built-in functions for parsing and printing numbers, as well as a significantly
    faster generic hash routine.
    
    Additions:
    - add pl_test_pixfmt_caps to test AVPixelFormat<->GPU capabilities
    - add pl_vulkan_swapchain_params.disable_10bit_sdr to work around bugs
    - add pl_queue_estimate_fps/vps, pl_queue_num_frames and pl_queue_peek
    - add pl_tone_map_linear_light
    - add pl_gamut_map_softclip (equivalent to old pl_gamut_map_perceptual)
    - add pl_primaries_compatible and pl_primaries_clip
    - add pl_gamut_map_params.gamut_expansion
    - add helper macros to struct pl_color_adjustment and pl_icc_profile
    - add pl_filter_function.name and pl_filter_config.name/description
    - add pl_filter_config.radius/params/wparams/antiring
    - add pl_filter_config.allowed/recommended usage hints
    - add pl_filter_functions and pl_filter_configs
    - add pl_filter.radius_zero (size of main lobe)
    - add pl_filter_ewa_lanczossharp and pl_filter_ewa_lanczos4sharpest
    - add pl_hook_par.names and TYPE ENUM named parameters
    - add new options system in <libplacebo/options.h>
    - add pl_gamut_map_params.constants and pl_color_map_params.gamut_constants
    - add pl_tone_map_params.constants and pl_color_map_params.tone_constants
    - add pl_renderer_get_hdr_metadata
    - add new unified cache system in <libplacebo/cache.h>
    - add pl_gpu_set_cache
    - add pl_render_params.correct_subpixel_offsets
    - add pl_icc_update to update pl_icc_object more efficiently
    - add pl_frame.icc to eventually replace pl_frame.profile
    - add pl_frame_mix_nearest/current
    - add pl_frames_infer and pl_frames_infer_mix
    - add pl_shader_sample_hermite/gaussian
    - add pl_tex_transfer_params.no_import to bypass host pointer import
    
    Changes:
    - pl_source_frame.pts and pl_queue_params.pts are now `double`
    - anti-ringing now works for polar (EWA) filters
    - pl_deband_default_params.threshold lowered to 2.0 (TODO)
    - pl_icc_params.size_r/g/b are now `int`
    - pl_filter_config and pl_filter_function have been substantially refactored
    - deprecate/remove pl_filter_function_preset and pl_filter_preset
    - pl_peak_detect_params.smoothing_period == 0 now disables smoothing
    - deprecate pl_color_map_params.tone_mapping_param and pl_tone_map_params.param
    - remove pl_peak_detect_params.minimum_peak
    - pl_tone_map_auto is now an alias for pl_tone_map_spline
    - change pl_peak_detect_params.scene_threshold_low/high and smoothing_period
      default values to make peak detection much more responsive
    - remove pl_filter_config.filter_scale (set filter blur instead)
    - default to pl_filter_ewa_lanczossharp in high quality preset
    - default to pl_filter_lanczos in default preset
    - default to pl_filter_hermite for downscaling
    - make pl_render_high_quality_params.frame_mixer consistent with default
    - require C++20 for building
    - remove pl_pass_params.cached_program (use pl_cache instead)
    - deprecate pl_dispatch_save/load (use pl_cache instead)
    - deprecate pl_renderer_save/load (use pl_cache instead)
    - depreciate pl_frame.profile in favor of pl_frame.icc
    - remove pl_render_params.icc_params and ignore_icc_profiles
    - remove the redundant pl_filter_function_{bcspline,catmull_rom,mitchell,
      robidoux,robidouxsharp,bicubic} family of cubic splines, and instead add
      a single tunable pl_filter_function_cubic to replace them
    - remove pl_{render,sample_filter}_params.{lut_entries,polar_cutoff}
    - pl_filter.radius now always holds the true radius (after blurring/cutoff)
    - slightly adjust pl_deband_default_params.threshold/grain
    
    Fixes and performance enhancements:
    - shader stripping is now enabled by default
    - greatly improve performance of complex shader generation
    - fix some bugs related to pl_swapchain_colorspace_hint
    - fix meson picking wrong python version sometimes
    - fix contrast recovery sometimes producing illegal values
    - fix pl_filter_function_box radius to be more useful, and make
      pl_filter_nearest radius 0.5 instead
    - fix error using vulkan on system with broken synchronization2 layers
    - fix AV1 film grain for 4:4:4 files
    - fix build issues with UCRT on windows
    - fix allocation of large pages (e.g. very large images) on vulkan
    - fix runtime checks on windows 8+
    - fix CHROMA/ALPHA_SCALED hooks not working
    - fix pl_tex_transfer_params.buf_offset in texel fallback path
    - automatically split large texture transfers into slices
    - fix overly strict garbage collection on high FPS displays
    - fix crash on pl_queue_update with no frames
    - fix peak detection not working for files with buggy HDR10 metadata
    - fix peak detection not applying when HDR10+ metadata is present
    - fix peak detection luma coefficients
    - make peak detection ignore entirely black pixels (e.g. black bars)
    - fix calculation of filter blurs not correctly scaling the window
    - fix leaking vulkan headers path in pkg-config file
    - improve performance and correctness of numerical parsing/printing
    - fix textureLod error when using external or rectangle samplers
    - greatly improve performance of built-in hashing function
    - improve LUT generation performance by caching all shader LUTs
    - halve in-memory size of gamut mapping 3DLUTs
    - fix rendering of overlays when target has an ICC profile set
    - fix incorrect subpixel offset on multi-pass prescalers (e.g. NNEDI3)
    - fix pl_filter_function_hermite and pl_filter_hermite values
    - fix scaling of kaiser/quadratic/bicubic windows
    - improve performance of ortho scaling with all-positive filter kernels
    - improve performance and LUT accuracy when scaling with prematurely windowed
      (or heavily sharpened) filters
    - improve performance of gaussian and hermite scaling
    - improve accuracy of all scaler LUTs
    
  • v6.292.1
    v6.292.1
    
    This minor release includes several important bug fixes to downscaler
    kernels, a new and improved default perceptual gamut mapping mode, and
    an overhaul of the `plplay` demo program's core timing loop. It also
    drops the requirement for VK_KHR_synchronization2, which was
    unnecessarily and prohibitively strict in practice.
    
    Note that because this minor release does not change the public API,
    several new options related to the above changes are not yet exposed as
    part of this release.
    
    Fixes and other enhancements:
    - improve the quality of fallback tone-mapping (without state object)
    - implement fast path for saturation mapping
    - don't clip overlays during tone mapping / gamut conversion
    - enhance gamut 3DLUT visualization
    - fix aliasing when antiringing during downscaling
    - fix aliasing when downscaling with polar (EWA) filters
    - revert requirement for VK_KHR_synchronization2
    - fix possible queue underrun bug on very high fps sources
    - correctly support displays above 200 Hz
    - improve timing loop of plplay
    - add CPU metrics and frame statistics to plplay
    - fix build errors on 32-bit windows
    - correctly flush when submitting frame on opengl
    - fix bug when using contrast recovery with bilinear sampling
    - fix compilation warning on some platforms
    - properly handle interpolation on single frame files
    - fix memory leak of d3d11 helper buffer
    - fix vulkan debug_extra not being respected
    - remove unusable rxgxbxax10/12 formats
    - various fixes to the test framework
    - fix compute shaders being incorrectly enabled at too-low GLSL versions
    - fix capability masking when limiting max GLSL version
    - fix HLG source peak tuning logic when display luminance is known
    - fix unintended tone-mapping from SDR sources with embedded ICC
      profiles on unknown SDR displays
    - fix ICC profile luminance metadata being ignored on redraws when using
      pl_render_image_mix
    - improve quality of perceptual gamut mapper, and vastly decrease time
      to compute
    - increase default 3DLUT precision
    - fix numerical accuracy of pl_primaries_superset
    - disable gamut mapping if either colorspace does not describe a normal RGB
      colorspace (e.g. swapped channels from synthetic test ICC profiles)
    
  • v6.292.0
    v6.292.0
    
    This release focuses on a major overhaul of gamut mapping, including an
    all-new perceptual colorspace (IPTPQc4) and related set of 3DLUT
    generation primitives. The new default gamut mapping has been replaced
    by a perceptual soft-clip operation which attempts mapping primaries
    onto primaries while preserving a balance of both intensity and
    chromaticity. The old bespoke tone mapping modes have been replaced by a
    single colorimetric (IPTPQc4) tone mapping scheme. Lastly, a new HDR
    contrast recovery option helps preserve detail in very bright
    tone-mapped regions.
    
    In addition, this release focuses on major performance improvements to
    the shader generation system, considerably reducing CPU overhead in
    release builds.
    
    Finally, full support has been added for libavutil Vulkan hwcontexts,
    allowing libplacebo to work directly with Vulkan Video decoding without
    any memory copy overhead.
    
    Additions:
    - add `pl_shader_info`
    - add `pl_ipt_lms2rgb/rgb2lms and pl_ipt_lms2ipt/ipt2lms`
    - add <libplacebo/gamut_mapping.h>
    - add `pl_color_map_params.visualize_hue/theta` to visualize gamut 3DLUT
    - add `pl_vulkan_required_features`
    - add `pl_get_mapped_avframe` to retrieve AVFrame from mapped pl_frame
    - add `linear` frame mixer to pl_frame_mixers
    - add `pl_render_params.corner_rounding`
    - add `pl_matrix2x2_scale/invert` and `pl_transform2x2_scale/invert`
    - add `pl_shader_distort` and `pl_render_params.distort_params` to
      enable arbitrary affine distortions (e.g. arbitrary rotation, shear,
      flip/scale) as a final output post-processing step
    - add PL_HOOK_PRE_OUTPUT
    - add `pl_shader_color_map_ex` and `pl_color_map_args` as a more
      flexible API variant of `pl_shader_color_map`
    - add `pl_color_map_parms.contrast_recovery/smoothness` settings, plus
      `pl_color_map_args.feature_map` and `pl_shader_extract_features`
    - add `pl_transform2x2_bounds` to compute bounding box of transform
    - add `PL_COLOR_HDR_BLACK`, `PL_COLOR_SDR_CONTRAST` and
      `PL_COLOR_HLG_PEAK` to replace previously-hardcoded magic constants
    - add `pl_peak_detect_high_quality_params` and
      `pl_color_map_high_quality_params`
    
    Changes:
    - drop public APIs deprecated for libplacebo v4
    - require vulkan 1.3 headers at compile time
    - require vulkan 1.2 as a minimum runtime version
    - require a minimum version of GLSL 130 (GL/ES 3.0+)
    - require a mininum version of meson 0.63 to build
    - `pl_dispatch_info.shader` has been changed from `pl_shader_res` to
      `pl_shader_info`, which may require updating some code (the fields
      should be mostly backwards compatible)
    - complete refactor of `pl_color_map_params` gamut mapping settings
    - reduce default tone-mapping LUT size from 1024 to 256
    - deprecate `pl_vulkan.queues`
    - add `pl_vulkan_params.extra_queues` to enable more queue types
    - users are no longer required to use extension-specific vulkan feature
      structs, and may freely mix and match them with vulkan 1.x
      meta-structs - additionally, both types of structs are reported in
      `pl_vulkan.features`
    - `pl_vulkan_wrap_params.aspect` can now be left as 0 when not mapping
      individual planes of planar images
    - also enable subgroup clustered and quad operations in shaders
    - change type of `pl_vulkan.(un)lock_queue` to uint32_t, to match Vulkan
      API and libavutil vulkan hwcontext
    - enable peak detection (sans histogram) by default in
      `pl_render_default_params`
    
    Fixes and performance enhancements:
    - drop various backwards compatibility paths for GLSL 110
    - fix clipping artefacts when using textureless linear tone-mapping
    - fix source black point determination when using ICC profiles
    - vastly improve CPU overhead of shader (re-)generation on release
      builds, at the cost of less friendly variable names
    - significantly improve CPU overhead of pl_shader-related internal
      temporary allocations and various other related operations
    - fix HDR passthrough minimum luma value being ignored
    - minor fixes and performance improvements on internal allocator
    - fix various possible sources of minor memory leaks
    - various fixes and improvements to the meson build scripts
    - work-around nvidia-specific swapchain resizing bug, at the cost of
      performance when resizing the window
    - fix frame queue FPS estimation for non-monotonic PTS
    - fix negative inputs edge case in pl_hdr_rescale
    - clamp detected HDR peak to legal PQ range
    - avoid unnecessary tone-mapping LUT regeneration on static content
    - minor optimizations to the fast bicubic shader
    - minor theoretical overhead reduction by forcing LOD level
    - fix pl_map_avframe_ex data buffer handling
    - various improvements and bug fixes to the `plplay` demo program
    - correctly handle v4 perceptual ICC profiles
    - fix memory leak of vulkan queue locks
    - fix theoretical UB in vulkan memory barrier ordering semantics
    - relax unnecessarily strict / redundant host memory barriers
    - improve debug logging to understand where VRAM is being allocated
    - reduce fragmentation of large VRAM allocations (>= 64 MB)
    - fix edge case where DRM format modifier was incorrectly checked on
      export
    - correctly find vulkan SDK headers via VULKAN_SDK env var
    - correctly init d3d11 monitored fences
    - various fixes to d3d11 error reporting and logging
    - fix extension loading on pl_vulkan_import
    - various fixes to d3d11 register allocation
    - fix edge case when encountering incomplete interlaced streams
    - fix pl_queue_update with explicitly provided "extreme" vsync ratios
    - properly hold last interpolated frame for an extra 1/fps duration
    - fix off-by-one in interpolation EOF semantics
    - fix discontinuity in black point handling of st2094-40
    - fix possible double-acquire in pl_renderer frame acquisition logic, as
      well as a possible use-after-unacquire
    - correctly handle mistagged YCbCr AVFrames (e.g. tagged as RGB)
    - fix incorrect clamping in pl_render_image(..., NULL) path
    - fix crash when effectively rendering to blank/empty target crop
    - fix alpha blending output
    - significantly speed up mathematical opeations on mingw builds
    - fix ICC profile gamma estimation for very strange synthetic test
      profiles
    - fix excessive saturation when using black point compensation,
      inverse tone mapping, or tone mapping very bright videos
    - fix edge case where pl_frame_queue returned frames too early
    - various fixes to `pl_color_space_nominal_luma_ex`
    - fix issue when using peak detection on older GPUs
    - substantially improve performance of peak detection shader, especially
      when measuring a frame histogram
    - correctly hook PL_HOOK_SCALED even when using free/bilinear sampling
    - peak detection is now performed after downscaling, when viewing
      high-res HDR content on a low-res monitor/window
    - fix clipping of overlays on targets with HDR metadata
    
  • v6.292.0-rc3
    v6.292.0-rc3
    
    This release focuses on a major overhaul of gamut mapping, including an
    all-new perceptual colorspace (IPTPQc4) and related set of 3DLUT
    generation primitives. The new default gamut mapping has been replaced
    by a perceptual soft-clip operation which attempts mapping primaries
    onto primaries while preserving a balance of both intensity and
    chromaticity. The old bespoke tone mapping modes have been replaced by a
    single colorimetric (IPTPQc4) tone mapping scheme. Lastly, a new HDR
    contrast recovery option helps preserve detail in very bright
    tone-mapped regions.
    
    In addition, this release focuses on major performance improvements to
    the shader generation system, considerably reducing CPU overhead in
    release builds.
    
    Finally, full support has been added for libavutil Vulkan hwcontexts,
    allowing libplacebo to work directly with Vulkan Video decoding without
    any memory copy overhead.
    
    Additions:
    - add `pl_shader_info`
    - add `pl_ipt_lms2rgb/rgb2lms and pl_ipt_lms2ipt/ipt2lms`
    - add <libplacebo/gamut_mapping.h>
    - add `pl_color_map_params.visualize_hue/theta` to visualize gamut 3DLUT
    - add `pl_vulkan_required_features`
    - add `pl_get_mapped_avframe` to retrieve AVFrame from mapped pl_frame
    - add `linear` frame mixer to pl_frame_mixers
    - add `pl_render_params.corner_rounding`
    - add `pl_matrix2x2_scale/invert` and `pl_transform2x2_scale/invert`
    - add `pl_shader_distort` and `pl_render_params.distort_params` to
      enable arbitrary affine distortions (e.g. arbitrary rotation, shear,
      flip/scale) as a final output post-processing step
    - add PL_HOOK_PRE_OUTPUT
    - add `pl_shader_color_map_ex` and `pl_color_map_args` as a more
      flexible API variant of `pl_shader_color_map`
    - add `pl_color_map_parms.contrast_recovery/smoothness` settings, plus
      `pl_color_map_args.feature_map` and `pl_shader_extract_features`
    - add `pl_transform2x2_bounds` to compute bounding box of transform
    - add `PL_COLOR_HDR_BLACK`, `PL_COLOR_SDR_CONTRAST` and
      `PL_COLOR_HLG_PEAK` to replace previously-hardcoded magic constants
    - add `pl_peak_detect_high_quality_params` and
      `pl_color_map_high_quality_params`
    
    Changes:
    - drop public APIs deprecated for libplacebo v4
    - require vulkan 1.3 headers at compile time
    - require vulkan 1.2 as a minimum runtime version
    - require a minimum version of GLSL 130 (GL/ES 3.0+)
    - require a mininum version of meson 0.63 to build
    - `pl_dispatch_info.shader` has been changed from `pl_shader_res` to
      `pl_shader_info`, which may require updating some code (the fields
      should be mostly backwards compatible)
    - complete refactor of `pl_color_map_params` gamut mapping settings
    - reduce default tone-mapping LUT size from 1024 to 256
    - deprecate `pl_vulkan.queues`
    - add `pl_vulkan_params.extra_queues` to enable more queue types
    - users are no longer required to use extension-specific vulkan feature
      structs, and may freely mix and match them with vulkan 1.x
      meta-structs - additionally, both types of structs are reported in
      `pl_vulkan.features`
    - `pl_vulkan_wrap_params.aspect` can now be left as 0 when not mapping
      individual planes of planar images
    - also enable subgroup clustered and quad operations in shaders
    - change type of `pl_vulkan.(un)lock_queue` to uint32_t, to match Vulkan
      API and libavutil vulkan hwcontext
    - enable peak detection (sans histogram) by default in
      `pl_render_default_params`
    
    Fixes and performance enhancements:
    - drop various backwards compatibility paths for GLSL 110
    - fix clipping artefacts when using textureless linear tone-mapping
    - fix source black point determination when using ICC profiles
    - vastly improve CPU overhead of shader (re-)generation on release
      builds, at the cost of less friendly variable names
    - significantly improve CPU overhead of pl_shader-related internal
      temporary allocations and various other related operations
    - fix HDR passthrough minimum luma value being ignored
    - minor fixes and performance improvements on internal allocator
    - fix various possible sources of minor memory leaks
    - various fixes and improvements to the meson build scripts
    - work-around nvidia-specific swapchain resizing bug, at the cost of
      performance when resizing the window
    - fix frame queue FPS estimation for non-monotonic PTS
    - fix negative inputs edge case in pl_hdr_rescale
    - clamp detected HDR peak to legal PQ range
    - avoid unnecessary tone-mapping LUT regeneration on static content
    - minor optimizations to the fast bicubic shader
    - minor theoretical overhead reduction by forcing LOD level
    - fix pl_map_avframe_ex data buffer handling
    - various improvements and bug fixes to the `plplay` demo program
    - correctly handle v4 perceptual ICC profiles
    - fix memory leak of vulkan queue locks
    - fix theoretical UB in vulkan memory barrier ordering semantics
    - relax unnecessarily strict / redundant host memory barriers
    - improve debug logging to understand where VRAM is being allocated
    - reduce fragmentation of large VRAM allocations (>= 64 MB)
    - fix edge case where DRM format modifier was incorrectly checked on
      export
    - correctly find vulkan SDK headers via VULKAN_SDK env var
    - correctly init d3d11 monitored fences
    - various fixes to d3d11 error reporting and logging
    - fix extension loading on pl_vulkan_import
    - various fixes to d3d11 register allocation
    - fix edge case when encountering incomplete interlaced streams
    - fix pl_queue_update with explicitly provided "extreme" vsync ratios
    - properly hold last interpolated frame for an extra 1/fps duration
    - fix off-by-one in interpolation EOF semantics
    - fix discontinuity in black point handling of st2094-40
    - fix possible double-acquire in pl_renderer frame acquisition logic, as
      well as a possible use-after-unacquire
    - correctly handle mistagged YCbCr AVFrames (e.g. tagged as RGB)
    - fix incorrect clamping in pl_render_image(..., NULL) path
    - fix crash when effectively rendering to blank/empty target crop
    - fix alpha blending output
    - significantly speed up mathematical opeations on mingw builds
    - fix ICC profile gamma estimation for very strange synthetic test
      profiles
    - fix excessive saturation when using black point compensation,
      inverse tone mapping, or tone mapping very bright videos
    - fix edge case where pl_frame_queue returned frames too early
    - various fixes to `pl_color_space_nominal_luma_ex`
    - fix issue when using peak detection on older GPUs
    - substantially improve performance of peak detection shader, especially
      when measuring a frame histogram
    - correctly hook PL_HOOK_SCALED even when using free/bilinear sampling
    - peak detection is now performed after downscaling, when viewing
      high-res HDR content on a low-res monitor/window
    
  • v6.291.0-rc2
    v6.291.0-rc2
    
    This release focuses on a major overhaul of gamut mapping, including an
    all-new perceptual colorspace (IPTPQc4) and related set of 3DLUT
    generation primitives. The new default gamut mapping has been replaced
    by a perceptual soft-clip operation which attempts mapping primaries
    onto primaries while preserving a balance of both intensity and
    chromaticity. The old bespoke tone mapping modes have been replaced by a
    single colorimetric (IPTPQc4) tone mapping scheme. Lastly, a new HDR
    contrast recovery option helps preserve detail in very bright
    tone-mapped regions.
    
    In addition, this release focuses on major performance improvements to
    the shader generation system, considerably reducing CPU overhead in
    release builds.
    
    Finally, full support has been added for libavutil Vulkan hwcontexts,
    allowing libplacebo to work directly with Vulkan Video decoding without
    any memory copy overhead.
    
    Additions:
    - add `pl_shader_info`
    - add `pl_ipt_lms2rgb/rgb2lms and pl_ipt_lms2ipt/ipt2lms`
    - add <libplacebo/gamut_mapping.h>
    - add `pl_color_map_params.visualize_hue/theta` to visualize gamut 3DLUT
    - add `pl_vulkan_required_features`
    - add `pl_get_mapped_avframe` to retrieve AVFrame from mapped pl_frame
    - add `linear` frame mixer to pl_frame_mixers
    - add `pl_render_params.corner_rounding`
    - add `pl_matrix2x2_scale/invert` and `pl_transform2x2_scale/invert`
    - add `pl_shader_distort` and `pl_render_params.distort_params` to
      enable arbitrary affine distortions (e.g. arbitrary rotation, shear,
      flip/scale) as a final output post-processing step
    - add PL_HOOK_PRE_OUTPUT
    - add `pl_shader_color_map_ex` and `pl_color_map_args` as a more
      flexible API variant of `pl_shader_color_map`
    - add `pl_color_map_parms.contrast_recovery/smoothness` settings, plus
      `pl_color_map_args.feature_map` and `pl_shader_extract_features`
    - add `pl_transform2x2_bounds` to compute bounding box of transform
    - add `PL_COLOR_HDR_BLACK`, `PL_COLOR_SDR_CONTRAST` and
      `PL_COLOR_HLG_PEAK` to replace previously-hardcoded magic constants
    
    Changes:
    - drop public APIs deprecated for libplacebo v4
    - require vulkan 1.3 headers at compile time
    - require vulkan 1.2 as a minimum runtime version
    - require a minimum version of GLSL 130 (GL/ES 3.0+)
    - require a mininum version of meson 0.63 to build
    - `pl_dispatch_info.shader` has been changed from `pl_shader_res` to
      `pl_shader_info`, which may require updating some code (the fields
      should be mostly backwards compatible)
    - complete refactor of `pl_color_map_params` gamut mapping settings
    - reduce default tone-mapping LUT size from 1024 to 256
    - deprecate `pl_vulkan.queues`
    - add `pl_vulkan_params.extra_queues` to enable more queue types
    - users are no longer required to use extension-specific vulkan feature
      structs, and may freely mix and match them with vulkan 1.x
      meta-structs - additionally, both types of structs are reported in
      `pl_vulkan.features`
    - `pl_vulkan_wrap_params.aspect` can now be left as 0 when not mapping
      individual planes of planar images
    - also enable subgroup clustered and quad operations in shaders
    - change type of `pl_vulkan.(un)lock_queue` to uint32_t, to match Vulkan
      API and libavutil vulkan hwcontext
    
    Fixes and performance enhancements:
    - drop various backwards compatibility paths for GLSL 110
    - fix clipping artefacts when using textureless linear tone-mapping
    - fix source black point determination when using ICC profiles
    - vastly improve CPU overhead of shader (re-)generation on release
      builds, at the cost of less friendly variable names
    - significantly improve CPU overhead of pl_shader-related internal
      temporary allocations and various other related operations
    - fix HDR passthrough minimum luma value being ignored
    - minor fixes and performance improvements on internal allocator
    - fix various possible sources of minor memory leaks
    - various fixes and improvements to the meson build scripts
    - work-around nvidia-specific swapchain resizing bug, at the cost of
      performance when resizing the window
    - fix frame queue FPS estimation for non-monotonic PTS
    - fix negative inputs edge case in pl_hdr_rescale
    - clamp detected HDR peak to legal PQ range
    - avoid unnecessary tone-mapping LUT regeneration on static content
    - minor optimizations to the fast bicubic shader
    - minor theoretical overhead reduction by forcing LOD level
    - fix pl_map_avframe_ex data buffer handling
    - various improvements and bug fixes to the `plplay` demo program
    - correctly handle v4 perceptual ICC profiles
    - fix memory leak of vulkan queue locks
    - fix theoretical UB in vulkan memory barrier ordering semantics
    - relax unnecessarily strict / redundant host memory barriers
    - improve debug logging to understand where VRAM is being allocated
    - reduce fragmentation of large VRAM allocations (>= 64 MB)
    - fix edge case where DRM format modifier was incorrectly checked on
      export
    - correctly find vulkan SDK headers via VULKAN_SDK env var
    - correctly init d3d11 monitored fences
    - various fixes to d3d11 error reporting and logging
    - fix extension loading on pl_vulkan_import
    - various fixes to d3d11 register allocation
    - fix edge case when encountering incomplete interlaced streams
    - fix pl_queue_update with explicitly provided "extreme" vsync ratios
    - properly hold last interpolated frame for an extra 1/fps duration
    - fix off-by-one in interpolation EOF semantics
    - fix discontinuity in black point handling of st2094-40
    - fix possible double-acquire in pl_renderer frame acquisition logic, as
      well as a possible use-after-unacquire
    - correctly handle mistagged YCbCr AVFrames (e.g. tagged as RGB)
    - fix incorrect clamping in pl_render_image(..., NULL) path
    - fix crash when effectively rendering to blank/empty target crop
    - fix alpha blending output
    - significantly speed up mathematical opeations on mingw builds
    - fix ICC profile gamma estimation for very strange synthetic test
      profiles
    - fix excessive saturation when using black point compensation,
      inverse tone mapping, or tone mapping very bright videos
    - fix edge case where pl_frame_queue returned frames too early
    - various fixes to `pl_color_space_nominal_luma_ex`
    - fix issue when using peak detection on older GPUs
    
  • v6.287.0-rc1
    v6.287.0-rc1
    
    This release focuses on a major overhaul of gamut mapping, including an
    all-new perceptual colorspace (IPTPQc4) and related set of 3DLUT
    generation primitives. The new default gamut mapping has been replaced
    by a perceptual soft-knee operation which attempts mapping primaries
    onto primaries while preserving a balance of both intensity and
    chromaticity. The old bespoke tone mapping modes have been replaced by a
    single tunable LMS/IPTPQc4 hybrid tone mapping scheme. Lastly, a
    new HDR contrast recovery option helps preserve detail in very bright
    tone-mapped regions.
    
    In addition, this release focuses on major performance improvements to
    the shader generation system, considerably reducing CPU overhead in
    release builds.
    
    Finally, full support has been added for libavutil Vulkan hwcontexts,
    allowing libplacebo to work directly with Vulkan Video decoding without
    any memory copy overhead.
    
    Additions:
    - add `pl_shader_info`
    - add `pl_ipt_lms2rgb/rgb2lms and pl_ipt_lms2ipt/ipt2lms`
    - add <libplacebo/gamut_mapping.h>
    - add `pl_color_map_params.visualize_hue/theta` to visualize gamut 3DLUT
    - add `pl_vulkan_required_features`
    - add `pl_get_mapped_avframe` to retrieve AVFrame from mapped pl_frame
    - add `linear` frame mixer to pl_frame_mixers
    - add `pl_render_params.corner_rounding`
    - add `pl_matrix2x2_scale/invert` and `pl_transform2x2_scale/invert`
    - add `pl_shader_distort` and `pl_render_params.distort_params` to
      enable arbitrary affine distortions (e.g. arbitrary rotation, shear,
      flip/scale) as a final output post-processing step
    - add PL_HOOK_PRE_OUTPUT
    - add `pl_shader_color_map_ex` and `pl_color_map_args` as a more
      flexible API variant of `pl_shader_color_map`
    - add `pl_color_map_parms.contrast_recovery/smoothness` settings, plus
      `pl_color_map_args.feature_map` and `pl_shader_extract_features`
    - add `pl_transform2x2_bounds` to compute bounding box of transform
    
    Changes:
    - drop public APIs deprecated for libplacebo v4
    - require vulkan 1.3 headers at compile time
    - require vulkan 1.2 as a minimum runtime version
    - require a minimum version of GLSL 130 (GL/ES 3.0+)
    - require a mininum version of meson 0.63 to build
    - `pl_dispatch_info.shader` has been changed from `pl_shader_res` to
      `pl_shader_info`, which may require updating some code (the fields
      should be mostly backwards compatible)
    - complete refactor of `pl_color_map_params` gamut mapping settings
    - reduce default tone-mapping LUT size from 1024 to 256
    - deprecate `pl_vulkan.queues`
    - add `pl_vulkan_params.extra_queues` to enable more queue types
    - users are no longer required to use extension-specific vulkan feature
      structs, and may freely mix and match them with vulkan 1.x
      meta-structs - additionally, both types of structs are reported in
      `pl_vulkan.features`
    - `pl_vulkan_wrap_params.aspect` can now be left as 0 when not mapping
      individual planes of planar images
    - also enable subgroup clustered and quad operations in shaders
    - change type of `pl_vulkan.(un)lock_queue` to uint32_t, to match Vulkan
      API and libavutil vulkan hwcontext
    
    Fixes and performance enhancements:
    - drop various backwards compatibility paths for GLSL 110
    - fix clipping artefacts when using textureless linear tone-mapping
    - fix source black point determination when using ICC profiles
    - vastly improve CPU overhead of shader (re-)generation on release
      builds, at the cost of less friendly variable names
    - significantly improve CPU overhead of pl_shader-related internal
      temporary allocations and various other related operations
    - fix HDR passthrough minimum luma value being ignored
    - minor fixes and performance improvements on internal allocator
    - fix various possible sources of minor memory leaks
    - various fixes and improvements to the meson build scripts
    - work-around nvidia-specific swapchain resizing bug, at the cost of
      performance when resizing the window
    - fix frame queue FPS estimation for non-monotonic PTS
    - fix negative inputs edge case in pl_hdr_rescale
    - clamp detected HDR peak to legal PQ range
    - avoid unnecessary tone-mapping LUT regeneration on static content
    - minor optimizations to the fast bicubic shader
    - minor theoretical overhead reduction by forcing LOD level
    - fix pl_map_avframe_ex data buffer handling
    - various improvements to the `plplay` demo program
    - correctly handle v4 perceptual ICC profiles
    - fix memory leak of vulkan queue locks
    - fix theoretical UB in vulkan memory barrier ordering semantics
    - relax unnecessarily strict / redundant host memory barriers
    - improve debug logging to understand where VRAM is being allocated
    - reduce fragmentation of large VRAM allocations (>= 64 MB)
    - fix edge case where DRM format modifier was incorrectly checked on
      export
    - correctly find vulkan SDK headers via VULKAN_SDK env var
    - correctly init d3d11 monitored fences
    - various fixes to d3d11 error reporting and logging
    - fix extension loading on pl_vulkan_import
    - various fixes to d3d11 register allocation
    - fix edge case when encountering incomplete interlaced streams
    - fix pl_queue_update with explicitly provided "extreme" vsync ratios
    - properly hold last interpolated frame for an extra 1/fps duration
    - fix off-by-one in interpolation EOF semantics
    - fix discontinuity in black point handling of st2094-40
    - fix possible double-acquire in pl_renderer frame acquisition logic, as
      well as a possible use-after-unacquire
    - correctly handle mistagged YCbCr AVFrames (e.g. tagged as RGB)
    - fix incorrect clamping in pl_render_image(..., NULL) path
    - fix crash when effectively rendering to blank/empty target crop
    - fix alpha blending output
    - significantly speed up mathematical opeations on mingw builds
    - fix ICC profile gamma estimation for very strange synthetic test
      profiles
    - fix excessive saturation when using black point compensation or
      inverse tone mapping
    
  • v5.264.1
    ed29e541 · meson: v5.264.1 ·
    v5.264.1
    
    This bugfix release fixes a major regression in the v5.264.0
    tone-mapping redesign which resulted in garbage pixels (and unnecessary
    tone-mapping) when using an ICC output profile, as well as other minor
    miscellaneous fixes.
    
    Fixes:
    - fix linear tone mapping resulting in garbage pixels appearing in and
      around black and near-black regions
    - fix ICC profiles incorrectly resulting in tone-mapping being enabled
    - fix minimum meson version being incorrectly set
    - fix HDR10 static metadata minimum brightness not being sent when using
      HDR passthrough
    - fix left-over debug junk that could possibly cause a shader
      miscompilation on older GLSL
    - fix a possible memleak in pl_renderer
    - fix several hypothetical sources of UB inside internal code
    - various minor fixes to misleading or missing log messages
    
  • v5.264.0
    v5.264.0
    
    This release focuses on a major overhaul of HDR tone-mapping, including
    support for HDR10+ and PQ CIE Y dynamic metadata (including ST2094-40
    OOTF), an entirely rewritten peak detection shader (using a frame
    histogram), a reimagined new default 'spline' tone-mapping function, and
    two new debug overlays to visualize the tone-mapping LUT and clipped
    pixels.
    
    In addition, this release offers proper native support for DCI Digital
    Cinema Distribution Master (XYZ) decoding, integration with libdovi for
    Dolby Vision RPU parsing, native support for planar (YCbCr) vulkan
    texture formats, and a major overhaul of the vulkan command scheduling
    and synchronization code.
    
    Additions:
    - add PL_COLOR_PRIM_ACES_AP0 and PL_COLOR_PRIM_ACES_AP1
    - add pl_tone_map_params_infer
    - add pl_plane_data_from_comps (not restricted to 64-bit formats)
    - add pl_hook.parameters and the ability to use //!PARAM directives
      inside mpv-style shaders
    - add pl_gpu_limits.host_cached to test for host-cached host-mapped
      buffer support
    - add pl_vukan.get_proc_addr
    - add pl_vulkan_sem_create/destroy, to create (exportable) vulkan
      semaphores for use with the vulkan image interop API
    - add pl_vulkan_hold_ex and pl_vulkan_release_ex
    - add pl_vulkan_wrap_params.aspect to wrap individual planes of planar
      images
    - add support for packed 16-bit formats (rx10, rxgx10 etc.)
    - add support for planar textures (pl_fmt.planes and pl_tex.planes), and
      introduce planar texture formats (g8_br8_420, gx10_bx10_rx10_444 etc)
    - add support for 3-component formats (rgb8, rgb16 etc) to d3d11
    - add PL_COLOR_TRC_ST428 (DCI digital cinema XYZ transfer function)
    - add pl_plane_data.swapped to support uploading non-native endian data
    - add pl_hdr_metadata.scene_max/avg and pl_hdr_metadata.ootf for HDR10+
      dynamic metadata
    - add pl_map_hdr_metadata and pl_frame_map_avdovi_metadata
    - add pl_tone_map_params.hdr
    - add pl_tone_map_st2094_10 and pl_tone_map_st2094_40
    - add pl_color_map_params.visualize_lut and visualize_rect
    - add pl_hook.signature to help identify hooks (for error tracking)
    - add pl_renderer_get_errors and pl_renderer_reset_errors to query the
      renderer for internal errors
    - add <libplacebo/utils/dolbyvision.h> for parsing DV RPUs (based on
      libdovi)
    - add a compile-time option to disable dolbyvision support
    - add support for sampling from integer textures on d3d11
    - add pl_color_space_nominal_peak_ex
    - add pl_get_detected_hdr_metadata
    - add pl_hdr_metadata.max_pq_y and avg_pq_y
    - add pl_tone_map_params.input_avg
    - add pl_hdr_metadata_type and pl_hdr_metadata_contains, as well as
      pl_color_map_params.metadata, to influence the choice of HDR metadata
    - add pl_peak_detect_params.percentile
    - add pl_color_map_params.show_clipping
    
    Changes:
    - deprecate pl_sync and pl_tex_export (in favor of pl_vulkan_sem_create
      and pl_vulkan_hold_ex)
    - deprecate pl_vulkan_hold, pl_vulkan_hold_raw and pl_vulkan_release (in
      favor of their _ex counterparts)
    - improve tone-mapping default function/mode heuristics
    - remove pl_swapchain.impl from public-facing struct
    - pl_tone_map_spline has been substantially rewritten and replaced by a
      similar but different algorithm, with a new tunable parameter
      (influencing the desired subjective contrast level)
    - pl_color_map_params.lut_size now only affects a 1D LUT, rather than a
      2D LUT, and the default has been increased from 256 to 1024
    - move pl_renderer_params.allow_delayed_peak_detect to
      pl_peak_detect_params.allow_delayed
    - deprecate pl_get_detected_peak, replaced by
      pl_get_detected_hdr_metadata
    - deprecate/remove pl_peak_detect_params.overshoot_margin
    - move pl_hdr_rescale from <libplacebo/tone_mapping.h> to
      <libplacebo/colorspace.h>
    
    Fixes and performance enhancements:
    - correctly accept even very wide ICC profiles
    - fix dynamic LUT generation suddenly switching between different tone
      mapping functions when using `pl_tone_map_auto`
    - correctly report buffer size limits in pl_vulkan.gpu->limits
    - fix an issue where zooming into a fullscreen image did not correctly
      invalidate the frame cache
    - fix building with recent versions of glslang
    - fix unintentional sub-pixel distortions when cropping
    - fix sampling from GL_OES_EGL_image_external targets on GL ES 3.x
    - fix UB when using VK_EXT_full_screen_exclusive
    - fix choice of default SDR curves when targetting PL_COLOR_TRC_UNKNOWN
    - infer correct color gamut / primaries when using PL_COLOR_SYSTEM_XYZ
    - fix corner case when combinig linear input with non-linear scaling
    - fix compute shader blit fallback rounding
    - optimize blitting from 1 pixel sources
    - fix UB when drawing from image formats where alpha was the first
      component
    - fix pl_vulkan_wrap incorrectly rejecting 1D/3D textures
    - fix pl_vulkan_wrap ignoring renderable/host_readable caps
    - fix GLSL codegen for non-float samplerBuffer
    - adjust precision of whitepoints to match common practice
    - fix d3d11 texel buffer initialization
    - fix frequent shader recompilation in pl_shader_dovi_reshape
    - correctly decode white point of DCI XYZ content
    - fix issue where OpenGL shaders with multiple buffer block bindings
      (UBOs/SSBOs) were not correctly initialized on older GLSL
    - various fixes and improvements to the vulkan memory selection logic
    - fix memory leak on d3d11
    - fix possible crash on older OpenGL drivers
    - fix texture blit fallback shader on older GLSL
    - avoid implementation-defined behavior when using SSBOs on older GLSL
    - fix memory leak when pl_mpv_user_shader_parse fails
    - fix memory leak when using deinterlaced frames in pl_queue
    - fix thread-unsafe array usage in pl_pass_create on vulkan
    - fix issue where BT.2446 was unintentionally picked for HDR->HDR
      inverse tone mapping
    - fix double mutex unlock in vulkan memory allocator
    - fix <libplacebo/shaders/deinterlacing.h> and <libplacebo/d3d11.h> headers
    - fix missing host read/write dependencies vulkan buffers
    - fix build on newer vulkan headers
    - fix various build issues on 32-bit platforms
    - fix issue when shader LUTs fail being created
    - fix possible UB in AV1 film grain shader
    - substantially rewrite vulkan command/object synchronization to take
      full advantage of timeline semaphores, drastically reducing the number
      of semaphores and synchronization primitives that were emitted
    - properly clean up after old/unused shader cache entries
    - fix timing of vulkan uninit debug messages
    - correctly prefer mingw vulkan headers over system-wide vulkan headers
      when building inside mingw
    - improve performance of string concatenation operations when
      constructing shaders
    - fix vulkan swapchain recreation when swapchain size is unchanged
    - fix unnecessary/redundant tone-mapping when drawing overlays
    - fix discontinuity when using PL_TONE_MAP_AUTO and the source peak
      falls below the target peak
    - fix overly aggressive saturation when using PL_TONE_MAP_LUMA for small
      range conversions
    - various fixes for using libplacebo from C++
    - always go through full tone-mapping LUT even when performing only
      black-point-compensation
    - performance improvement (LUT bypass) for pl_tone_map_linear
    - improve debugging of vulkan leak detection and out-of-memory errors
    - fix possible segfault when vulkan/d3d11 context creation fails
    - avoid deprecated features when compiling SPIR-V for newer vulkan
    - fix various issues caused by a poor choice of color mixing space when
      using pl_render_image_mix and HDR sources/displays
    - correctly invalidate frame cache when rendering single frames with
      updated parameters/dimensions
    - correctly reset peak detection state when params change
    - fix unintentional RGB hard-clip before luma-based tone-mapping
    - correctly enable vulkan validation features extension when using
      pl_vk_inst_params.debug_extra
    - emit correct texture barrier when pl_pass_params.load_target is true
    - various fixes and improvements to the test framework
    - various fixes and improvements to demos/plplay
    
  • v5.264.0-rc1
    v5.264.0-rc1
    
    This release focuses on a major overhaul of HDR tone-mapping, including
    support for HDR10+ and PQ CIE Y dynamic metadata (including ST2094-40
    OOTF), an entirely rewritten peak detection shader (using a frame
    histogram), a reimagined new default 'spline' tone-mapping function, and
    two new debug overlays to visualize the tone-mapping LUT and clipped
    pixels.
    
    In addition, this release offers proper native support for DCI Digital
    Cinema Distribution Master (XYZ) decoding, integration with libdovi for
    Dolby Vision RPU parsing, native support for planar (YCbCr) vulkan
    texture formats, and a major overhaul of the vulkan command scheduling
    and synchronization code.
    
    Additions:
    - add PL_COLOR_PRIM_ACES_AP0 and PL_COLOR_PRIM_ACES_AP1
    - add pl_tone_map_params_infer
    - add pl_plane_data_from_comps (not restricted to 64-bit formats)
    - add pl_hook.parameters and the ability to use //!PARAM directives
      inside mpv-style shaders
    - add pl_gpu_limits.host_cached to test for host-cached host-mapped
      buffer support
    - add pl_vukan.get_proc_addr
    - add pl_vulkan_sem_create/destroy, to create (exportable) vulkan
      semaphores for use with the vulkan image interop API
    - add pl_vulkan_hold_ex and pl_vulkan_release_ex
    - add pl_vulkan_wrap_params.aspect to wrap individual planes of planar
      images
    - add support for packed 16-bit formats (rx10, rxgx10 etc.)
    - add support for planar textures (pl_fmt.planes and pl_tex.planes), and
      introduce planar texture formats (g8_br8_420, gx10_bx10_rx10_444 etc)
    - add support for 3-component formats (rgb8, rgb16 etc) to d3d11
    - add PL_COLOR_TRC_ST428 (DCI digital cinema XYZ transfer function)
    - add pl_plane_data.swapped to support uploading non-native endian data
    - add pl_hdr_metadata.scene_max/avg and pl_hdr_metadata.ootf for HDR10+
      dynamic metadata
    - add pl_map_hdr_metadata and pl_frame_map_avdovi_metadata
    - add pl_tone_map_params.hdr
    - add pl_tone_map_st2094_10 and pl_tone_map_st2094_40
    - add pl_color_map_params.visualize_lut and visualize_rect
    - add pl_hook.signature to help identify hooks (for error tracking)
    - add pl_renderer_get_errors and pl_renderer_reset_errors to query the
      renderer for internal errors
    - add <libplacebo/utils/dolbyvision.h> for parsing DV RPUs (based on
      libdovi)
    - add support for sampling from integer textures on d3d11
    - add pl_color_space_nominal_peak_ex
    - add pl_get_detected_hdr_metadata
    - add pl_hdr_metadata.max_pq_y and avg_pq_y
    - add pl_tone_map_params.input_avg
    - add pl_hdr_metadata_type and pl_hdr_metadata_contains, as well as
      pl_color_map_params.metadata, to influence the choice of HDR metadata
    - add pl_peak_detect_params.percentile
    - add pl_color_map_params.show_clipping
    
    Changes:
    - deprecate pl_sync and pl_tex_export (in favor of pl_vulkan_sem_create
      and pl_vulkan_hold_ex)
    - deprecate pl_vulkan_hold, pl_vulkan_hold_raw and pl_vulkan_release (in
      favor of their _ex counterparts)
    - improve tone-mapping default function/mode heuristics
    - remove pl_swapchain.impl from public-facing struct
    - pl_tone_map_spline has been substantially rewritten and replaced by a
      similar but different algorithm, with a new tunable parameter
      (influencing the desired subjective contrast level)
    - pl_color_map_params.lut_size now only affects a 1D LUT, rather than a
      2D LUT, and the default has been increased from 256 to 1024
    - move pl_renderer_params.allow_delayed_peak_detect to
      pl_peak_detect_params.allow_delayed
    - deprecate pl_get_detected_peak, replaced by
      pl_get_detected_hdr_metadata
    - deprecate/remove pl_peak_detect_params.overshoot_margin
    - move pl_hdr_rescale from <libplacebo/tone_mapping.h> to
      <libplacebo/colorspace.h>
    
    Fixes and performance enhancements:
    - correctly accept even very wide ICC profiles
    - fix dynamic LUT generation suddenly switching between different tone
      mapping functions when using `pl_tone_map_auto`
    - correctly report buffer size limits in pl_vulkan.gpu->limits
    - fix an issue where zooming into a fullscreen image did not correctly
      invalidate the frame cache
    - fix building with recent versions of glslang
    - fix unintentional sub-pixel distortions when cropping
    - fix sampling from GL_OES_EGL_image_external targets on GL ES 3.x
    - fix UB when using VK_EXT_full_screen_exclusive
    - fix choice of default SDR curves when targetting PL_COLOR_TRC_UNKNOWN
    - infer correct color gamut / primaries when using PL_COLOR_SYSTEM_XYZ
    - fix corner case when combinig linear input with non-linear scaling
    - fix compute shader blit fallback rounding
    - optimize blitting from 1 pixel sources
    - fix UB when drawing from image formats where alpha was the first
      component
    - fix pl_vulkan_wrap incorrectly rejecting 1D/3D textures
    - fix pl_vulkan_wrap ignoring renderable/host_readable caps
    - fix GLSL codegen for non-float samplerBuffer
    - adjust precision of whitepoints to match common practice
    - fix d3d11 texel buffer initialization
    - fix frequent shader recompilation in pl_shader_dovi_reshape
    - correctly decode white point of DCI XYZ content
    - fix issue where OpenGL shaders with multiple buffer block bindings
      (UBOs/SSBOs) were not correctly initialized on older GLSL
    - various fixes and improvements to the vulkan memory selection logic
    - fix memory leak on d3d11
    - fix possible crash on older OpenGL drivers
    - fix texture blit fallback shader on older GLSL
    - avoid implementation-defined behavior when using SSBOs on older GLSL
    - fix memory leak when pl_mpv_user_shader_parse fails
    - fix memory leak when using deinterlaced frames in pl_queue
    - fix thread-unsafe array usage in pl_pass_create on vulkan
    - fix issue where BT.2446 was unintentionally picked for HDR->HDR
      inverse tone mapping
    - fix double mutex unlock in vulkan memory allocator
    - fix <libplacebo/shaders/deinterlacing.h> and <libplacebo/d3d11.h> headers
    - fix missing host read/write dependencies vulkan buffers
    - fix build on newer vulkan headers
    - fix various build issues on 32-bit platforms
    - fix issue when shader LUTs fail being created
    - fix possible UB in AV1 film grain shader
    - substantially rewrite vulkan command/object synchronization to take
      full advantage of timeline semaphores, drastically reducing the number
      of semaphores and synchronization primitives that were emitted
    - properly clean up after old/unused shader cache entries
    - fix timing of vulkan uninit debug messages
    - correctly prefer mingw vulkan headers over system-wide vulkan headers
      when building inside mingw
    - improve performance of string concatenation operations when
      constructing shaders
    - fix vulkan swapchain recreation when swapchain size is unchanged
    - fix unnecessary/redundant tone-mapping when drawing overlays
    - fix discontinuity when using PL_TONE_MAP_AUTO and the source peak
      falls below the target peak
    - fix overly aggressive saturation when using PL_TONE_MAP_LUMA for small
      range conversions
    - various fixes for using libplacebo from C++
    - always go through full tone-mapping LUT even when performing only
      black-point-compensation
    - performance improvement (LUT bypass) for pl_tone_map_linear
    - improve debugging of vulkan leak detection and out-of-memory errors
    - fix possible segfault when vulkan/d3d11 context creation fails
    - avoid deprecated features when compiling SPIR-V for newer vulkan
    - fix various issues caused by a poor choice of color mixing space when
      using pl_render_image_mix and HDR sources/displays
    - correctly invalidate frame cache when rendering single frames with
      updated parameters/dimensions
    - correctly reset peak detection state when params change
    - fix unintentional RGB hard-clip before luma-based tone-mapping
    - correctly enable vulkan validation features extension when using
      pl_vk_inst_params.debug_extra
    - emit correct texture barrier when pl_pass_params.load_target is true
    - various fixes and improvements to the test framework
    - various fixes and improvements to demos/plplay
    
  • v5.229.2
    2394aea1 · meson: update fix version ·
    v5.229.2
    
    This bugfix release fixes a number of minor issues that have come up
    since v5.229.1:
    
    Fixes and performance enhancements:
    - allow `plplay` to support hardware decoding with EGL
    - fix an issue where custom shaders with `//!SAVE MAIN` did not save
      textures
    - fix a number of minor memory leaks
    - fix an issue where custom shaders that tried binding conditionally
      excluded textures generated superfluous errors
    - fix an issue where the libav helpers ran into undefined behavior when
      operating on the 128-bit image formats in recent versions of ffmpeg
    - fix a build issue on BSD platforms without libdl
    - fix an issue where freeing `pl_shader_obj` too early could lead to
      use-after-free errors if shaders still referenced these objects
    - fix an issue where applying film grain after debanding could trigger
      an assertion due to a change in bit depth
    - fix an issue where film grain generation was unnecessarily verbose due
      to LUT updates
    - fix an issue where tone mapping desaturation was not working as
      intended, resulting in strongly oversaturated colors
    - fix an issue where the red channel sometimes got unintentionally
      deleted from RGB input images
    - fix an issue where AV1 film grain synthesis did not work on pictures
      above 12 bit depth, such as could be the output of a previous filter
    - remove an unnecessary assertion that caused build issues on some
      versions of clang
    - fix an issue where we unintentionally used linear downscaling on HDR
      sources
    - fix an issue with false negatives in the PL_GAMUT_WARN algorithm, and
      also change the algorithm to make it more visually obvious
    - fix an issue where OpenGL on WSL2 was unintentionally rejected as a
      software rasterizer
    
  • v5.229.1
    v5.229.1
    
    This minor release fixes a crucial bug in v5.229.0, which caused a
    regression when using orthogonal scaler kernels on anything but simple
    scaling ratios, as well as other minor fixes.
    
    Fixes and performance enhancements:
    - fix an issue where the pl_shader_sample_ortho refactor broke
      orthogonal scalers inside pl_renderer, for anything but very simply
      scaling ratios
    - fix an issue where pl_shader_sample_ortho2 rejected some scaling
      ratios due to floating point inaccuracy
    - fix an issue where some extreme 'test' ICC profiles were unfairly
      rejected by the gamma detection code
    - fix an issue where some oddly-crafted ICC profiles could result in
      NaNs propagating into the shader math
    
  • v5.229.0
    v5.229.0
    
    This is a major release, bumping up the major version to v5 and dropping
    all APIs deprecated in v3.x. The other major breaking change of this
    release is a switch away from the external `libepoxy` and `mako`
    dependencies in favor of the (optionally bundled) `glad2` and `jinja2`.
    These are now included, along with various other build-time dependencies,
    as git submodules. Users are advised to clone with `git clone
    --recursive` in order to satisfy these dependencies automatically, while
    distros maintainers are nonetheless encouraged to continue packaging
    them.
    
    In addition, this release brings with it a number of new features and
    changes - including support for fully automatic GPU deinterlacing, error
    diffusion dithering, gamma-aware dithering, and a number of improvements
    to the handling of HDR sources and output displays, as well as several
    notable bug fixes and performance enhancements.
    
    Additions:
    - add `pl_gpu_limits.array_size_constants` to indicate whether or not
      push constants can be used to size arrays
    - add PL_HANDLE_MTL_TEX, PL_HANDLE_IOSURFACE and `pl_shared_mem.plane`
      to improve interop with MoltenVK
    - add the informational fields `pl_opengl.major, `pl_opengl.minor`,
      `pl_opengl_extensions` and the `pl_opengl_has_ext` utility function
    - add `pl_opengl_params.get_proc_addr` and `get_proc_addr_ex`
    - add `pl_deband_params.grain_neutral`, the effect of which is to scale
      down / disable adding noise near this value
    - add <libplacebo/shaders/deinterlacing.h>, containing a basic
      implementation of yadif, bob and weave
    - add support for deinterlacing metadata to `pl_render_params`,
      `pl_frame`, and `pl_source_frame`
    - add <libplacebo/shaders/dithering.h>, splitting this off from its
      previous location inside <libplacebo/shaders/colorspace.h>
    - add `pl_shader_error_diffusion` and related helper functions, as well
      as `pl_render_params.error_diffusion`
    - add `pl_dither_params.transfer` to support gamma-aware dithering
    - add `pl_icc_params.force_bpc` to help work around black point
      compensation issues on "broken" v4 and v2 profiles
    
    Changes:
    - fields and functions deprecated in libplacebo v3 have been removed
    - `python3-mako` is now bundled as a submodule to make resolving this
      dependency easier
    - drop `libepoxy` as a dependency, and require `glad` v2 instead, the
      latter of which is added as a submodule to make building easier
    - drop the `PL_STRUCT` transitional macro, and switch to a consistent
      API where e.g. `pl_tex` is a typedef of `const struct pl_tex_t *`.
    - `PL_LUT_CONVERSION` now explicitly overrides ICC profiles as well
    - HDR color spaces no longer default to having a black point of 0.005
      nits, instead now defaulting to "true" black (1e-7 nits)
    - BT.1886 sources are now automatically tuned to match the swapchain /
      detected target contrast, rather than defaulting to 1000:1
    - move `pl_queue_params.frame_duration` to `pl_source_frame.duration`
    - the `vulkan-link` and `opengl-loader` boolean meson options have been
      removed in favor of the `vk-proc-addr` and `gl-proc-addr` feature
      flags, defaulting to `auto` instead of `yes`
    - a copy of `vulkan.h` and `vk.xml` have been bundled as submodules to
      make satisfying these dependencies easier
    - `<libplacebo/opengl.h>`, `<libplacebo/vulkan.h>` and
      `<libplacebo/d3d11.h`> are now installed unconditonally, with stubs
      for `pl_vulkan_create` etc. available even if these features are
      disabled at compile time
    - `pl_render_info.index` no longer indicates the number of frames being
      mixed on PL_RENDER_STAGE_BLEND, instead being relegated to the new
      field `pl_render_info.count`
    - `pl_shader_sample_ortho` has been reworked in order to fix a design
      flaw in its API, see `pl_shader_sample_ortho2` for its replacement
    
    Fixes and performance enhancements:
    - fix a bug where shaders with dynamically sized arrays would fail to
      compile on MoltenVK
    - reduce the frequency at which polar compute shaders need to be
      recompiled
    - fix compilation issues with MSVC
    - fix an issue where vulkan portability extensions were not correctly
      detected
    - fix a possible deadlock when using a multi-threaded opengl context
    - specify the correct calling convention for EGL debug callbacks
    - fix a bug where PL_INTENT_ABSOLUTE_COLORIMETRIC broke ICC profiles
    - improve the handling of perceptual ICC profiles, especially on
      "broken" v4 or v2 profiles
    - fix undefined behavior on 32-bit vulkan systems
    - fix bugs in the vulkan swapchain recreation
    - fix an issue where HDR metadata was not correctly reflected back to
      the renderer on vulkan swapchains
    - fix a bug where d3d11 swapchains failed being created on older
      versions of windows where high-bit-depth swapchains are unavailable
    - fix a bug where HDR metadata sent to the swapchain was not correctly
      inferred to valid values
    - `pl_shader_deband` has been rewritten to slightly improve performance,
      especially when the texture has more channels than necessary
    - `pl_shader_deband` no longer raises the black point due to clipping
    - fix build issues on GCC < 6
    - improve validity of partially set `pl_color_space` structs
    - fix `pl_find_tone_map_function` not having an implementation
    - fix a bug where cubic spline frame mixing did not work in `plplay`
    - fix a memory leak in `pl_queue_destroy`
    - fix a bug where changing `pl_icc_params.max_luma` or `intent` did not
      correctly invalidate the ICC 3DLUT and renderer cache
    - greatly improve the performance and accuracy of 3DLUTs (ICC, .cube)
    - fix compilation on newer glslang and make this code forward-compatible
    - fix an issue where `pl_shader_dither` raised the apparent brightness
      of the image when dithering to low bit depths
    - fix compilation on vulkan systems with `vulkan.h` available but no
      vulkan loader
    - fix an issue where DV metadata requiring an EL was partially applied
    - fix an issue where PQ HDR sources were incorrectly assumed to have a
      black point scaled to the mastering display, rather than absolute zero
    - fix an issue where disabling `async_compute` led to undefined behavior
      on systems with async compute queues available
    - fix an issue where debanding was applied *after* user shaders, causing
      massive performance/quality loss in the case of user shaders that
      upscaled the input planes somehow - in exchange for a slight
      performance penalty when rendering a heavily cropped source image with
      debanding enabled
    - fix an issue where plane shaders were sometimes not correctly merged
      with the following image combination shader
    - fix an issue where inverse tone mapping did not work with
      `pl_tone_map_auto`
    - fix a massive performance regression in the non-compute fallback polar
      shader, especially on nvidia and apple systems - in exchange for a
      slight performance penalty on AMD systems
    - slightly boost the performance of shader LUTs in some very specific
      circumstances
    - fix an issue where nonlinear shader LUTs did not work on GLSL < 130
    - fix an issue where libdl was incorrectly required on windows
    - fix an issue where fullscreen exclusive mode triggered freezes on
      certain platforms (e.g. AMD+Windows), by disabling fs exclusive mode
    - fix an issue where the wrong (GLES) extension was used for EGL image
      imports on desktop GL
    - fix a bug where host pointer imports could trigger an assertion
      failure on some platforms (e.g. intel+windows)
    - fix build issues on some platforms (windows llvm/mingw, emscripten)
    
  • v5.228.0-rc2
    v5.228.0-rc2
    
    This is a major release, bumping up the major version to v5 and dropping
    all APIs deprecated in v3.x. The other major breaking change of this
    release is a switch away from the external `libepoxy` and `mako`
    dependencies in favor of the (optionally bundled) `glad2` and `jinja2`.
    These are now included, along with various other build-time dependencies,
    as git submodules. Users are advised to clone with `git clone
    --recursive` in order to satisfy these dependencies automatically, while
    distros maintainers are nonetheless encouraged to continue packaging
    them.
    
    In addition, this release brings with it a number of new features and
    changes - including support for fully automatic GPU deinterlacing, error
    diffusion dithering, gamma-aware dithering, and a number of improvements
    to the handling of HDR sources and output displays, as well as several
    notable bug fixes and performance enhancements.
    
    Additions:
    - add `pl_gpu_limits.array_size_constants` to indicate whether or not
      push constants can be used to size arrays
    - add PL_HANDLE_MTL_TEX, PL_HANDLE_IOSURFACE and `pl_shared_mem.plane`
      to improve interop with MoltenVK
    - add the informational fields `pl_opengl.major, `pl_opengl.minor`,
      `pl_opengl_extensions` and the `pl_opengl_has_ext` utility function
    - add `pl_opengl_params.get_proc_addr` and `get_proc_addr_ex`
    - add `pl_deband_params.grain_neutral`, the effect of which is to scale
      down / disable adding noise near this value
    - add <libplacebo/shaders/deinterlacing.h>, containing a basic
      implementation of yadif, bob and weave
    - add support for deinterlacing metadata to `pl_render_params`,
      `pl_frame`, and `pl_source_frame`
    - add <libplacebo/shaders/dithering.h>, splitting this off from its
      previous location inside <libplacebo/shaders/colorspace.h>
    - add `pl_shader_error_diffusion` and related helper functions, as well
      as `pl_render_params.error_diffusion`
    - add `pl_dither_params.transfer` to support gamma-aware dithering
    - add `pl_icc_params.force_bpc` to help work around black point
      compensation issues on "broken" v4 and v2 profiles
    
    Changes:
    - fields and functions deprecated in libplacebo v3 have been removed
    - `python3-mako` is now bundled as a submodule to make resolving this
      dependency easier
    - drop `libepoxy` as a dependency, and require `glad` v2 instead, the
      latter of which is added as a submodule to make building easier
    - drop the `PL_STRUCT` transitional macro, and switch to a consistent
      API where e.g. `pl_tex` is a typedef of `const struct pl_tex_t *`.
    - `PL_LUT_CONVERSION` now explicitly overrides ICC profiles as well
    - HDR color spaces no longer default to having a black point of 0.005
      nits, instead now defaulting to "true" black (1e-7 nits)
    - BT.1886 sources are now automatically tuned to match the swapchain /
      detected target contrast, rather than defaulting to 1000:1
    - move `pl_queue_params.frame_duration` to `pl_source_frame.duration`
    - the `vulkan-link` and `opengl-loader` boolean meson options have been
      removed in favor of the `vk-proc-addr` and `gl-proc-addr` feature
      flags, defaulting to `auto` instead of `yes`
    - a copy of `vulkan.h` and `vk.xml` have been bundled as submodules to
      make satisfying these dependencies easier
    - `<libplacebo/opengl.h>`, `<libplacebo/vulkan.h>` and
      `<libplacebo/d3d11.h`> are now installed unconditonally, with stubs
      for `pl_vulkan_create` etc. available even if these features are
      disabled at compile time
    - `pl_render_info.index` no longer indicates the number of frames being
      mixed on PL_RENDER_STAGE_BLEND, instead being relegated to the new
      field `pl_render_info.count`
    
    Fixes and performance enhancements:
    - fix a bug where shaders with dynamically sized arrays would fail to
      compile on MoltenVK
    - reduce the frequency at which polar compute shaders need to be
      recompiled
    - fix compilation issues with MSVC
    - fix an issue where vulkan portability extensions were not correctly
      detected
    - fix a possible deadlock when using a multi-threaded opengl context
    - specify the correct calling convention for EGL debug callbacks
    - fix a bug where PL_INTENT_ABSOLUTE_COLORIMETRIC broke ICC profiles
    - improve the handling of perceptual ICC profiles, especially on
      "broken" v4 or v2 profiles
    - fix undefined behavior on 32-bit vulkan systems
    - fix bugs in the vulkan swapchain recreation
    - fix an issue where HDR metadata was not correctly reflected back to
      the renderer on vulkan swapchains
    - fix a bug where d3d11 swapchains failed being created on older
      versions of windows where high-bit-depth swapchains are unavailable
    - fix a bug where HDR metadata sent to the swapchain was not correctly
      inferred to valid values
    - `pl_shader_deband` has been rewritten to slightly improve performance,
      especially when the texture has more channels than necessary
    - `pl_shader_deband` no longer raises the black point due to clipping
    - fix build issues on GCC < 6
    - improve validity of partially set `pl_color_space` structs
    - fix `pl_find_tone_map_function` not having an implementation
    - fix a bug where cubic spline frame mixing did not work in `plplay`
    - fix a memory leak in `pl_queue_destroy`
    - fix a bug where changing `pl_icc_params.max_luma` or `intent` did not
      correctly invalidate the ICC 3DLUT and renderer cache
    - greatly improve the performance and accuracy of 3DLUTs (ICC, .cube)
    - fix compilation on newer glslang and make this code forward-compatible
    - fix an issue where `pl_shader_dither` raised the apparent brightness
      of the image when dithering to low bit depths
    - fix compilation on vulkan systems with `vulkan.h` available but no
      vulkan loader
    - fix an issue where DV metadata requiring an EL was partially applied
    - fix an issue where PQ HDR sources were incorrectly assumed to have a
      black point scaled to the mastering display, rather than absolute zero
    - fix an issue where disabling `async_compute` led to undefined behavior
      on systems with async compute queues available
    - fix an issue where debanding was applied *after* user shaders, causing
      massive performance/quality loss in the case of user shaders that
      upscaled the input planes somehow - in exchange for a slight
      performance penalty when rendering a heavily cropped source image with
      debanding enabled
    - fix an issue where plane shaders were sometimes not correctly merged
      with the following image combination shader
    - fix an issue where inverse tone mapping did not work with
      `pl_tone_map_auto`
    - fix a massive performance regression in the non-compute fallback polar
      shader, especially on nvidia and apple systems - in exchange for a
      slight performance penalty on AMD systems
    - slightly boost the performance of shader LUTs in some very specific
      circumstances
    - fix an issue where nonlinear shader LUTs did not work on GLSL < 130
    - fix an issue where libdl was incorrectly required on windows
    - fix an issue where fullscreen exclusive mode triggered freezes on
      certain platforms (e.g. AMD+Windows), by disabling fs exclusive mode
    - fix an issue where the wrong (GLES) extension was used for EGL image
      imports on desktop GL
    
  • v5.228.0-rc1
    v5.228.0-rc1
    
    This is a major release, bumping up the major version to v5 and dropping
    all APIs deprecated in v3.x. The other major breaking change of this
    release is a switch away from the external `libepoxy` OpenGL dependency
    in favor of the (optionally bundled) `glad` version 2. This is now
    included, along with various other build-time dependencies, as git
    submodules. Users are advised to clone with `git clone --recursive` in
    order to satisfy these dependencies automatically, while distros
    maintainers are nonetheless encouraged to continue packaging them.
    
    In addition, this release brings with it a number of new features and
    changes - including support for fully automatic GPU deinterlacing, error
    diffusion dithering, gamma-aware dithering, and a number of improvements
    to the handling of HDR sources and output displays, as well as several
    notable bug fixes and performance enhancements.
    
    Additions:
    - add `pl_gpu_limits.array_size_constants` to indicate whether or not
      push constants can be used to size arrays
    - add PL_HANDLE_MTL_TEX, PL_HANDLE_IOSURFACE and `pl_shared_mem.plane`
      to improve interop with MoltenVK
    - add the informational fields `pl_opengl.major, `pl_opengl.minor`,
      `pl_opengl_extensions` and the `pl_opengl_has_ext` utility function
    - add `pl_opengl_params.get_proc_addr` and `get_proc_addr_ex`
    - add `pl_deband_params.grain_neutral`, the effect of which is to scale
      down / disable adding noise near this value
    - add <libplacebo/shaders/deinterlacing.h>, containing a basic
      implementation of yadif, bob and weave
    - add support for deinterlacing metadata to `pl_render_params`,
      `pl_frame`, and `pl_source_frame`
    - add <libplacebo/shaders/dithering.h>, splitting this off from its
      previous location inside <libplacebo/shaders/colorspace.h>
    - add `pl_shader_error_diffusion` and related helper functions, as well
      as `pl_render_params.error_diffusion`
    - add `pl_dither_params.transfer` to support gamma-aware dithering
    - add `pl_icc_params.force_bpc` to help work around black point
      compensation issues on "broken" v4 and v2 profiles
    
    Changes:
    - fields and functions deprecated in libplacebo v3 have been removed
    - `python3-mako` is now bundled as a submodule to make resolving this
      dependency easier
    - drop `libepoxy` as a dependency, and require `glad` v2 instead, the
      latter of which is added as a submodule to make building easier
    - drop the `PL_STRUCT` transitional macro, and switch to a consistent
      API where e.g. `pl_tex` is a typedef of `const struct pl_tex_t *`.
    - `PL_LUT_CONVERSION` now explicitly overrides ICC profiles as well
    - HDR color spaces no longer default to having a black point of 0.005
      nits, instead now defaulting to "true" black (1e-7 nits)
    - BT.1886 sources are now automatically tuned to match the swapchain /
      detected target contrast, rather than defaulting to 1000:1
    - move `pl_queue_params.frame_duration` to `pl_source_frame.duration`
    - the `vulkan-link` and `opengl-loader` boolean meson options have been
      removed in favor of the `vk-proc-addr` and `gl-proc-addr` feature
      flags, defaulting to `auto` instead of `yes`
    - a copy of `vulkan.h` and `vk.xml` have been bundled as submodules to
      make satisfying these dependencies easier
    - `<libplacebo/opengl.h>`, `<libplacebo/vulkan.h>` and
      `<libplacebo/d3d11.h`> are now installed unconditonally, with stubs
      for `pl_vulkan_create` etc. available even if these features are
      disabled at compile time
    - `pl_render_info.index` no longer indicates the number of frames being
      mixed on PL_RENDER_STAGE_BLEND, instead being relegated to the new
      field `pl_render_info.count`
    
    Fixes and performance enhancements:
    - fix a bug where shaders with dynamically sized arrays would fail to
      compile on MoltenVK
    - reduce the frequency at which polar compute shaders need to be
      recompiled
    - fix compilation issues with MSVC
    - fix an issue where vulkan portability extensions were not correctly
      detected
    - fix a possible deadlock when using a multi-threaded opengl context
    - specify the correct calling convention for EGL debug callbacks
    - fix a bug where PL_INTENT_ABSOLUTE_COLORIMETRIC broke ICC profiles
    - improve the handling of perceptual ICC profiles, especially on
      "broken" v4 or v2 profiles
    - fix undefined behavior on 32-bit vulkan systems
    - fix bugs in the vulkan swapchain recreation
    - fix an issue where HDR metadata was not correctly reflected back to
      the renderer on vulkan swapchains
    - fix a bug where d3d11 swapchains failed being created on older
      versions of windows where high-bit-depth swapchains are unavailable
    - fix a bug where HDR metadata sent to the swapchain was not correctly
      inferred to valid values
    - `pl_shader_deband` has been rewritten to slightly improve performance,
      especially when the texture has more channels than necessary
    - `pl_shader_deband` no longer raises the black point due to clipping
    - fix build issues on GCC < 6
    - improve validity of partially set `pl_color_space` structs
    - fix `pl_find_tone_map_function` not having an implementation
    - fix a bug where cubic spline frame mixing did not work in `plplay`
    - fix a memory leak in `pl_queue_destroy`
    - fix a bug where changing `pl_icc_params.max_luma` or `intent` did not
      correctly invalidate the ICC 3DLUT and renderer cache
    - greatly improve the performance and accuracy of 3DLUTs (ICC, .cube)
    - fix compilation on newer glslang and make this code forward-compatible
    - fix an issue where `pl_shader_dither` raised the apparent brightness
      of the image when dithering to low bit depths
    - fix compilation on vulkan systems with `vulkan.h` available but no
      vulkan loader
    - fix an issue where DV metadata requiring an EL was partially applied
    - fix an issue where PQ HDR sources were incorrectly assumed to have a
      black point scaled to the mastering display, rather than absolute zero
    - fix an issue where disabling `async_compute` led to undefined behavior
      on systems with async compute queues available
    - fix an issue where debanding was applied *after* user shaders, causing
      massive performance/quality loss in the case of user shaders that
      upscaled the input planes somehow - in exchange for a slight
      performance penalty when rendering a heavily cropped source image with
      debanding enabled
    - fix an issue where plane shaders were sometimes not correctly merged
      with the following image combination shader
    - fix an issue where inverse tone mapping did not work with
      `pl_tone_map_auto`
    - fix a massive performance regression in the non-compute fallback polar
      shader, especially on nvidia and apple systems - in exchange for a
      slight performance penalty on AMD systems
    - slightly boost the performance of shader LUTs in some very specific
      circumstances
    - fix an issue where nonlinear shader LUTs did not work on GLSL < 130
    
  • v4.208.0
    v4.208.0
    
    This major release brings with it a number of fixes and changes for
    compatibility with both upstream and downstream projects, native HDR
    output on D3D11, and a complete redesign of the way ICC profiles are
    handled.
    
    Additions:
    - add helper macros linearize() and delinearize(), expanding to the
      definition of the gamma function in use for the video signal
    - add various new helper functions relating to colorspaces and
      primaries, see the API change log for a more comprehensive list
    - add `pl_render_params.force_low_bit_depth_fbos` for
      debugging/performance tweaking purposes
    - add `pl_plane.flipped`, to allow representing individual flipped
      frames in a way that semantically decouples from the presentation rect
      (e.g. for OpenGL framebuffers, or planes with negative stride)
    - add '%' and '=' as operators to custom shaders, matching mpv
    - add `pl_vulkan.(un)lock_queue` for interop with other libraries
    - add `pl_frame.acquire/release` for better interop with hardware
      decoders. These are only called on an as-needed basis immediately
      before and after a frame is actually used for rendering, with only one
      frame being acquired at any given time
    - add `pl_film_grain_from_av` helper function
    - add support for configuring the swapchain color space on D3D11, using
      the existing pl_swapchain_colorspace_hint mechanism
    - add an entirely new ICC profile shader API, allowing ICC profiles to
      be persistently opened (pl_icc_open) and their metadata exposed,
      with explicit `pl_icc_decode` and `pl_icc_encode` operations instead
      of a single monolithic decode+apply step
    - add `pl_render_params.plane_up/downscaler`, allowing to override the
      upscaler/downscaler for subsampled chroma planes in particular
    - add `pl_filter_function/config.name` for debugging/logging purposes
    
    Changes:
    - pl_log_create is no longer an exported symbol, instead becoming
      versioned by the compiled API version. `pl_log_create` is now a macro
      expanding to the name of this versioned function
    - `pl_overlay_part` has been refactored, adding the new field `coords`
      to control the coordinate system relative to which the part is placed
      on-screen, as well as being generalized to support floating point
      positions
    - deprecate PL_HOOK_PRE_OVERLAY, as a result of overlays no longer being
      applied during the rendering pipeline
    - default `pl_color_map_params.gamut_mode` to PL_GAMUT_CLIP, replacing
      PL_GAMUT_DARKEN
    - DRM modifiers are now required for vulkan dmabuf interop
    - `pl_vulkan.queue_*` are now *always* set to valid queues for that
      operation type, even if it means including duplicates
    - `pl_render_image` with NULL image now reports itself as a blend pass
      (blending 0 frames) instead of a frame pass to the info callbacks
    - completely refactor/remove the old ICC/3DLUT shader API
      (`pl_icc_update`, `pl_icc_apply` etc.)
    - <libplacebo/shaders/icc.h> is now installed unconditionally, with
      `pl_icc_open` simply failing when built without lcms2
    - versions of glslang before the new versioning scheme (10.x.x) are no
      longer supported
    
    Fixes and performance enhancements:
    - fix pl_tone_map_reinhard.param_min to prevent division by zero
    - fix left-over asserts preventing misaligned buffer uploads via
      pl_upload_plane
    - fix bug where emulated rgb textures had alpha incorrectly
      preinitialized to 0 instead of 1
    - overlays are now always rendered onto the final blended image, solving
      various bugs and unexpected edge cases due to image overlays being
      blended in the middle of the rendering pipeline
    - fix a bug where tone-mapping without a state object resulted in broken
      behavior
    - allow `pl_shader_sample_polar` to work with external samplers or
      flipped textures without incurring a performance penalty
    - fix the behavior of pl_shader_sample_oversample, which was previously
      producing very wrong results
    - fix an issue where the dither depth was incorrectly picked in a number
      of edge cases
    - fix a number of issues with the H.274 film grain shader
    - fix a bug where grayscale images were slightly too green
    - fix a bug where `pl_vulkan.queue_transfer` was never set
    - fix possible UB in pl_opengl_wrap_tex on some drivers with broken
      texture channel depth queries
    - fix issue where some shader LUTs were being regenerated on every
      single frame rather than properly cached
    - fix shader compilation error on older GLSL
    - fix bug where images were sometimes undesiredly being scaled in linear
      light
    - fix SDR<->SDR tone-mapping to properly be a no-op (linear stretch)
    - fix use-after-free in pl_get_buffer2's error path
    - fix d3d11 build issues on older versions of the SDK
    - fix edge case where auto-detected vulkan in the absence of
      glslang/shaderc caused the build to fail
    - fix build issues with up-to-date vulkan SDK
    - fix issue where non-coherent buffer imports were used in ways not
      adhering to the non-coherent memory atom size
    - fix various issues and undefined behavior when flushing mapped
      buffers, especially for non-coherent memory
    - avoid some validation warnings about improper pipeline barriers
    - fix runtime error with up-to-date MoltenVK
    - fix issue where some pl_frame_mix structs resulted no frames being
      mixed, triggering an assertion
    - fix bug where overlays were drawn flipped onto flipped planes when
      rendering a NULL image
    - fix allocation alignment issues on some platforms (notably win32 i686)
    - fix compatibility issues with older macOS
    - fix error handling in pl_cond_timedwait
    - fix build issues with older vulkan versions
    - fix build issue of demos/sdlimage in some configurations
    - reduce VRAM consumption of ICC 3DLUTs by 50%
    
  • v4.208.0-rc2
    v4.208.0-rc2
    
    This major release brings with it a number of fixes and changes for
    compatibility with both upstream and downstream projects, native HDR
    output on D3D11, and a complete redesign of the way ICC profiles are
    handled.
    
    Additions:
    - add helper macros linearize() and delinearize(), expanding to the
      definition of the gamma function in use for the video signal
    - add various new helper functions relating to colorspaces and
      primaries, see the API change log for a more comprehensive list
    - add `pl_render_params.force_low_bit_depth_fbos` for
      debugging/performance tweaking purposes
    - add `pl_plane.flipped`, to allow representing individual flipped
      frames in a way that semantically decouples from the presentation rect
      (e.g. for OpenGL framebuffers, or planes with negative stride)
    - add '%' and '=' as operators to custom shaders, matching mpv
    - add `pl_vulkan.(un)lock_queue` for interop with other libraries
    - add `pl_frame.acquire/release` for better interop with hardware
      decoders. These are only called on an as-needed basis immediately
      before and after a frame is actually used for rendering, with only one
      frame being acquired at any given time
    - add `pl_film_grain_from_av` helper function
    - add support for configuring the swapchain color space on D3D11, using
      the existing pl_swapchain_colorspace_hint mechanism
    - add an entirely new ICC profile shader API, allowing ICC profiles to
      be persistently opened (pl_icc_open) and their metadata exposed,
      with explicit `pl_icc_decode` and `pl_icc_encode` operations instead
      of a single monolithic decode+apply step
    - add `pl_render_params.plane_up/downscaler`, allowing to override the
      upscaler/downscaler for subsampled chroma planes in particular
    - add `pl_filter_function/config.name` for debugging/logging purposes
    
    Changes:
    - pl_log_create is no longer an exported symbol, instead becoming
      versioned by the compiled API version. `pl_log_create` is now a macro
      expanding to the name of this versioned function
    - `pl_overlay_part` has been refactored, adding the new field `coords`
      to control the coordinate system relative to which the part is placed
      on-screen, as well as being generalized to support floating point
      positions
    - deprecate PL_HOOK_PRE_OVERLAY, as a result of overlays no longer being
      applied during the rendering pipeline
    - default `pl_color_map_params.gamut_mode` to PL_GAMUT_CLIP, replacing
      PL_GAMUT_DARKEN
    - DRM modifiers are now required for vulkan dmabuf interop
    - `pl_vulkan.queue_*` are now *always* set to valid queues for that
      operation type, even if it means including duplicates
    - `pl_render_image` with NULL image now reports itself as a blend pass
      (blending 0 frames) instead of a frame pass to the info callbacks
    - completely refactor/remove the old ICC/3DLUT shader API
      (`pl_icc_update`, `pl_icc_apply` etc.)
    - <libplacebo/shaders/icc.h> is now installed unconditionally, with
      `pl_icc_open` simply failing when built without lcms2
    - versions of glslang before the new versioning scheme (10.x.x) are no
      longer supported
    
    Fixes and performance enhancements:
    - fix pl_tone_map_reinhard.param_min to prevent division by zero
    - fix left-over asserts preventing misaligned buffer uploads via
      pl_upload_plane
    - fix bug where emulated rgb textures had alpha incorrectly
      preinitialized to 0 instead of 1
    - overlays are now always rendered onto the final blended image, solving
      various bugs and unexpected edge cases due to image overlays being
      blended in the middle of the rendering pipeline
    - fix a bug where tone-mapping without a state object resulted in broken
      behavior
    - allow `pl_shader_sample_polar` to work with external samplers or
      flipped textures without incurring a performance penalty
    - fix the behavior of pl_shader_sample_oversample, which was previously
      producing very wrong results
    - fix an issue where the dither depth was incorrectly picked in a number
      of edge cases
    - fix a number of issues with the H.274 film grain shader
    - fix a bug where grayscale images were slightly too green
    - fix a bug where `pl_vulkan.queue_transfer` was never set
    - fix possible UB in pl_opengl_wrap_tex on some drivers with broken
      texture channel depth queries
    - fix issue where some shader LUTs were being regenerated on every
      single frame rather than properly cached
    - fix shader compilation error on older GLSL
    - fix bug where images were sometimes undesiredly being scaled in linear
      light
    - fix SDR<->SDR tone-mapping to properly be a no-op (linear stretch)
    - fix use-after-free in pl_get_buffer2's error path
    - fix d3d11 build issues on older versions of the SDK
    - fix edge case where auto-detected vulkan in the absence of
      glslang/shaderc caused the build to fail
    - fix build issues with up-to-date vulkan SDK
    - fix issue where non-coherent buffer imports were used in ways not
      adhering to the non-coherent memory atom size
    - fix various issues and undefined behavior when flushing mapped
      buffers, especially for non-coherent memory
    - avoid some validation warnings about improper pipeline barriers
    - fix runtime error with up-to-date MoltenVK
    - fix issue where some pl_frame_mix structs resulted no frames being
      mixed, triggering an assertion
    - fix bug where overlays were drawn flipped onto flipped planes when
      rendering a NULL image
    - fix allocation alignment issues on some platforms (notably win32 i686)
    - fix compatibility issues with older macOS
    - fix error handling in pl_cond_timedwait
    - fix build issues with older vulkan versions
    - fix build issue of demos/sdlimage in some configurations
    
  • v4.208.0-rc1
    v4.208.0-rc1
    
    This major release brings with it a number of fixes and changes for
    compatibility with both upstream and downstream projects, native HDR
    output on D3D11, and a complete redesign of the way ICC profiles are
    handled.
    
    Additions:
    - add helper macros linearize() and delinearize(), expanding to the
      definition of the gamma function in use for the video signal
    - add various new helper functions relating to colorspaces and
      primaries, see the API change log for a more comprehensive list
    - add `pl_render_params.force_low_bit_depth_fbos` for
      debugging/performance tweaking purposes
    - add `pl_plane.flipped`, to allow representing individual flipped
      frames in a way that semantically decouples from the presentation rect
      (e.g. for OpenGL framebuffers, or planes with negative stride)
    - add '%' and '=' as operators to custom shaders, matching mpv
    - add `pl_vulkan.(un)lock_queue` for interop with other libraries
    - add `pl_frame.acquire/release` for better interop with hardware
      decoders. These are only called on an as-needed basis immediately
      before and after a frame is actually used for rendering, with only one
      frame being acquired at any given time
    - add `pl_film_grain_from_av` helper function
    - add support for configuring the swapchain color space on D3D11, using
      the existing pl_swapchain_colorspace_hint mechanism
    - add an entirely new ICC profile shader API, allowing ICC profiles to
      be persistently opened (pl_icc_open) and their metadata exposed,
      with explicit `pl_icc_decode` and `pl_icc_encode` operations instead
      of a single monolithic decode+apply step
    - add `pl_render_params.plane_up/downscaler`, allowing to override the
      upscaler/downscaler for subsampled chroma planes in particular
    - ad `pl_filter_function/config.name` for debugging/logging purposes
    
    Changes:
    - pl_log_create is no longer an exported symbol, instead becoming
      versioned by the compiled API version. `pl_log_create` is now a macro
      expanding to the name of this versioned function
    - `pl_overlay_part` has been refactored, adding the new field `coords`
      to control the coordinate system relative to which the part is placed
      on-screen, as well as being generalized to support floating point
      positions
    - deprecate PL_HOOK_PRE_OVERLAY, as a result of overlays no longer being
      applied during the rendering pipeline
    - default `pl_color_map_params.gamut_mode` to PL_GAMUT_CLIP, replacing
      PL_GAMUT_DARKEN
    - DRM modifiers are now required for vulkan dmabuf interop
    - `pl_vulkan.queue_*` are now *always* set to valid queues for that
      operation type, even if it means including duplicates
    - `pl_render_image` with NULL image now reports itself as a blend pass
      (blending 0 frames) instead of a frame pass to the info callbacks
    - completely refactor/remove the old ICC/3DLUT shader API
      (`pl_icc_update`, `pl_icc_apply` etc.)
    - <libplacebo/shaders/icc.h> is now installed unconditionally, with
      `pl_icc_open` simply failing when built without lcms2
    
    Fixes and performance enhancements:
    - fix pl_tone_map_reinhard.param_min to prevent division by zero
    - fix left-over asserts preventing misaligned buffer uploads via
      pl_upload_plane
    - fix bug where emulated rgb textures had alpha incorrectly
      preinitialized to 0 instead of 1
    - overlays are now always rendered onto the final blended image, solving
      various bugs and unexpected edge cases due to image overlays being
      blended in the middle of the rendering pipeline
    - fix a bug where tone-mapping without a state object resulted in broken
      behavior
    - allow `pl_shader_sample_polar` to work with external samplers or
      flipped textures without incurring a performance penalty
    - fix the behavior of pl_shader_sample_oversample, which was previously
      producing very wrong results
    - fix an issue where the dither depth was incorrectly picked in a number
      of edge cases
    - fix a number of issues with the H.274 film grain shader
    - fix a bug where grayscale images were slightly too green
    - fix a bug where `pl_vulkan.queue_transfer` was never set
    - fix possible UB in pl_opengl_wrap_tex on some drivers with broken
      texture channel depth queries
    - fix issue where some shader LUTs were being regenerated on every
      single frame rather than properly cached
    - fix shader compilation error on older GLSL
    - fix bug where images were sometimes undesiredly being scaled in linear
      light
    - fix SDR<->SDR tone-mapping to properly be a no-op (linear stretch)
    - fix use-after-free in pl_get_buffer2's error path
    - fix d3d11 build issues on older versions of the SDK
    - fix edge case where auto-detected vulkan in the absence of
      glslang/shaderc caused the build to fail
    - fix build issues with up-to-date vulkan SDK
    - fix issue where non-coherent buffer imports were used in ways not
      adhering to the non-coherent memory atom size
    - fix various issues and undefined behavior when flushing mapped
      buffers, especially for non-coherent memory
    - avoid some validation warnings about improper pipeline barriers
    - fix runtime error with up-to-date MoltenVK
    - fix issue where some pl_frame_mix structs resulted no frames being
      mixed, triggering an assertion
    - fix bug where overlays were drawn flipped onto flipped planes when
      rendering a NULL image