BALL  1.4.1
trianglePoint.h
Go to the documentation of this file.
00001 // -*- Mode: C++; tab-width: 2; -*-
00002 // vi: set ts=2:
00003 //
00004 
00005 #ifndef BALL_STRUCTURE_TRIANGLEPOINT_H
00006 #define BALL_STRUCTURE_TRIANGLEPOINT_H
00007 
00008 #ifndef BALL_MATHS_VECTOR3_H
00009 # include <BALL/MATHS/vector3.h>
00010 #endif
00011 
00012 #ifndef BALL_STRUCTURE_GRAPHEDGE_H
00013 # include <BALL/STRUCTURE/graphEdge.h>
00014 #endif
00015 
00016 #ifndef BALL_STRUCTURE_GRAPHFACE_H
00017 # include <BALL/STRUCTURE/graphFace.h>
00018 #endif
00019 
00020 #ifndef BALL_STRUCTURE_GRAPHVERTEX_H
00021 # include <BALL/STRUCTURE/graphVertex.h>
00022 #endif
00023 
00024 
00025 namespace BALL
00026 {
00027 
00028   class TriangleEdge;
00029   class Triangle;
00030   class TriangulatedSurface;
00031   class TriangulatedSphere;
00032   class TriangulatedSES;
00033   class SESTriangulator;
00034   class TriangulatedSAS;
00035   class SASTriangulator;
00036 
00037 
00041   class BALL_EXPORT TrianglePoint
00042       : public GraphVertex< TrianglePoint,TriangleEdge,Triangle >
00043   {
00044     
00045     public:
00046 
00059     friend class Triangle;
00060     friend class TriangleEdge;
00061     friend class TriangulatedSurface;
00062     friend class TriangulatedSphere;
00063     friend class TriangulatedSES;
00064     friend class SESTriangulator;
00065     friend class TriangulatedSAS;
00066     friend class SASTriangulator;
00067 
00068     BALL_CREATE(TrianglePoint)
00069 
00070     
00073 
00077     TrianglePoint()
00078       ;
00079 
00084     TrianglePoint(const TVector3<double>& point, const TVector3<double>& normal = TVector3<double>(0.));
00085 
00093     TrianglePoint(const TrianglePoint& point, bool deep = false)
00094       ;
00095 
00099     virtual ~TrianglePoint()
00100       ;
00101 
00103 
00106 
00114     void set(const TrianglePoint& point, bool deep = false)
00115       ;
00116 
00122     TrianglePoint& operator = (const TrianglePoint& point)
00123       ;
00124 
00126 
00129 
00132     TVector3<double> getPoint() const
00133       ;
00134 
00137     void setPoint(const TVector3<double>& point)
00138       ;
00139 
00142     TVector3<double> getNormal() const
00143       ;
00144 
00147     void setNormal(const TVector3<double>& normal)
00148       throw(Exception::DivisionByZero);
00149 
00151 
00155 
00160     virtual bool operator == (const TrianglePoint& point) const
00161       ;
00162 
00167     virtual bool operator != (const TrianglePoint& point) const
00168       ;
00169 
00174     virtual bool operator *= (const TrianglePoint& point) const
00175       ;
00176 
00178 
00179     protected:
00180 
00181     /*_ The point itself
00182     */
00183     TVector3<double> point_;
00184     /*_ The normal vector of the point
00185     */
00186     TVector3<double> normal_;
00187 
00188   };
00189 
00190 
00194 
00197   BALL_EXPORT std::ostream& operator << (std::ostream& s, const TrianglePoint& point);
00198 
00200 
00201 
00202 } // namespace BALL
00203 
00204 
00205 #endif  // BALL_STRUCTURE_TRIANGLEPOINT_H
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Defines