# EggAttributes

from pandac.PandaModules import EggAttributes

Class : EggAttributes
Description : 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:

EggAttributes:

## Methods of EggAttributes:

EggAttributes (Constructor)
clearColor
clearNormal
compareTo
copyColor
copyNormal
getClassType
getColor
getNormal
hasColor
hasNormal
matchesColor
matchesNormal
operator =
setColor
setNormal
sortsLessThan
transform
write

EggAttributes EggAttributes::EggAttributes(void); Description:

clearColor void EggAttributes::clear_color(void); Description:

clearNormal void EggAttributes::clear_normal(void); Description:

compareTo int EggAttributes::compare_to(EggAttributes const &other) const; Description: An ordering operator to compare two vertices for sorting order. This imposes an arbitrary ordering useful to identify unique vertices.

copyColor void EggAttributes::copy_color(EggAttributes const &other); Description: Sets this color to be the same as the other's, include morphs. If the other has no color, this clears the color.

copyNormal void EggAttributes::copy_normal(EggAttributes const &other); Description: Sets this normal to be the same as the other's, include morphs. If the other has no normal, this clears the normal.

getClassType static TypeHandle EggAttributes::get_class_type(void); Undocumented function.

getColor LVecBase4f EggAttributes::get_color(void) const; Description: Returns the color set on this particular attribute. If there is no color set, returns white.

getNormal LVector3d const &EggAttributes::get_normal(void) const; Description:

hasColor bool EggAttributes::has_color(void) const; Description:

hasNormal bool EggAttributes::has_normal(void) const; Description:

matchesColor bool EggAttributes::matches_color(EggAttributes const &other) const; Description: Returns true if this color matches that of the other EggAttributes object, include the morph list.

matchesNormal bool EggAttributes::matches_normal(EggAttributes const &other) const; Description: Returns true if this normal matches that of the other EggAttributes object, include the morph list.

operator = EggAttributes &EggAttributes::operator =(EggAttributes const &copy); Description:

setColor void EggAttributes::set_color(LVecBase4f const &Color); Description:

setNormal void EggAttributes::set_normal(LVector3d const &normal); Description:

sortsLessThan bool EggAttributes::sorts_less_than(EggAttributes const &other) const; Description: An ordering operator to compare two vertices for sorting order. This imposes an arbitrary ordering useful to identify unique vertices.

transform void EggAttributes::transform(LMatrix4d const &mat); Description: Applies the indicated transformation matrix to the attributes.

write void EggAttributes::write(ostream &out, int indent_level) const; Description: Writes the attributes to the indicated output stream in Egg format.