glsl: parse component layout qualifier

Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Edward O'Callaghan <eocallaghan@alterapraxis.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
This commit is contained in:
Timothy Arceri
2015-11-10 12:47:46 +11:00
parent ea4c1afd05
commit daa8df590b
3 changed files with 28 additions and 0 deletions

View File

@@ -502,6 +502,12 @@ struct ast_type_qualifier {
*/
unsigned explicit_index:1;
/**
* Flag set if GL_ARB_enhanced_layouts "component" layout
* qualifier is used.
*/
unsigned explicit_component:1;
/**
* Flag set if GL_ARB_shading_language_420pack "binding" layout
* qualifier is used.
@@ -621,6 +627,14 @@ struct ast_type_qualifier {
*/
ast_expression *index;
/**
* Component specified via GL_ARB_enhaced_layouts
*
* \note
* This field is only valid if \c explicit_component is set.
*/
ast_expression *component;
/** Maximum output vertices in GLSL 1.50 geometry shaders. */
ast_layout_expression *max_vertices;