summaryrefslogtreecommitdiff
path: root/src/glsl/ir.h
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2010-11-19 18:27:41 +0800
committerEric Anholt <eric@anholt.net>2010-11-19 19:09:18 -0800
commit02939d643f878ce3a3dcd2e7b2c6f035c64ecda7 (patch)
treef68a3826a9a8a3b68286303f48008200f2b49301 /src/glsl/ir.h
parent602ae2441aaca6a652d3fc78114bb60852132f98 (diff)
glsl: Add a helper function for determining if an rvalue could be a saturate.
Hardware pretty commonly has saturate modifiers on instructions, and this can be used in codegen to produce those, without everyone else needing to understand clamping other than min and max.
Diffstat (limited to 'src/glsl/ir.h')
-rw-r--r--src/glsl/ir.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/glsl/ir.h b/src/glsl/ir.h
index be0da07b3b..850033b185 100644
--- a/src/glsl/ir.h
+++ b/src/glsl/ir.h
@@ -144,6 +144,8 @@ public:
return this;
}
+ ir_rvalue *as_rvalue_to_saturate();
+
virtual bool is_lvalue()
{
return false;