aboutsummaryrefslogtreecommitdiffstats
path: root/src/compiler
diff options
context:
space:
mode:
authorAlyssa Rosenzweig <[email protected]>2019-05-06 01:58:56 +0000
committerAlyssa Rosenzweig <[email protected]>2019-05-10 15:49:01 +0000
commitf41be53a1706181be85a8ba41681e28b4780f6e1 (patch)
tree83200e687adfd499067b3794e3389a47d02112b8 /src/compiler
parentd0bff89159bead4ba850182e5a30d0745510f773 (diff)
compiler: Add enums for blend state
We add enums corresponding to (GLES) blend state to shader_enums.h, complementing the existing advanced blending enums in the file. This allows us to represent blending state in a driver-agnostic, API-agnostic way to permit lowering. Signed-off-by: Alyssa Rosenzweig <[email protected]> Reviewed-by: Ian Romanick <[email protected]> Acked-by: Eric Anholt <[email protected]>
Diffstat (limited to 'src/compiler')
-rw-r--r--src/compiler/shader_enums.h21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/compiler/shader_enums.h b/src/compiler/shader_enums.h
index ac293af4519..47b1ca01dd6 100644
--- a/src/compiler/shader_enums.h
+++ b/src/compiler/shader_enums.h
@@ -753,6 +753,27 @@ enum gl_advanced_blend_mode
BLEND_ALL = 0x7fff,
};
+enum blend_func
+{
+ BLEND_FUNC_ADD,
+ BLEND_FUNC_SUBTRACT,
+ BLEND_FUNC_REVERSE_SUBTRACT,
+ BLEND_FUNC_MIN,
+ BLEND_FUNC_MAX,
+};
+
+enum blend_factor
+{
+ BLEND_FACTOR_ZERO,
+ BLEND_FACTOR_SRC_COLOR,
+ BLEND_FACTOR_DST_COLOR,
+ BLEND_FACTOR_SRC_ALPHA,
+ BLEND_FACTOR_DST_ALPHA,
+ BLEND_FACTOR_CONSTANT_COLOR,
+ BLEND_FACTOR_CONSTANT_ALPHA,
+ BLEND_FACTOR_SRC_ALPHA_SATURATE,
+};
+
enum gl_tess_spacing
{
TESS_SPACING_UNSPECIFIED,