00001
00015 #ifndef MDS_TETRADATA_H
00016 #define MDS_TETRADATA_H
00017
00018
00019 #include <MDSTk/Base/mdsAssert.h>
00020 #include <MDSTk/Base/mdsTypes.h>
00021 #include <MDSTk/Base/mdsSmallObject.h>
00022
00023
00024 #include <VectorEntity/mcentity.h>
00025 #include <VectorEntity/mcsphere.h>
00026
00027
00028 namespace mds
00029 {
00030 namespace seg
00031 {
00032
00033
00038
00039 struct STetrahedronInfo : public mds::base::CSmallValueObject<>
00040 {
00042 vctl::MCSphere Circumsphere;
00043
00045 void *pData;
00046
00048 STetrahedronInfo() : pData(NULL) {}
00049 };
00050
00051
00052
00053
00054
00055
00056
00058 inline vctl::MCSphere *getTetrahedronCircumsphere(vctl::MCTetra *pTetrahedron)
00059 {
00060 return &(((STetrahedronInfo *)pTetrahedron->GetValuePtr())->Circumsphere);
00061 }
00062
00063
00066 inline void *getTetrahedronDataPtr(vctl::MCTetra *pTetrahedron)
00067 {
00068 return ((STetrahedronInfo *)pTetrahedron->GetValuePtr())->pData;
00069 }
00070
00071
00073 inline void setTetrahedronDataPtr(vctl::MCTetra *pTetrahedron, void *pData)
00074 {
00075 ((STetrahedronInfo *)pTetrahedron->GetValuePtr())->pData = pData;
00076 }
00077
00078
00079 }
00080 }
00081
00082 #endif // MDS_TETRADATA_H
00083