EggAttributes

class EggAttributes

Bases: MemoryBase

The set of attributes that may be applied to vertices as well as polygons, such as surface normal and color.

This class cannot inherit from EggObject, because it causes problems at the EggPolygon level with multiple appearances of the EggObject base class. And making EggObject a virtual base class is just no fun.

Inheritance diagram

digraph inheritance1bff8791cb { bgcolor=transparent; rankdir=BT; size="8.0, 12.0"; "DTOOL_SUPER_BASE" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=11,height=0.25,shape=box,style=""]; "EggAttributes" [URL="acron.egg.EggAttributes.html#acron.egg.EggAttributes",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" -> "EggAttributes" [arrowsize=0.75,style=""]; }
EggAttributes.__init__()
EggAttributes.assign()
EggAttributes.clear_color()
EggAttributes.clear_normal()
EggAttributes.compare_to()

An ordering operator to compare two vertices for sorting order. This imposes an arbitrary ordering useful to identify unique vertices.

EggAttributes.copy_color()

Sets this color to be the same as the other’s, include morphs. If the other has no color, this clears the color.

EggAttributes.copy_normal()

Sets this normal to be the same as the other’s, include morphs. If the other has no normal, this clears the normal.

static EggAttributes.get_class_type()
EggAttributes.get_color()

Returns the color set on this particular attribute. If there is no color set, returns white.

EggAttributes.get_normal()
EggAttributes.has_color()
EggAttributes.has_normal()
EggAttributes.matches_color()

Returns true if this color matches that of the other EggAttributes object, include the morph list.

EggAttributes.matches_normal()

Returns true if this normal matches that of the other EggAttributes object, include the morph list.

EggAttributes.set_color()
EggAttributes.set_normal()
EggAttributes.sorts_less_than()

An ordering operator to compare two vertices for sorting order. This imposes an arbitrary ordering useful to identify unique vertices.

EggAttributes.transform()

Applies the indicated transformation matrix to the attributes.

EggAttributes.write()

Writes the attributes to the indicated output stream in Egg format.