[Mesa-dev] [PATCH] glsl: set shader inputs as read only
Timothy Arceri
t_arceri at yahoo.com.au
Tue Dec 23 22:22:56 PST 2014
Signed-off-by: Timothy Arceri <t_arceri at yahoo.com.au>
---
Note: This doesn't work for interface blocks, I'm still
trying to figure out whats missing for that to work.
Piglit test: http://lists.freedesktop.org/archives/piglit/2014-December/013857.html
No piglit regressions.
src/glsl/ast_to_hir.cpp | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/glsl/ast_to_hir.cpp b/src/glsl/ast_to_hir.cpp
index 6cf79bd..188cd01 100644
--- a/src/glsl/ast_to_hir.cpp
+++ b/src/glsl/ast_to_hir.cpp
@@ -2451,6 +2451,7 @@ apply_type_qualifier_to_variable(const struct ast_type_qualifier *qual,
if (qual->flags.q.constant || qual->flags.q.attribute
|| qual->flags.q.uniform
+ || (qual->flags.q.in && !is_parameter)
|| (qual->flags.q.varying
&& ((state->stage == MESA_SHADER_FRAGMENT)
|| (state->stage == MESA_SHADER_GEOMETRY))))
--
2.1.0
More information about the mesa-dev
mailing list