diff options
Diffstat (limited to 'src/glsl/shader_enums.h')
-rw-r--r-- | src/glsl/shader_enums.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/glsl/shader_enums.h b/src/glsl/shader_enums.h index 7f59fdc..79e0f6b 100644 --- a/src/glsl/shader_enums.h +++ b/src/glsl/shader_enums.h @@ -27,6 +27,23 @@ #define SHADER_ENUMS_H /** + * Shader stages. Note that these will become 5 with tessellation. + * + * The order must match how shaders are ordered in the pipeline. + * The GLSL linker assumes that if i<j, then the j-th shader is + * executed later than the i-th shader. + */ +typedef enum +{ + MESA_SHADER_VERTEX = 0, + MESA_SHADER_GEOMETRY = 1, + MESA_SHADER_FRAGMENT = 2, + MESA_SHADER_COMPUTE = 3, +} gl_shader_stage; + +#define MESA_SHADER_STAGES (MESA_SHADER_COMPUTE + 1) + +/** * Bitflags for system values. */ #define SYSTEM_BIT_SAMPLE_ID ((uint64_t)1 << SYSTEM_VALUE_SAMPLE_ID) |