Panda3D
|
A single layer in the DXF file to be written by EggToDXF. More...
#include "eggToDXFLayer.h"
Public Member Functions | |
EggToDXFLayer (EggToDXF *egg2dxf, EggGroupNode *group) | |
EggToDXFLayer (const EggToDXFLayer ©) | |
void | add_color (const LColor &color) |
Records that one polygon is defined using the indicated color. More... | |
void | choose_overall_color () |
After all polygons have been accounted for, chooses the polygon color that occurred most often as the layer color. More... | |
void | operator= (const EggToDXFLayer ©) |
void | write_3d_face (EggPolygon *poly, ostream &out) |
Writes a polygon as a 3DFACE entity. More... | |
void | write_entities (ostream &out) |
Writes out the "entities", e.g. More... | |
void | write_layer (ostream &out) |
Writes the layer definition into the table at the beginning of the DXF file. More... | |
void | write_polyline (EggPolygon *poly, ostream &out) |
Writes a polygon as a POLYLINE entity. More... | |
A single layer in the DXF file to be written by EggToDXF.
Definition at line 32 of file eggToDXFLayer.h.
void EggToDXFLayer::add_color | ( | const LColor & | color | ) |
Records that one polygon is defined using the indicated color.
This will get accumulated; the color used by the majority of polygons will become the layer color.
Definition at line 72 of file eggToDXFLayer.cxx.
References choose_overall_color().
void EggToDXFLayer::choose_overall_color | ( | ) |
After all polygons have been accounted for, chooses the polygon color that occurred most often as the layer color.
Definition at line 95 of file eggToDXFLayer.cxx.
References write_layer().
Referenced by add_color().
void EggToDXFLayer::write_3d_face | ( | EggPolygon * | poly, |
ostream & | out | ||
) |
Writes a polygon as a 3DFACE entity.
Definition at line 159 of file eggToDXFLayer.cxx.
References EggVertex::get_pos3(), TypedObject::is_of_type(), EggPolygon::triangulate_into(), and write_entities().
Referenced by write_polyline().
void EggToDXFLayer::write_entities | ( | ostream & | out | ) |
Writes out the "entities", e.g.
polygons, defined for the current layer.
Definition at line 207 of file eggToDXFLayer.cxx.
References DXFFile::find_color(), and TypedObject::is_of_type().
Referenced by write_3d_face().
void EggToDXFLayer::write_layer | ( | ostream & | out | ) |
Writes the layer definition into the table at the beginning of the DXF file.
This does not write the actual geometry; that gets done later by write_entities().
Definition at line 118 of file eggToDXFLayer.cxx.
References write_polyline().
Referenced by choose_overall_color().
void EggToDXFLayer::write_polyline | ( | EggPolygon * | poly, |
ostream & | out | ||
) |
Writes a polygon as a POLYLINE entity.
Definition at line 132 of file eggToDXFLayer.cxx.
References EggAttributes::get_color(), EggVertex::get_pos3(), and write_3d_face().
Referenced by write_layer().