00001 #ifndef SIGEL_ROBOT_SIG_POLYGON 00002 #define SIGEL_ROBOT_SIG_POLYGON 00003 00004 namespace SIGEL_Robot { class SIG_Polygon; } 00005 00006 #include <pointvector.h> 00007 #include <matrix.h> 00008 #include <qtextstream.h> 00009 #include "SIGEL_Robot/SIG_Geometry.h" 00010 00011 namespace SIGEL_Robot { 00015 class SIG_Polygon { 00016 friend class SIG_Geometry; 00017 00018 private: 00019 SIG_Geometry *myGeometry; 00020 QArray<int> vertices; 00021 00022 protected: 00031 SIG_Polygon (SIG_Geometry *within, SIG_Polygon *other); 00032 00033 public: 00039 SIG_Polygon (SIG_Geometry *within); 00045 SIG_Polygon (SIG_Geometry *mygeom, QTextStream & tx); 00049 ~SIG_Polygon (void); 00050 00054 void appendVertex (DL_vector pt); 00058 int getNumVertices (void) const; 00062 DL_vector getVertex (int nr) const; 00069 int getVertexIndex (int nr) const; 00070 00074 void writeToFileTransfer (QTextStream & tx) const; 00075 }; 00076 } 00077 00078 #endif