Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package libplacebo for openSUSE:Factory 
checked in at 2023-03-24 15:16:42
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/libplacebo (Old)
 and      /work/SRC/openSUSE:Factory/.libplacebo.new.31432 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "libplacebo"

Fri Mar 24 15:16:42 2023 rev:25 rq:1074110 version:5.264.1

Changes:
--------
--- /work/SRC/openSUSE:Factory/libplacebo/libplacebo.changes    2023-03-17 
17:02:24.849099370 +0100
+++ /work/SRC/openSUSE:Factory/.libplacebo.new.31432/libplacebo.changes 
2023-03-24 15:16:44.353727565 +0100
@@ -1,0 +2,12 @@
+Thu Mar 23 15:01:17 UTC 2023 - Niklas Haas <o...@haasn.xyz>
+
+- Update libplacebo to version 5.264.1. See details in:
+    https://code.videolan.org/videolan/libplacebo/-/tags/v5.264.0
+- Bump meson dependency to 0.63
+
+-------------------------------------------------------------------
+Sun Mar 19 09:56:56 UTC 2023 - Jan Engelhardt <jeng...@inai.de>
+
+- Add baselibs.conf (for the sake of ffmpeg)
+
+-------------------------------------------------------------------

Old:
----
  libplacebo-v5.264.0.tar.bz2

New:
----
  baselibs.conf
  libplacebo-v5.264.1.tar.bz2

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ libplacebo.spec ++++++
--- /var/tmp/diff_new_pack.fBfJxN/_old  2023-03-24 15:16:44.857730255 +0100
+++ /var/tmp/diff_new_pack.fBfJxN/_new  2023-03-24 15:16:44.857730255 +0100
@@ -18,7 +18,7 @@
 
 %define sover   264
 Name:           libplacebo
-Version:        5.264.0
+Version:        5.264.1
 Release:        0
 Summary:        Library for GPU-accelerated video/image rendering primitives
 License:        LGPL-2.1-or-later
@@ -26,9 +26,10 @@
 URL:            https://code.videolan.org/videolan/libplacebo
 Source0:        
https://code.videolan.org/videolan/libplacebo/-/archive/v%{version}/libplacebo-v%{version}.tar.bz2
 Source1:        
https://github.com/Immediate-Mode-UI/Nuklear/raw/c512ac886425f6b6b6c816d67f4cb1385cd4cc53/nuklear.h
+Source9:        baselibs.conf
 BuildRequires:  c++_compiler
 BuildRequires:  c_compiler
-BuildRequires:  meson >= 0.59.0
+BuildRequires:  meson >= 0.63.0
 BuildRequires:  pkgconfig
 BuildRequires:  python3-Jinja2
 BuildRequires:  python3-glad2

++++++ baselibs.conf ++++++
libplacebo264

++++++ libplacebo-v5.264.0.tar.bz2 -> libplacebo-v5.264.1.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/libplacebo-v5.264.0/README.md 
new/libplacebo-v5.264.1/README.md
--- old/libplacebo-v5.264.0/README.md   2023-03-13 13:07:23.000000000 +0100
+++ new/libplacebo-v5.264.1/README.md   2023-03-23 15:53:00.000000000 +0100
@@ -246,10 +246,6 @@
 
 ## Installing
 
-### Gentoo
-
-An ebuild is available as `media-libs/libplacebo` in the gentoo repository.
-
 ### Obtaining
 
 When cloning libplacebo, make sure to provide the `--recursive``` flag:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/libplacebo-v5.264.0/meson.build 
new/libplacebo-v5.264.1/meson.build
--- old/libplacebo-v5.264.0/meson.build 2023-03-13 13:07:23.000000000 +0100
+++ new/libplacebo-v5.264.1/meson.build 2023-03-23 15:53:00.000000000 +0100
@@ -6,7 +6,7 @@
     'c_std=c11',
     'cpp_std=c++11',
   ],
-  meson_version: '>=0.59',
+  meson_version: '>=0.63',
   version: '@0@.@1@.@2@'.format(
     # Major version
     5,
@@ -278,7 +278,7 @@
       '1': '',
     }.keys().length(),
     # Fix version
-    0)
+    1)
 )
 
 ### Version number and configuration
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/libplacebo-v5.264.0/src/colorspace.c 
new/libplacebo-v5.264.1/src/colorspace.c
--- old/libplacebo-v5.264.0/src/colorspace.c    2023-03-13 13:07:23.000000000 
+0100
+++ new/libplacebo-v5.264.1/src/colorspace.c    2023-03-23 15:53:00.000000000 
+0100
@@ -597,6 +597,8 @@
         avg_luma = pl_hdr_rescale(PL_HDR_PQ, scaling, csp->hdr.avg_pq_y);
     }
 
+    if (min_luma < 0)
+        min_luma = 0; // sanity
     if (max_luma && min_luma > max_luma) // sanity
         min_luma = max_luma = 0;
 
@@ -644,8 +646,9 @@
         .color      = space,
         .metadata   = PL_HDR_METADATA_HDR10,
         .scaling    = PL_HDR_NITS,
-        .out_min    = &space->hdr.min_luma,
         .out_max    = &space->hdr.max_luma,
+        // Preserve tagged minimum
+        .out_min    = space->hdr.min_luma ? NULL : &space->hdr.min_luma,
     ));
 
     // Default the signal color space based on the nominal raw primaries
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/libplacebo-v5.264.0/src/opengl/context.c 
new/libplacebo-v5.264.1/src/opengl/context.c
--- old/libplacebo-v5.264.0/src/opengl/context.c        2023-03-13 
13:07:23.000000000 +0100
+++ new/libplacebo-v5.264.1/src/opengl/context.c        2023-03-23 
15:53:00.000000000 +0100
@@ -155,9 +155,9 @@
     }
 
     if (!ok) {
-        PL_INFO(p, "Failed loading core GL, retrying as GLES2...");
+        PL_INFO(p, "Failed loading core GL, retrying as GLES...");
     } else if (gl_is_gles(pl_gl)) {
-        PL_INFO(p, "GL context seems to be OpenGL ES, reloading as GLES2...");
+        PL_INFO(p, "GL context seems to be OpenGL ES, reloading as GLES...");
         ok = false;
     }
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/libplacebo-v5.264.0/src/pl_alloc.c 
new/libplacebo-v5.264.1/src/pl_alloc.c
--- old/libplacebo-v5.264.0/src/pl_alloc.c      2023-03-13 13:07:23.000000000 
+0100
+++ new/libplacebo-v5.264.1/src/pl_alloc.c      2023-03-23 15:53:00.000000000 
+0100
@@ -221,6 +221,7 @@
         h->ext->children[i]->parent = NULL; // prevent recursive access
         pl_free(h->ext->children[i]->data);
     }
+    h->ext->num_children = 0;
 
 #ifndef NDEBUG
     h->magic = MAGIC;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/libplacebo-v5.264.0/src/renderer.c 
new/libplacebo-v5.264.1/src/renderer.c
--- old/libplacebo-v5.264.0/src/renderer.c      2023-03-13 13:07:23.000000000 
+0100
+++ new/libplacebo-v5.264.1/src/renderer.c      2023-03-23 15:53:00.000000000 
+0100
@@ -1575,6 +1575,7 @@
             GLSL("} \n");
 
             sti->img.fmt = fmt;
+            pl_dispatch_abort(rr->dp, &stj->img.sh);
             *stj = (struct plane_state) {0};
             did_merge = true;
         }
@@ -2707,6 +2708,11 @@
     fix_refs_and_rects(pass);
     find_fbo_format(pass);
 
+    // Update ICC profiles, do this before inferring color space parameters
+    // because the ICC profile may override tagged values
+    pass->src_icc = acquire_image ? update_icc(pass, &rr->icc[0], image) : 
NULL;
+    pass->dst_icc = update_icc(pass, &rr->icc[1], target);
+
     // Infer the target color space info based on the image's
     if (image) {
         fix_frame(image);
@@ -2745,10 +2751,6 @@
         }
     }
 
-    // Update ICC profiles
-    pass->src_icc = acquire_image ? update_icc(pass, &rr->icc[0], image) : 
NULL;
-    pass->dst_icc = update_icc(pass, &rr->icc[1], target);
-
     pass->tmp = pl_tmp(NULL);
     return true;
 
@@ -3272,7 +3274,7 @@
     pl_assert(fidx > 0);
 
     pl_shader sh = pl_dispatch_begin(rr->dp);
-    sh_describe(sh, "frame mixing");
+    sh_describef(sh, "frame mixing (%d frame%s)", fidx, fidx > 1 ? "s" : "");
     sh->res.output = PL_SHADER_SIG_COLOR;
     sh->output_w = out_w;
     sh->output_h = out_h;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/libplacebo-v5.264.0/src/shaders/colorspace.c 
new/libplacebo-v5.264.1/src/shaders/colorspace.c
--- old/libplacebo-v5.264.0/src/shaders/colorspace.c    2023-03-13 
13:07:23.000000000 +0100
+++ new/libplacebo-v5.264.1/src/shaders/colorspace.c    2023-03-23 
15:53:00.000000000 +0100
@@ -1366,10 +1366,9 @@
 
 const struct pl_color_map_params pl_color_map_default_params = { 
PL_COLOR_MAP_DEFAULTS };
 
-static inline void visualize_tone_map(pl_shader sh, ident_t fun,
-                                      float xmin, float xmax, float xavg,
-                                      float ymin, float ymax,
-                                      struct pl_rect2df rc)
+static void visualize_tone_map(pl_shader sh, ident_t fun,
+                               float xmin, float xmax, float xavg,
+                               float ymin, float ymax, struct pl_rect2df rc)
 {
     if (!rc.x0 && !rc.x1)
         rc.x1 = 1.0f;
@@ -1433,6 +1432,8 @@
          "    if (pos.y > xmax) {                   \n" // inverse 
tone-mapping region
          "        vec3 hi = vec3(0.2, 0.5, 0.8);    \n"
          "        viz = mix(viz, hi, 0.5);          \n"
+         "    } else if (pos.y < xmin) {            \n" // black point region
+         "        viz = mix(viz, vec3(0.0), 0.3);   \n"
          "    }                                     \n"
          "    if (xavg > 0.0 && abs(pos.x - xavg) < 1e-3)\n" // source avg 
brightness
          "        viz = vec3(0.5);                  \n"
@@ -1541,18 +1542,15 @@
     if (pl_tone_map_params_noop(&lut_params))
         return;
 
-    sh_describef(sh, "tone mapping (%d -> %d nits%s)",
-                 (int) roundf(pl_hdr_rescale(PL_HDR_NORM, PL_HDR_NITS, 
src_max)),
-                 (int) roundf(pl_hdr_rescale(PL_HDR_NORM, PL_HDR_NITS, 
dst_max)),
-                 src_min != dst_min ? " + BPC" : "");
-
     const struct pl_tone_map_function *fun = lut_params.function;
+    sh_describef(sh, "%s tone map (%.0f -> %.0f)", fun->name,
+                 pl_hdr_rescale(PL_HDR_NORM, PL_HDR_NITS, src_max),
+                 pl_hdr_rescale(PL_HDR_NORM, PL_HDR_NITS, dst_max));
     ident_t lut = NULL;
 
     bool can_fixed = !params->force_tone_mapping_lut;
-    bool is_clip = can_fixed && (!fun || fun == &pl_tone_map_clip);
-    bool is_linear = can_fixed && fun == &pl_tone_map_linear &&
-                     (!lut_params.param || lut_params.param == 1.0f);
+    bool is_clip = can_fixed && fun == &pl_tone_map_clip;
+    bool is_linear = can_fixed && fun == &pl_tone_map_linear;
 
     if (state && !(is_clip || is_linear)) {
         struct sh_tone_map_obj *obj;
@@ -1583,39 +1581,41 @@
 
     } else if (is_linear) {
 
+        const float gain = PL_DEF(lut_params.param, 1.0f);
         const float pq_src_min = pl_hdr_rescale(PL_HDR_NORM, PL_HDR_PQ, 
src_min);
         const float pq_src_max = pl_hdr_rescale(PL_HDR_NORM, PL_HDR_PQ, 
src_max);
         const float pq_dst_min = pl_hdr_rescale(PL_HDR_NORM, PL_HDR_PQ, 
dst_min);
         const float pq_dst_max = pl_hdr_rescale(PL_HDR_NORM, PL_HDR_PQ, 
dst_max);
+        const float src_scale = gain / (pq_src_max - pq_src_min);
+        const float dst_scale = pq_dst_max - pq_dst_min;
 
-        ident_t bpc = sh_fresh(sh, "bpc_pq");
+        ident_t linfun = sh_fresh(sh, "linear_pq");
         GLSLH("float %s(float x) {                          \n"
              // PQ OETF
              "    x *= %f;                                  \n"
              "    x = pow(max(x, 0.0), %f);                 \n"
              "    x = (%f + %f * x) / (1.0 + %f * x);       \n"
              "    x = pow(x, %f);                           \n"
-             // Stretch the black point
-             "    x -= %s;                                  \n"
-             "    x *= %s;                                  \n"
-             "    x += %s;                                  \n"
+             // Stretch the input range (while clipping)
+             "    x = %s * x + %s;                          \n"
+             "    x = clamp(x, 0.0, 1.0);                   \n"
+             "    x = %s * x + %s;                          \n"
              // PQ EOTF
-             "    x = pow(max(x, 0.0), 1.0/%f);             \n"
+             "    x = pow(x, 1.0 / %f);                     \n"
              "    x = max(x - %f, 0.0) / (%f - %f * x);     \n"
              "    x = pow(x, 1.0 / %f);                     \n"
              "    x *= %f;                                  \n"
              "    return x;                                 \n"
              "}                                             \n",
-             bpc,
+             linfun,
              PL_COLOR_SDR_WHITE / 10000.0,
              PQ_M1, PQ_C1, PQ_C2, PQ_C3, PQ_M2,
-             SH_FLOAT_DYN(pq_src_min),
-             SH_FLOAT_DYN((pq_dst_max - pq_dst_min) / (pq_src_max - 
pq_src_min)),
-             SH_FLOAT(pq_dst_min),
+             SH_FLOAT_DYN(src_scale), SH_FLOAT_DYN(-src_scale * pq_src_min),
+             SH_FLOAT_DYN(dst_scale), SH_FLOAT(pq_dst_min),
              PQ_M2, PQ_C1, PQ_C2, PQ_C3, PQ_M1,
              10000.0 / PL_COLOR_SDR_WHITE);
 
-        GLSL("#define tone_map(x) (%s(x)) \n", bpc);
+        GLSL("#define tone_map(x) (%s(x)) \n", linfun);
 
     } else if (lut) {
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/libplacebo-v5.264.0/src/shaders/icc.c 
new/libplacebo-v5.264.1/src/shaders/icc.c
--- old/libplacebo-v5.264.0/src/shaders/icc.c   2023-03-13 13:07:23.000000000 
+0100
+++ new/libplacebo-v5.264.1/src/shaders/icc.c   2023-03-23 15:53:00.000000000 
+0100
@@ -29,6 +29,7 @@
 #include <lcms2_plugin.h>
 
 struct icc_priv {
+    pl_log log;
     cmsContext cms;
     cmsHPROFILE profile;
     cmsHPROFILE approx; // approximation profile
@@ -58,8 +59,8 @@
     pl_free_ptr((void **) picc);
 }
 
-static bool detect_csp(pl_log pllog, pl_icc_object icc,
-                       struct pl_raw_primaries *prim, float *gamma)
+static bool detect_csp(pl_icc_object icc, struct pl_raw_primaries *prim,
+                       float *out_gamma)
 {
     struct icc_priv *p = PL_PRIV(icc);
     cmsHTRANSFORM tf;
@@ -168,16 +169,16 @@
     }
     S = sqrt(S / (k - 1));
     if (S > 0.5) {
-        pl_warn(pllog, "Detected profile gamma (%.3f) very far from pure power 
"
+        PL_WARN(p, "Detected profile gamma (%.3f) very far from pure power "
                 "response (stddev=%.1f), suspected unusual or broken profile. "
-                "Ignoring, but results may be poor.", M, S);
+                "Using anyway, but results may be poor.", M, S);
     } else if (!(M > 0)) {
-        pl_err(pllog, "Arithmetic error in ICC profile gamma estimation? "
+        PL_ERR(p, "Arithmetic error in ICC profile gamma estimation? "
                "Please open an issue");
         return false;
     }
 
-    *gamma = M;
+    *out_gamma = M;
     p->gamma_stddev = S;
     return true;
 }
@@ -193,8 +194,10 @@
      * brightness value here */
     if (intent == PL_INTENT_ABSOLUTE_COLORIMETRIC)
         intent = PL_INTENT_RELATIVE_COLORIMETRIC;
-    if (!cmsDetectDestinationBlackPoint(&p->black, p->profile, intent, 0))
+    if (!cmsDetectDestinationBlackPoint(&p->black, p->profile, intent, 0)) {
+        PL_ERR(p, "Failed detecting ICC profile black point!");
         return false;
+    }
 
     if (max_luma <= 0)
         max_luma = white ? white->Y : PL_COLOR_SDR_WHITE;
@@ -205,12 +208,12 @@
     return true;
 }
 
-static void infer_clut_size(pl_log log, struct pl_icc_object_t *icc)
+static void infer_clut_size(struct pl_icc_object_t *icc)
 {
     struct icc_priv *p = PL_PRIV(icc);
     struct pl_icc_params *params = &icc->params;
     if (params->size_r && params->size_g && params->size_b) {
-        pl_debug(log, "Using fixed 3DLUT size: %dx%dx%d",
+        PL_DEBUG(p, "Using fixed 3DLUT size: %dx%dx%d",
                  (int) params->size_r, (int) params->size_g, (int) 
params->size_b);
         return;
     }
@@ -314,7 +317,7 @@
         params->size_b = ceilf(factor * params->size_b);
     }
 
-    pl_info(log, "Chosen 3DLUT size: %dx%dx%d",
+    PL_INFO(p, "Chosen 3DLUT size: %dx%dx%d",
             (int) params->size_r, (int) params->size_g, (int) params->size_b);
 }
 
@@ -329,22 +332,23 @@
     struct pl_icc_params *params = &icc->params;
     *params = pparams ? *pparams : pl_icc_default_params;
     icc->signature = profile->signature;
+    p->log = log;
     p->cms = cmsCreateContext(NULL, (void *) log);
     if (!p->cms) {
-        pl_err(log, "Failed creating LittleCMS context!");
+        PL_ERR(p, "Failed creating LittleCMS context!");
         goto error;
     }
 
     cmsSetLogErrorHandlerTHR(p->cms, error_callback);
-    pl_info(log, "Opening ICC profile..");
+    PL_INFO(p, "Opening ICC profile..");
     p->profile = cmsOpenProfileFromMemTHR(p->cms, profile->data, profile->len);
     if (!p->profile) {
-        pl_err(log, "Failed opening ICC profile");
+        PL_ERR(p, "Failed opening ICC profile");
         goto error;
     }
 
     if (cmsGetColorSpace(p->profile) != cmsSigRgbData) {
-        pl_err(log, "Invalid ICC profile: not RGB");
+        PL_ERR(p, "Invalid ICC profile: not RGB");
         goto error;
     }
 
@@ -352,11 +356,11 @@
         params->intent = cmsGetHeaderRenderingIntent(p->profile);
 
     struct pl_raw_primaries *out_prim = &icc->csp.hdr.prim;
-    if (!detect_csp(log, icc, out_prim, &icc->gamma))
+    if (!detect_csp(icc, out_prim, &icc->gamma))
         goto error;
     if (!detect_contrast(icc, &icc->csp.hdr, params->max_luma))
         goto error;
-    infer_clut_size(log, icc);
+    infer_clut_size(icc);
 
     const struct pl_raw_primaries *best = NULL;
     for (enum pl_color_primaries prim = 1; prim < PL_COLOR_PRIM_COUNT; prim++) 
{
@@ -377,7 +381,7 @@
     }
 
     if (!best) {
-        pl_warn(log, "ICC profile too wide to handle, colors may be clipped!");
+        PL_WARN(p, "ICC profile too wide to handle, colors may be clipped!");
         icc->containing_primaries = PL_COLOR_PRIM_ACES_AP0;
         best = pl_raw_primaries_get(icc->containing_primaries);
     }
@@ -446,14 +450,13 @@
 {
     pl_icc_object icc = params->priv;
     struct icc_priv *p = PL_PRIV(icc);
-    pl_log log = cmsGetContextUserData(p->cms);
     cmsHPROFILE srcp = decode ? p->profile : p->approx;
     cmsHPROFILE dstp = decode ? p->approx  : p->profile;
 
     int s_r = params->width, s_g = params->height, s_b = params->depth;
     size_t data_size = s_r * s_g * s_b * sizeof(uint16_t[4]);
     if (cache_load(icc, params->signature, datap, data_size)) {
-        pl_info(log, "Using cached 3DLUT (0x%"PRIX64")", params->signature);
+        PL_INFO(p, "Using cached 3DLUT (0x%"PRIX64")", params->signature);
         return;
     }
 
@@ -467,7 +470,7 @@
         return;
 
     clock_t after_transform = clock();
-    pl_log_cpu_time(log, start, after_transform, "creating ICC transform");
+    pl_log_cpu_time(p->log, start, after_transform, "creating ICC transform");
 
     uint16_t *tmp = pl_alloc(NULL, s_r * 3 * sizeof(tmp[0]));
     for (int b = 0; b < s_b; b++) {
@@ -502,7 +505,7 @@
         }
     }
 
-    pl_log_cpu_time(log, after_transform, clock(), "generating ICC 3DLUT");
+    pl_log_cpu_time(p->log, after_transform, clock(), "generating ICC 3DLUT");
     cmsDeleteTransform(tf);
     pl_free(tmp);
 
@@ -602,15 +605,12 @@
     sh_describe(sh, "ICC 3DLUT");
     GLSL("// pl_icc_encode                      \n"
          "{                                     \n"
-         "if (any(greaterThan(color.rgb, vec3(%s)))) \n"
-         "    color.rgb = vec3(1,0,0); \n"
          "color.rgb = max(color.rgb, 0.0);      \n"
          "color.rgb = 1.0/%s * color.rgb;       \n"
          "color.rgb = pow(color.rgb, vec3(%s)); \n"
          "color.rgb = 1.0/%s * color.rgb - %s;  \n"
          "color.rgb = %s(color.rgb).rgb;        \n"
          "}                                     \n",
-         SH_FLOAT(icc->csp.hdr.min_luma + 1e4),
          SH_FLOAT(p->scale),
          SH_FLOAT(1.0f / icc->gamma),
          SH_FLOAT(p->a), SH_FLOAT(p->b / p->a),
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/libplacebo-v5.264.0/src/shaders.c 
new/libplacebo-v5.264.1/src/shaders.c
--- old/libplacebo-v5.264.0/src/shaders.c       2023-03-13 13:07:23.000000000 
+0100
+++ new/libplacebo-v5.264.1/src/shaders.c       2023-03-23 15:53:00.000000000 
+0100
@@ -72,6 +72,7 @@
 
         // Preserve array allocations
         .tmp.elem       = sh->tmp.elem,
+        .obj.elem       = sh->obj.elem,
         .vas.elem       = sh->vas.elem,
         .vars.elem      = sh->vars.elem,
         .descs.elem     = sh->descs.elem,
@@ -247,8 +248,6 @@
     switch (sd.desc.type) {
     case PL_DESC_BUF_UNIFORM:
     case PL_DESC_BUF_STORAGE:
-    case PL_DESC_BUF_TEXEL_UNIFORM:
-    case PL_DESC_BUF_TEXEL_STORAGE:
         // Skip re-attaching the same buffer desc twice
         // FIXME: define aliases if the variable names differ
         for (int i = 0; i < sh->descs.num; i++) {
@@ -263,6 +262,8 @@
         sd.buffer_vars = pl_memdup(SH_TMP(sh), sd.buffer_vars, bsize);
         break;
 
+    case PL_DESC_BUF_TEXEL_UNIFORM:
+    case PL_DESC_BUF_TEXEL_STORAGE:
     case PL_DESC_SAMPLED_TEX:
     case PL_DESC_STORAGE_IMG:
         pl_assert(!sd.num_buffer_vars);
@@ -579,6 +580,11 @@
     pl_str_builder_concat(sh->buffers[SH_BUF_HEADER], 
sub->buffers[SH_BUF_BODY]);
     GLSLH("%s\n}\n\n", retvals[sub->res.output]);
 
+    // Ref all objects
+    PL_ARRAY_CONCAT(sh, sh->obj, sub->obj);
+    for (int i = 0; i < sub->obj.num; i++)
+        pl_rc_ref(&sub->obj.elem[i]->rc);
+
     // Copy over all of the descriptors etc.
     for (int i = 0; i < sub->tmp.num; i++)
         PL_ARRAY_APPEND(sh, sh->tmp, pl_ref_dup(sub->tmp.elem[i]));
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/libplacebo-v5.264.0/src/vulkan/context.c 
new/libplacebo-v5.264.1/src/vulkan/context.c
--- old/libplacebo-v5.264.0/src/vulkan/context.c        2023-03-13 
13:07:23.000000000 +0100
+++ new/libplacebo-v5.264.1/src/vulkan/context.c        2023-03-23 
15:53:00.000000000 +0100
@@ -447,10 +447,6 @@
     case 0x6cfe18a5: // UNASSIGNED-BestPractices-SemaphoreCount
         return false;
 
-    // Work-around for validation layers bug
-    case 0xc05b3a9d: // VUID-vkMapMemory-memory-00683
-        return false;
-
     case 0x5f379b89: // UNASSIGNED-BestPractices-Error-Result
         if (strstr(data->pMessage, "VK_ERROR_FORMAT_NOT_SUPPORTED"))
             return false;

Reply via email to