summaryrefslogtreecommitdiff
path: root/ir.cpp
diff options
context:
space:
mode:
authorKenneth Graunke <kenneth@whitecape.org>2010-06-09 14:42:41 -0700
committerKenneth Graunke <kenneth@whitecape.org>2010-06-09 14:44:39 -0700
commitb843c7a20c2d65494f30eb82622ae7db380f581a (patch)
treed39710afa28855bbd8a7684b22e97c9fc0177600 /ir.cpp
parentcbd881da3fd2a68272988cf7fd21dfe006d47c8c (diff)
Implement dFdx, dFdy, and fwidth via new expression opcodes.
Diffstat (limited to 'ir.cpp')
-rw-r--r--ir.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/ir.cpp b/ir.cpp
index ca34c24719..c5eb94d2d5 100644
--- a/ir.cpp
+++ b/ir.cpp
@@ -76,6 +76,9 @@ ir_expression::get_num_operands(ir_expression_operation op)
1, /* ir_unop_sin */
1, /* ir_unop_cos */
+ 1, /* ir_unop_dFdx */
+ 1, /* ir_unop_dFdy */
+
2, /* ir_binop_add */
2, /* ir_binop_sub */
2, /* ir_binop_mul */
@@ -136,6 +139,8 @@ static const char *const operator_strs[] = {
"floor",
"sin",
"cos",
+ "dFdx",
+ "dFdy",
"+",
"-",
"*",