Main Page   Groups   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Concepts

itkBlobSpatialObject.h

Go to the documentation of this file.
00001 /*========================================================================= 00002 00003 Program: Insight Segmentation & Registration Toolkit 00004 Module: $RCSfile: itkBlobSpatialObject.h,v $ 00005 Language: C++ 00006 Date: $Date: 2003/11/07 23:27:29 $ 00007 Version: $Revision: 1.21 $ 00008 00009 Copyright (c) Insight Software Consortium. All rights reserved. 00010 See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details. 00011 00012 This software is distributed WITHOUT ANY WARRANTY; without even 00013 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 00014 PURPOSE. See the above copyright notices for more information. 00015 00016 =========================================================================*/ 00017 00018 #ifndef __itkBlobSpatialObject_h 00019 #define __itkBlobSpatialObject_h 00020 00021 #include <list> 00022 00023 #include "itkPointBasedSpatialObject.h" 00024 #include "itkSpatialObjectPoint.h" 00025 00026 namespace itk 00027 { 00028 00042 template < unsigned int TDimension = 3 > 00043 class BlobSpatialObject 00044 :public PointBasedSpatialObject< TDimension > 00045 { 00046 00047 public: 00048 00049 typedef BlobSpatialObject Self; 00050 typedef PointBasedSpatialObject< TDimension > Superclass; 00051 typedef SmartPointer < Self > Pointer; 00052 typedef SmartPointer < const Self > ConstPointer; 00053 typedef double ScalarType; 00054 typedef SpatialObjectPoint< TDimension > BlobPointType; 00055 typedef std::vector< BlobPointType > PointListType; 00056 typedef typename Superclass::PointType PointType; 00057 typedef typename Superclass::SpatialObjectPointType SpatialObjectPointType; 00058 typedef typename Superclass::TransformType TransformType; 00059 typedef VectorContainer<unsigned long,PointType> PointContainerType; 00060 typedef SmartPointer<PointContainerType> PointContainerPointer; 00061 00063 itkNewMacro( Self ); 00064 00066 itkTypeMacro( BlobSpatialObject, SpatialObject ); 00067 00069 PointListType & GetPoints( void ); 00070 00072 const PointListType & GetPoints( void ) const; 00073 00075 void SetPoints( PointListType & newPoints ); 00076 00078 const SpatialObjectPointType* GetPoint(unsigned long id) const {return &(m_Points[id]);} 00079 00081 unsigned long GetNumberOfPoints(void) const {return m_Points.size();} 00082 00085 bool IsEvaluableAt( const PointType & point, 00086 unsigned int depth=0, char * name=NULL ) const; 00087 00092 bool ValueAt( const PointType & point, double & value, 00093 unsigned int depth=0, char * name=NULL ) const; 00094 00096 bool IsInside( const PointType & point, 00097 unsigned int depth=0, char * name=NULL ) const; 00098 00100 bool ComputeBoundingBox() const; 00101 00102 protected: 00103 00104 PointListType m_Points; 00105 00106 BlobSpatialObject(); 00107 virtual ~BlobSpatialObject(); 00108 00110 virtual void PrintSelf( std::ostream& os, Indent indent ) const; 00111 }; 00112 00113 } // end namespace itk 00114 00115 #ifndef ITK_MANUAL_INSTANTIATION 00116 #include "itkBlobSpatialObject.txx" 00117 #endif 00118 00119 #endif // __itkBlobSpatialObject_h

Generated at Sun Apr 1 02:24:54 2007 for ITK by doxygen 1.3.8 written by Dimitri van Heesch, © 1997-2000