aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/glsl/glsl_parser.yy
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2012-08-13 10:11:17 +0200
committermarha <marha@users.sourceforge.net>2012-08-13 10:11:17 +0200
commitf5a4fa87e844b3ea2658a2355a4c4ac3393a65a1 (patch)
tree921a5a742930124e7bd7e9a7e73f6029bd74338d /mesalib/src/glsl/glsl_parser.yy
parentec4051f308e8e84146e0ecc39b6d228e500e9636 (diff)
parent9ddf44af81782451cee798e06749ce3067a14a41 (diff)
downloadvcxsrv-f5a4fa87e844b3ea2658a2355a4c4ac3393a65a1.tar.gz
vcxsrv-f5a4fa87e844b3ea2658a2355a4c4ac3393a65a1.tar.bz2
vcxsrv-f5a4fa87e844b3ea2658a2355a4c4ac3393a65a1.zip
Merge remote-tracking branch 'origin/released'
Diffstat (limited to 'mesalib/src/glsl/glsl_parser.yy')
-rw-r--r--mesalib/src/glsl/glsl_parser.yy20
1 files changed, 20 insertions, 0 deletions
diff --git a/mesalib/src/glsl/glsl_parser.yy b/mesalib/src/glsl/glsl_parser.yy
index 04c64f096..ee6a67288 100644
--- a/mesalib/src/glsl/glsl_parser.yy
+++ b/mesalib/src/glsl/glsl_parser.yy
@@ -1929,6 +1929,16 @@ uniform_block:
void *ctx = state;
$$ = new(ctx) ast_uniform_block(*state->default_uniform_qualifier,
$2, $4);
+
+ if (!state->ARB_uniform_buffer_object_enable) {
+ _mesa_glsl_error(& @1, state,
+ "#version 140 / GL_ARB_uniform_buffer_object "
+ "required for defining uniform blocks\n");
+ } else if (state->ARB_uniform_buffer_object_warn) {
+ _mesa_glsl_warning(& @1, state,
+ "#version 140 / GL_ARB_uniform_buffer_object "
+ "required for defining uniform blocks\n");
+ }
}
| layout_qualifier UNIFORM NEW_IDENTIFIER '{' member_list '}' ';'
{
@@ -1939,6 +1949,16 @@ uniform_block:
YYERROR;
}
$$ = new(ctx) ast_uniform_block(qual, $3, $5);
+
+ if (!state->ARB_uniform_buffer_object_enable) {
+ _mesa_glsl_error(& @1, state,
+ "#version 140 / GL_ARB_uniform_buffer_object "
+ "required for defining uniform blocks\n");
+ } else if (state->ARB_uniform_buffer_object_warn) {
+ _mesa_glsl_warning(& @1, state,
+ "#version 140 / GL_ARB_uniform_buffer_object "
+ "required for defining uniform blocks\n");
+ }
}
;