class LogicOpAttrib

Bases: RenderAttrib

If enabled, specifies that a custom logical operation be performed instead of any color blending. Setting it to a value other than M_none will cause color blending to be disabled and the given logic operation to be performed.

New in version 1.10.0.

Inheritance diagram

Inheritance diagram of LogicOpAttrib

enum Operation
enumerator O_none = 0

LogicOp disabled, regular blending occurs.

enumerator O_clear = 1

Clears framebuffer value.

enumerator O_and = 2
enumerator O_and_reverse = 3
enumerator O_copy = 4

Writes the incoming color to the framebuffer.

enumerator O_and_inverted = 5
enumerator O_noop = 6

Leaves the framebuffer value unaltered.

enumerator O_xor = 7
enumerator O_or = 8
enumerator O_nor = 9
enumerator O_equivalent = 10
enumerator O_invert = 11
enumerator O_or_reverse = 12
enumerator O_copy_inverted = 13
enumerator O_or_inverted = 14
enumerator O_nand = 15
enumerator O_set = 16

Sets all the bits in the framebuffer to 1.

static int get_class_slot(void)
static TypeHandle get_class_type(void)
Operation get_operation(void) const

Returns the logic operation specified by this attribute.

static ConstPointerTo<RenderAttrib> make(LogicOpAttrib::Operation op)

Constructs a new LogicOpAttrib object with the given logic operation.

static ConstPointerTo<RenderAttrib> make_default(void)

Returns a RenderAttrib that corresponds to whatever the standard default properties for render attributes of this type ought to be.

static ConstPointerTo<RenderAttrib> make_off(void)

Constructs a new LogicOpAttrib object that disables special-effect blending, allowing normal transparency to be used instead.