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/02/10 16:00:09 $
00007   Version:   $Revision: 1.12 $
00008 
00009   Copyright (c) 2002 Insight 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 "itkSpatialObject.h"
00024 #include "itkSpatialObjectPoint.h"
00025 
00026 namespace itk 
00027 {
00028 
00038 template < unsigned int TDimension = 3 >
00039 class BlobSpatialObject 
00040 :public SpatialObject<  TDimension >
00041 {
00042 
00043 public:
00044 
00045   typedef BlobSpatialObject                           Self;
00046   typedef SpatialObject< TDimension >                 Superclass;
00047   typedef SmartPointer < Self >                       Pointer;
00048   typedef SmartPointer < const Self >                 ConstPointer;
00049   typedef double                                      ScalarType;
00050   typedef SpatialObjectPoint< TDimension >            BlobPointType; 
00051   typedef std::list < BlobPointType >                 PointListType;
00052   typedef typename Superclass::PointType              PointType;
00053   typedef VectorContainer<unsigned long,PointType>    PointContainerType;
00054   typedef SmartPointer<PointContainerType>            PointContainerPointer;
00055 
00057   itkNewMacro( Self );
00058 
00060   itkTypeMacro( Self, Superclass );
00061   
00063   PointListType & GetPoints( void );
00064 
00066   const PointListType & GetPoints( void ) const;
00067 
00069   void SetPoints( PointListType & newPoints );
00070 
00073   bool IsEvaluableAt( const PointType & point, 
00074                       unsigned int depth=0, char *name = NULL ) const;
00075 
00080   bool ValueAt( const PointType & point, double & value,
00081                 unsigned int depth=0, char *name = NULL ) const;
00082 
00084   bool IsInside( const PointType & point,
00085                  unsigned int depth=0, char *name = NULL ) const;
00086 
00088   bool ComputeBoundingBox( unsigned int depth=0, char *name = NULL );
00089 
00090 protected:
00091 
00092   PointListType   m_Points;
00093 
00094   BlobSpatialObject();
00095   virtual ~BlobSpatialObject();
00096 
00098   virtual void PrintSelf( std::ostream& os, Indent indent ) const;
00099 };
00100 
00101 } // end namespace itk
00102 
00103 #ifndef ITK_MANUAL_INSTANTIATION 
00104   #include "itkBlobSpatialObject.txx" 
00105 #endif 
00106 
00107 #endif // __itkBlobSpatialObject_h

Generated at Fri May 21 01:14:28 2004 for ITK by doxygen 1.2.15 written by Dimitri van Heesch, © 1997-2000