Panda3D
|
00001 // Filename: dxfToEggLayer.h 00002 // Created by: drose (04May04) 00003 // 00004 //////////////////////////////////////////////////////////////////// 00005 // 00006 // PANDA 3D SOFTWARE 00007 // Copyright (c) Carnegie Mellon University. All rights reserved. 00008 // 00009 // All use of this software is subject to the terms of the revised BSD 00010 // license. You should have received a copy of this license along 00011 // with this source code in a file named "LICENSE." 00012 // 00013 //////////////////////////////////////////////////////////////////// 00014 00015 #ifndef DXFTOEGGLAYER_H 00016 #define DXFTOEGGLAYER_H 00017 00018 #include "pandatoolbase.h" 00019 00020 #include "dxfLayer.h" 00021 #include "eggVertexPool.h" 00022 #include "eggGroup.h" 00023 #include "pointerTo.h" 00024 00025 class EggGroupNode; 00026 class EggVertex; 00027 class DXFVertex; 00028 class DXFToEggConverter; 00029 00030 //////////////////////////////////////////////////////////////////// 00031 // Class : DXFToEggLayer 00032 // Description : The specialization of DXFLayer used by 00033 // DXFToEggConverter. It contains a pointer to an 00034 // EggGroup and a vertex pool; these are used to build 00035 // up polygons grouped by layer in the egg file as each 00036 // polygon is read from the DXF file. 00037 //////////////////////////////////////////////////////////////////// 00038 class DXFToEggLayer : public DXFLayer { 00039 public: 00040 DXFToEggLayer(const string &name, EggGroupNode *parent); 00041 00042 void add_polygon(const DXFToEggConverter *entity); 00043 void add_line(const DXFToEggConverter *entity); 00044 EggVertex *add_vertex(const DXFVertex &vertex); 00045 00046 PT(EggVertexPool) _vpool; 00047 PT(EggGroup) _group; 00048 }; 00049 00050 00051 #endif