summaryrefslogtreecommitdiffstats
path: root/src/glsl/glsl_parser_extras.cpp
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2013-09-23 18:13:52 -0700
committerKenneth Graunke <[email protected]>2013-09-26 16:55:18 -0700
commite4af55c78f9d639653bb9290e0fc63c6658cdc4d (patch)
tree4703a3137ed166cc66a40012481ee3f86cc86b59 /src/glsl/glsl_parser_extras.cpp
parente9b410b54dd893568a50af661fdbba12b4573ed9 (diff)
glsl: Create and use a has_explicit_attrib_location() helper.
Explicit attribute locations are supported with GLSL 3.30, GLSL ES 3.00, or "#extension GL_ARB_explicit_attrib_location: enable". Using a helper function makes it easy to check for this. This enables support in GLSL 3.30, which was previously missing. Previously, we overrode the extension enable flag for ES 3.00. This is not robust against a shader such as: #version 330 #extension GL_ARB_explicit_attrib_location : disable Disabling extensions should not remove core language functionality. Signed-off-by: Kenneth Graunke <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
Diffstat (limited to 'src/glsl/glsl_parser_extras.cpp')
-rw-r--r--src/glsl/glsl_parser_extras.cpp4
1 files changed, 0 insertions, 4 deletions
diff --git a/src/glsl/glsl_parser_extras.cpp b/src/glsl/glsl_parser_extras.cpp
index cac5a18e474..a2b52ef004f 100644
--- a/src/glsl/glsl_parser_extras.cpp
+++ b/src/glsl/glsl_parser_extras.cpp
@@ -303,10 +303,6 @@ _mesa_glsl_parse_state::process_version_directive(YYLTYPE *locp, int version,
if (this->language_version >= 140) {
this->ARB_uniform_buffer_object_enable = true;
}
-
- if (this->language_version == 300 && this->es_shader) {
- this->ARB_explicit_attrib_location_enable = true;
- }
}
extern "C" {