summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Forbes <chrisf@ijw.co.nz>2014-04-12 19:44:46 +1200
committerKenneth Graunke <kenneth@whitecape.org>2014-04-18 10:35:05 -0700
commit92840aabf7a96583619a01a8257ef6f117f0ca50 (patch)
tree92bd198ebcf410d7a6d40d4a45493fc1865ade66
parent7489f3eedafbdad905158196873c8b3f5ccb546f (diff)
downloadexternal_mesa3d-92840aabf7a96583619a01a8257ef6f117f0ca50.zip
external_mesa3d-92840aabf7a96583619a01a8257ef6f117f0ca50.tar.gz
external_mesa3d-92840aabf7a96583619a01a8257ef6f117f0ca50.tar.bz2
glsl: Allow explicit binding on atomics again
As of 943b2d52bf5, layout(binding) on an atomic would fail the assertion here. Signed-off-by: Chris Forbes <chrisf@ijw.co.nz> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
-rw-r--r--src/glsl/link_uniform_initializers.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/glsl/link_uniform_initializers.cpp b/src/glsl/link_uniform_initializers.cpp
index e60bb64..2100e05 100644
--- a/src/glsl/link_uniform_initializers.cpp
+++ b/src/glsl/link_uniform_initializers.cpp
@@ -296,8 +296,10 @@ link_set_uniform_initializers(struct gl_shader_program *prog)
linker::set_block_binding(prog, iface_type->name,
var->data.binding);
}
+ } else if (type->contains_atomic()) {
+ /* we don't actually need to do anything. */
} else {
- assert(!"Explicit binding not on a sampler or UBO.");
+ assert(!"Explicit binding not on a sampler, UBO or atomic.");
}
} else if (var->constant_value) {
linker::set_uniform_initializer(mem_ctx, prog, var->name,