mesa: fix glUniform* when a struct contains a bindless sampler
authorPierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Mon, 14 Sep 2020 19:08:29 +0000 (21:08 +0200)
committerMarge Bot <eric+marge@anholt.net>
Fri, 18 Sep 2020 07:52:06 +0000 (07:52 +0000)
commit090fc593b44d41e5613b04931bbf46d268fca666
treeffeab3436048991d4bee0cafbbad5ec7746d3af8
parent77af1ca690f4f49e305c095d97b9af798bfea307
mesa: fix glUniform* when a struct contains a bindless sampler

Small example from #3271:

layout (bindless_sampler) uniform;
struct SamplerSparse {
  sampler2D tex;
  vec4 size;
  [...]
};
uniform SamplerSparse foo;

'foo' will be marked as bindless but we should only take the assign-as-GLuint64 path for 'tex'.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/3271
Fixes: 990c8d15ac3 ("mesa: fix setting uniform variables for bindless samplers/images")
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6730>
src/mesa/main/uniform_query.cpp