diff options
author | Marek Olšák <[email protected]> | 2011-05-02 16:41:04 +0200 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2011-05-03 12:03:22 +0200 |
commit | 5ba2e7adf01aaa855e36a577a47de8f4ddace99c (patch) | |
tree | 74c3fe13b5fff0ff02d00911ce5f28b5e12591a3 /src/glsl/glsl_parser_extras.cpp | |
parent | 93754d8499934a4c38e9a934d0a934c1484b707c (diff) |
mesa: implement AMD_shader_stencil_export
It's just an alias of the ARB variant with some GLSL compiler changes.
Reviewed-by: Brian Paul <[email protected]>
Reviewed-by: Ian Romanick <[email protected]>
Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/glsl/glsl_parser_extras.cpp')
-rw-r--r-- | src/glsl/glsl_parser_extras.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/glsl/glsl_parser_extras.cpp b/src/glsl/glsl_parser_extras.cpp index 5bb3a6f25a3..18bff88deec 100644 --- a/src/glsl/glsl_parser_extras.cpp +++ b/src/glsl/glsl_parser_extras.cpp @@ -255,6 +255,16 @@ _mesa_glsl_process_extension(const char *name, YYLTYPE *name_locp, state->AMD_conservative_depth_enable = (ext_mode != extension_disable); state->AMD_conservative_depth_warn = (ext_mode == extension_warn); unsupported = !state->extensions->AMD_conservative_depth; + } else if (strcmp(name, "GL_AMD_shader_stencil_export") == 0) { + state->AMD_shader_stencil_export_enable = (ext_mode != extension_disable); + state->AMD_shader_stencil_export_warn = (ext_mode == extension_warn); + + /* This extension is only supported in fragment shaders. + * Both the ARB and AMD variants share the same ARB flag + * in gl_extensions. + */ + unsupported = (state->target != fragment_shader) + || !state->extensions->ARB_shader_stencil_export; } else if (strcmp(name, "GL_OES_texture_3D") == 0 && state->es_shader) { state->OES_texture_3D_enable = (ext_mode != extension_disable); state->OES_texture_3D_warn = (ext_mode == extension_warn); |