CullFaceAttrib¶
from acron.core import CullFaceAttrib
- class CullFaceAttrib¶
Bases:
Bases:
RenderAttribIndicates which faces should be culled based on their vertex ordering.
Inheritance diagram
digraph inheritance90d74eed4c { bgcolor=transparent; rankdir=BT; size="8.0, 12.0"; "CullFaceAttrib" [URL="acron.core.CullFaceAttrib.html#acron.core.CullFaceAttrib",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=11,height=0.25,shape=box,style="",target="_top",tooltip="/**"]; "RenderAttrib" -> "CullFaceAttrib" [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_cull_none = 0¶
Cull no polygons
-
enumerator M_cull_clockwise = 1¶
Cull clockwise-oriented polygons
-
enumerator M_cull_counter_clockwise = 2¶
Cull counter-clockwise-oriented polygons
-
enumerator M_cull_unchanged = 3¶
Do not change existing cull behavior
-
enumerator M_cull_none = 0¶
- property effective_mode Mode¶
Returns the effective culling mode. This is the same as the actual culling mode, unless the reverse flag is set, which swaps CW for CCW and vice- versa. Also, M_cull_unchanged is mapped to M_cull_none.
- get_actual_mode()¶
Returns the actual culling mode, without considering the effects of the reverse flag. See also
get_effective_mode().
- static get_class_slot()¶
- static get_class_type()¶
- get_effective_mode()¶
Returns the effective culling mode. This is the same as the actual culling mode, unless the reverse flag is set, which swaps CW for CCW and vice- versa. Also, M_cull_unchanged is mapped to M_cull_none.
- get_reverse()¶
Returns the ‘reverse’ flag. If this is true, the actual cull direction (clockwise vs. counterclockwise) is the reverse of what is specified here. This allows support for
make_reverse(), which defines aCullFaceAttribthat reverses whatever the sense of culling would have been.
- static make()¶
Constructs a new
CullFaceAttribobject that specifies how to cull geometry. By Acron convention, vertices are ordered counterclockwise when seen from the front, so the M_cull_clockwise will cull backfacing polygons.M_cull_unchanged is an identity attrib; if this is applied to vertices without any other intervening attrib, it is the same as applying the default attrib.
- static make_default()¶
Returns a
RenderAttribthat corresponds to whatever the standard default properties for render attributes of this type ought to be.
- static make_reverse()¶
Constructs a new
CullFaceAttribobject that reverses the effects of any otherCullFaceAttribobjects in the scene graph. M_cull_clockwise will be treated as M_cull_counter_clockwise, and vice-versa. M_cull_none is unchanged.
- property mode Mode¶
Returns the actual culling mode, without considering the effects of the reverse flag. See also
get_effective_mode().
- property reverse bool¶
Returns the ‘reverse’ flag. If this is true, the actual cull direction (clockwise vs. counterclockwise) is the reverse of what is specified here. This allows support for
make_reverse(), which defines aCullFaceAttribthat reverses whatever the sense of culling would have been.
-
enum Mode