00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef __itkVertexCell_h
00018 #define __itkVertexCell_h
00019
00020 #include "itkCellInterface.h"
00021 #include "itkCellBoundary.h"
00022
00023 namespace itk
00024 {
00025
00043 template < typename TCellInterface >
00044 class VertexCell: public TCellInterface
00045 {
00046 public:
00048 itkCellCommonTypedefs(VertexCell);
00049 itkCellInheritedTypedefs(TCellInterface);
00050
00052 itkTypeMacro(VertexCell, CellInterface);
00053
00055 itkStaticConstMacro(NumberOfPoints, unsigned int, 1);
00056 itkStaticConstMacro(CellDimension, unsigned int, 0);
00057
00059 virtual CellGeometry GetType(void) const
00060 {return Superclass::VERTEX_CELL;}
00061 virtual void MakeCopy( CellAutoPointer & ) const;
00062 virtual unsigned int GetDimension(void) const;
00063 virtual unsigned int GetNumberOfPoints(void) const;
00064 virtual CellFeatureCount GetNumberOfBoundaryFeatures(int dimension) const;
00065 virtual bool GetBoundaryFeature(int dimension, CellFeatureIdentifier, CellAutoPointer &);
00066 virtual void SetPointIds(PointIdConstIterator first);
00067 virtual void SetPointIds(PointIdConstIterator first,
00068 PointIdConstIterator last);
00069 virtual void SetPointId(int localId, PointIdentifier);
00070 virtual PointIdIterator PointIdsBegin(void);
00071 virtual PointIdConstIterator PointIdsBegin(void) const;
00072 virtual PointIdIterator PointIdsEnd(void);
00073 virtual PointIdConstIterator PointIdsEnd(void) const;
00074
00076 virtual void SetPointId(PointIdentifier);
00077 virtual PointIdentifier GetPointId(void);
00078
00080 itkCellVisitMacro(VERTEX_CELL);
00081
00082 public:
00083 VertexCell() {}
00084 ~VertexCell() {}
00085
00086 protected:
00090 PointIdentifier m_PointIds[NumberOfPoints];
00091
00092 private:
00093 VertexCell(const Self&);
00094 void operator=(const Self&);
00095 };
00096
00100 template <typename TCellInterface>
00101 class VertexBoundary:
00102 public CellBoundary< VertexCell< TCellInterface > >
00103 {
00104 public:
00106 itkCellCommonTypedefs(VertexBoundary);
00107
00109 itkTypeMacro(VertexBoundary, CellBoundary);
00110 };
00111
00112 }
00113
00114 #ifndef ITK_MANUAL_INSTANTIATION
00115 #include "itkVertexCell.txx"
00116 #endif
00117
00118 #endif