ColorBlendAttrib¶
-
class ColorBlendAttrib¶
Bases:
RenderAttribThis specifies how colors are blended into the frame buffer, for special effects. This overrides transparency if transparency is also specified.
Inheritance diagram
digraph inheritance13fae001db { bgcolor=transparent; rankdir=BT; size="8.0, 12.0"; "ColorBlendAttrib" [URL="acron.core.ColorBlendAttrib.html#acron.core.ColorBlendAttrib",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=11,height=0.25,shape=box,style="",target="_top",tooltip="/**"]; "RenderAttrib" -> "ColorBlendAttrib" [arrowsize=0.75,style=""]; "DTOOL_SUPER_BASE" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=11,height=0.25,shape=box,style=""]; "ReferenceCount" [URL="acron.core.ReferenceCount.html#acron.core.ReferenceCount",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=11,height=0.25,shape=box,style="",target="_top",tooltip="/**"]; "DTOOL_SUPER_BASE" -> "ReferenceCount" [arrowsize=0.75,style=""]; "RenderAttrib" [URL="acron.core.RenderAttrib.html#acron.core.RenderAttrib",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=11,height=0.25,shape=box,style="",target="_top",tooltip="/**"]; "TypedWritableReferenceCount" -> "RenderAttrib" [arrowsize=0.75,style=""]; "TypedObject" [URL="acron.core.TypedObject.html#acron.core.TypedObject",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=11,height=0.25,shape=box,style="",target="_top",tooltip="/**"]; "DTOOL_SUPER_BASE" -> "TypedObject" [arrowsize=0.75,style=""]; "TypedWritable" [URL="acron.core.TypedWritable.html#acron.core.TypedWritable",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=11,height=0.25,shape=box,style="",target="_top",tooltip="/**"]; "TypedObject" -> "TypedWritable" [arrowsize=0.75,style=""]; "TypedWritableReferenceCount" [URL="acron.core.TypedWritableReferenceCount.html#acron.core.TypedWritableReferenceCount",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=11,height=0.25,shape=box,style="",target="_top",tooltip="/**"]; "TypedWritable" -> "TypedWritableReferenceCount" [arrowsize=0.75,style=""]; "ReferenceCount" -> "TypedWritableReferenceCount" [arrowsize=0.75,style=""]; }-
enum Mode¶
-
enumerator M_none = 0¶
Blending is disabled
-
enumerator M_add = 1¶
incoming color * A + fbuffer color * B
-
enumerator M_subtract = 2¶
incoming color * A - fbuffer color * B
-
enumerator M_inv_subtract = 3¶
fbuffer color * B - incoming color * A
-
enumerator M_min = 4¶
min(incoming color, fbuffer color)
-
enumerator M_max = 5¶
max(incoming color, fbuffer color)
-
enumerator M_none = 0¶
-
enum Operand¶
-
enumerator O_zero = 0¶
-
enumerator O_one = 1¶
-
enumerator O_incoming_color = 2¶
-
enumerator O_one_minus_incoming_color = 3¶
-
enumerator O_fbuffer_color = 4¶
-
enumerator O_one_minus_fbuffer_color = 5¶
-
enumerator O_incoming_alpha = 6¶
-
enumerator O_one_minus_incoming_alpha = 7¶
-
enumerator O_fbuffer_alpha = 8¶
-
enumerator O_one_minus_fbuffer_alpha = 9¶
-
enumerator O_constant_color = 10¶
-
enumerator O_one_minus_constant_color = 11¶
-
enumerator O_constant_alpha = 12¶
-
enumerator O_one_minus_constant_alpha = 13¶
-
enumerator O_incoming_color_saturate = 14¶
valid only for operand a
-
enumerator O_incoming1_color = 15¶
The following are used for dual-source blending, where the fragment shader outputs a second color that will be used for blending.
-
enumerator O_one_minus_incoming1_color = 16¶
-
enumerator O_incoming1_alpha = 17¶
-
enumerator O_one_minus_incoming1_alpha = 18¶
-
enumerator O_color_scale = 19¶
These modes are being considered for deprecation.
-
enumerator O_one_minus_color_scale = 20¶
-
enumerator O_alpha_scale = 21¶
-
enumerator O_one_minus_alpha_scale = 22¶
-
enumerator O_zero = 0¶
- ColorBlendAttrib.get_alpha_mode()¶
Returns the blending mode for the alpha channel.
- ColorBlendAttrib.get_alpha_operand_a()¶
Returns the alpha multiplier for the first component.
- ColorBlendAttrib.get_alpha_operand_b()¶
Returns the alpha multiplier for the second component.
- static ColorBlendAttrib.get_class_slot()¶
- static ColorBlendAttrib.get_class_type()¶
- ColorBlendAttrib.get_color()¶
Returns the constant color associated with the attrib.
- ColorBlendAttrib.get_mode()¶
Returns the blending mode for the RGB channels.
- ColorBlendAttrib.get_operand_a()¶
Returns the RGB multiplier for the first component.
- ColorBlendAttrib.get_operand_b()¶
Returns the RGB multiplier for the second component.
- ColorBlendAttrib.involves_color_scale()¶
Returns true if the this attrib uses the color scale attrib, false otherwise.
Returns true if the indicated operand uses the color scale attrib, false otherwise.
- ColorBlendAttrib.involves_constant_color()¶
Returns true if the this attrib uses the constant color, false otherwise.
Returns true if the indicated operand uses the constant color, false otherwise.
- static ColorBlendAttrib.make()¶
Constructs a new
ColorBlendAttribobject.Deprecated: Use the three- or four-parameter constructor instead.
Constructs a new
ColorBlendAttribobject that enables special-effect blending. This supercedes transparency. The given mode and operands are used for both the RGB and alpha channels.Constructs a new
ColorBlendAttribobject that enables special-effect blending. This supercedes transparency. This form is used to specify separate blending parameters for the RGB and alpha channels.
- static ColorBlendAttrib.make_default()¶
Returns a
RenderAttribthat corresponds to whatever the standard default properties for render attributes of this type ought to be.
- static ColorBlendAttrib.make_off()¶
Constructs a new
ColorBlendAttribobject that disables special-effect blending, allowing normal transparency to be used instead.
-
enum Mode¶