00001 
00002 
00003 
00004 
00005 
00006 
00007 
00008 
00009 
00010 
00011 
00012 
00013 
00014 
00015 
00016 
00017 
00018 
00019 
00020 
00021 
00022 
00023 
00024 
00025 
00026 
00027 
00028 #ifndef _math_isosurf_vertex_h
00029 #define _math_isosurf_vertex_h
00030 
00031 #ifdef __GNUC__
00032 #pragma interface
00033 #endif
00034 
00035 #include <stdlib.h>
00036 #include <math.h>
00037 #include <util/ref/ref.h>
00038 #include <math/scmat/matrix.h>
00039 #include <math/isosurf/volume.h>
00040 #include <math/isosurf/implicit.h>
00041 
00042 class Vertex: public RefCount {
00043   private:
00044     SCVector3 _point;
00045     SCVector3 *_normal; 
00046   public:
00047     Vertex();
00048     Vertex(const SCVector3& point,const SCVector3& normal);
00049     Vertex(const SCVector3& point);
00050     ~Vertex();
00051     const SCVector3& point() const { return _point; }
00052     int has_normal() const { return _normal != 0; }
00053     const SCVector3& normal() const { return *_normal; }
00054     void set_point(const SCVector3&p);
00055     void set_normal(const SCVector3&p);
00056     operator SCVector3&();
00057 
00058     void print(std::ostream&o=ExEnv::out());
00059 };
00060 
00061 
00062 
00063 #endif
00064 
00065 
00066 
00067 
00068