00001
00002
00003
00004
00005 #ifndef BALL_STRUCTURE_RSFACE_H
00006 #define BALL_STRUCTURE_RSFACE_H
00007
00008 #ifndef BALL_STRUCTURE_GRAPHFACE_H
00009 # include <BALL/STRUCTURE/graphFace.h>
00010 #endif
00011
00012 #ifndef BALL_MATHS_VECTOR3_H
00013 # include <BALL/MATHS/vector3.h>
00014 #endif
00015
00016 namespace BALL
00017 {
00018 class RSVertex;
00019 class RSEdge;
00020 class ReducedSurface;
00021 class RSComputer;
00022 class SolventExcludedSurface;
00023 class SESComputer;
00024 class SESSingularityCleaner;
00025 class SESEdge;
00026 class SESFace;
00027 class SESVertex;
00028 class TriangulatedSES;
00029 class SASTriangulator;
00030 class SolventAccessibleSurface;
00031 class SASEdge;
00032 class SASFace;
00033 class SASVertex;
00034 class TriangulatedSAS;
00035 class SESTriangulator;
00036
00040 class BALL_EXPORT RSFace : public GraphTriangle< RSVertex,RSEdge,RSFace >
00041 {
00042 public:
00043
00066 friend class RSEdge;
00067 friend class RSVertex;
00068 friend class ReducedSurface;
00069 friend class RSComputer;
00070 friend class SESEdge;
00071 friend class SESFace;
00072 friend class SESVertex;
00073 friend class SolventExcludedSurface;
00074 friend class SESComputer;
00075 friend class SESSingularityCleaner;
00076 friend class TriangulatedSES;
00077 friend class SESTriangulator;
00078 friend class SASEdge;
00079 friend class SASFace;
00080 friend class SASVertex;
00081 friend class SolventAccessibleSurface;
00082 friend class TriangulatedSAS;
00083 friend class SASTriangulator;
00084
00085 BALL_CREATE(RSFace)
00086
00087
00090
00094 RSFace()
00095 ;
00096
00104 RSFace(const RSFace& rsface, bool deep = false)
00105 ;
00106
00120 RSFace(RSVertex* vertex1,
00121 RSVertex* vertex2,
00122 RSVertex* vertex3,
00123 RSEdge* edge1,
00124 RSEdge* edge2,
00125 RSEdge* edge3,
00126 const TVector3<double>& center,
00127 const TVector3<double>& normal,
00128 bool singular,
00129 Index index)
00130 throw(Exception::DivisionByZero);
00131
00135 virtual ~RSFace()
00136 ;
00137
00139
00142
00149 void set(const RSFace& rsface, bool deep = false)
00150 ;
00151
00157 RSFace& operator = (const RSFace& rsface)
00158 ;
00159
00172 void set(RSVertex* vertex1,
00173 RSVertex* vertex2,
00174 RSVertex* vertex3,
00175 RSEdge* edge1,
00176 RSEdge* edge2,
00177 RSEdge* edge3,
00178 const TVector3<double>& center,
00179 const TVector3<double>& normal,
00180 bool singular,
00181 Index index)
00182 throw(Exception::DivisionByZero);
00183
00185
00188
00193 virtual bool operator == (const RSFace& rsface) const
00194 ;
00195
00200 virtual bool operator != (const RSFace& rsface) const
00201 ;
00202
00207 virtual bool operator *=(const RSFace& rsface) const
00208 ;
00209
00214 bool isSingular() const
00215 ;
00216
00218
00221
00225 void setCenter(const TVector3<double>& center)
00226 ;
00227
00231 TVector3<double> getCenter() const
00232 ;
00233
00237 void setNormal(const TVector3<double>& normal)
00238 throw(Exception::DivisionByZero);
00239
00243 TVector3<double> getNormal() const
00244 ;
00245
00248 void setSingular(bool singular)
00249 ;
00250
00259 void remove
00260 (HashSet<RSEdge*>& edges,
00261 HashSet<RSVertex*>& vertices,
00262 HashSet<RSFace*>& faces)
00263 ;
00264
00266
00267 protected:
00268
00269
00270
00272
00273
00274
00275 TVector3<double> center_;
00276
00277
00278 TVector3<double> normal_;
00279
00280
00281 bool singular_;
00282
00284
00285 };
00286
00290
00293 BALL_EXPORT std::ostream& operator << (std::ostream& s, const RSFace& rsface);
00294
00296
00297 }
00298
00299 #endif // BALL_STRUCTURE_RSFACE_H