aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/glsl/glcpp/glcpp-parse.y
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2013-06-18 08:28:35 +0200
committermarha <marha@users.sourceforge.net>2013-06-18 08:28:35 +0200
commit230fe896faed312ef22d915e871fb5aee3ecfad0 (patch)
tree971b0c0899c72496f97970319bfadfae383abbea /mesalib/src/glsl/glcpp/glcpp-parse.y
parent180290f941da61bd80284d817e27c01cf789ee53 (diff)
parentb071050b9eda9d5e5185e582dbe9f4adba863ccc (diff)
downloadvcxsrv-230fe896faed312ef22d915e871fb5aee3ecfad0.tar.gz
vcxsrv-230fe896faed312ef22d915e871fb5aee3ecfad0.tar.bz2
vcxsrv-230fe896faed312ef22d915e871fb5aee3ecfad0.zip
Merge remote-tracking branch 'origin/released'
* origin/released: libX11 libXmu libxcb/xcb-proto mesa mkfontscale pixman xkeyboard-config git update 18 June 2013
Diffstat (limited to 'mesalib/src/glsl/glcpp/glcpp-parse.y')
-rw-r--r--mesalib/src/glsl/glcpp/glcpp-parse.y20
1 files changed, 13 insertions, 7 deletions
diff --git a/mesalib/src/glsl/glcpp/glcpp-parse.y b/mesalib/src/glsl/glcpp/glcpp-parse.y
index 81ba04bcc..ff5bdfe5d 100644
--- a/mesalib/src/glsl/glcpp/glcpp-parse.y
+++ b/mesalib/src/glsl/glcpp/glcpp-parse.y
@@ -1184,14 +1184,14 @@ glcpp_parser_create (const struct gl_extensions *extensions, int api)
parser->is_gles = false;
/* Add pre-defined macros. */
- if (extensions != NULL) {
- if (extensions->OES_EGL_image_external)
- add_builtin_define(parser, "GL_OES_EGL_image_external", 1);
- }
-
if (api == API_OPENGLES2) {
- parser->is_gles = true;
- add_builtin_define(parser, "GL_ES", 1);
+ parser->is_gles = true;
+ add_builtin_define(parser, "GL_ES", 1);
+
+ if (extensions != NULL) {
+ if (extensions->OES_EGL_image_external)
+ add_builtin_define(parser, "GL_OES_EGL_image_external", 1);
+ }
} else {
add_builtin_define(parser, "GL_ARB_draw_buffers", 1);
add_builtin_define(parser, "GL_ARB_texture_rectangle", 1);
@@ -1242,6 +1242,9 @@ glcpp_parser_create (const struct gl_extensions *extensions, int api)
if (extensions->AMD_vertex_shader_layer)
add_builtin_define(parser, "GL_AMD_vertex_shader_layer", 1);
+
+ if (extensions->ARB_shading_language_420pack)
+ add_builtin_define(parser, "GL_ARB_shading_language_420pack", 1);
}
}
@@ -2064,6 +2067,9 @@ _glcpp_parser_handle_version_declaration(glcpp_parser_t *parser, intmax_t versio
add_builtin_define (parser, "GL_ES", 1);
}
+ if (version >= 150)
+ add_builtin_define(parser, "GL_core_profile", 1);
+
/* Currently, all ES2/ES3 implementations support highp in the
* fragment shader, so we always define this macro in ES2/ES3.
* If we ever get a driver that doesn't support highp, we'll