Browse Source

glsl: Add a virtual as_discard() method.

NOTE: This is candidate for the 7.9 branch.
tags/android-x86-2.2
Kenneth Graunke 14 years ago
parent
commit
1eb7a81f2e
1 changed files with 6 additions and 0 deletions
  1. 6
    0
      src/glsl/ir.h

+ 6
- 0
src/glsl/ir.h View File

@@ -122,6 +122,7 @@ public:
virtual class ir_if * as_if() { return NULL; }
virtual class ir_swizzle * as_swizzle() { return NULL; }
virtual class ir_constant * as_constant() { return NULL; }
virtual class ir_discard * as_discard() { return NULL; }
/*@}*/

protected:
@@ -1122,6 +1123,11 @@ public:

virtual ir_visitor_status accept(ir_hierarchical_visitor *);

virtual ir_discard *as_discard()
{
return this;
}

ir_rvalue *condition;
};
/*@}*/

Loading…
Cancel
Save