Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef __itkSpatialObjectToPointSetFilter_h
00018 #define __itkSpatialObjectToPointSetFilter_h
00019
00020 #include "itkPointSet.h"
00021 #include "itkMeshSource.h"
00022 #include "itkPointBasedSpatialObject.h"
00023
00024 namespace itk
00025 {
00026
00032 template <class TInputSpatialObject, class TOutputPointSet>
00033 class ITK_EXPORT SpatialObjectToPointSetFilter : public MeshSource<TOutputPointSet>
00034 {
00035 public:
00037 typedef SpatialObjectToPointSetFilter Self;
00038 typedef MeshSource<TOutputPointSet> Superclass;
00039 typedef SmartPointer<Self> Pointer;
00040 typedef SmartPointer<const Self> ConstPointer;
00041
00042 typedef TOutputPointSet OutputPointSetType;
00043 typedef typename OutputPointSetType::Pointer OutputPointSetPointer;
00044
00046 typedef DataObject::Pointer DataObjectPointer;
00047
00049 itkNewMacro(Self);
00050
00052 itkTypeMacro(SpatialObjectToPointSetFilter,ProcessObject);
00053
00055 typedef TInputSpatialObject InputSpatialObjectType;
00056 typedef typename InputSpatialObjectType::Pointer InputSpatialObjectPointer;
00057 typedef typename InputSpatialObjectType::ConstPointer InputSpatialObjectConstPointer;
00058 typedef typename TInputSpatialObject::ChildrenListType ChildrenListType;
00059
00060
00062 itkStaticConstMacro(ObjectDimension, unsigned int,
00063 InputSpatialObjectType::ObjectDimension);
00064
00065 typedef itk::SpatialObjectPoint<itkGetStaticConstMacro(ObjectDimension)> PointType;
00066 typedef itk::PointBasedSpatialObject<itkGetStaticConstMacro(ObjectDimension)> PointBasedSpatialObjectType;
00067
00069 virtual void SetInput( const InputSpatialObjectType *object);
00070 virtual void SetInput( unsigned int, const InputSpatialObjectType * object);
00071 const InputSpatialObjectType * GetInput(void);
00072 const InputSpatialObjectType * GetInput(unsigned int idx);
00074
00079 itkSetMacro(ChildrenDepth, unsigned int);
00080 itkGetConstMacro(ChildrenDepth, unsigned int);
00082
00083
00084
00085
00086 itkSetMacro(SamplingFactor, unsigned int);
00087 itkGetConstMacro(SamplingFactor, unsigned int);
00088
00089 protected:
00090 SpatialObjectToPointSetFilter();
00091 ~SpatialObjectToPointSetFilter();
00092
00093 virtual void GenerateOutputInformation(){};
00094 virtual void GenerateData();
00095
00096 unsigned int m_ChildrenDepth;
00097
00098 virtual void PrintSelf(std::ostream& os, Indent indent) const;
00099
00100 private:
00101 SpatialObjectToPointSetFilter(const Self&);
00102 void operator=(const Self&);
00103
00104 unsigned int m_SamplingFactor;
00105
00106
00107 };
00108
00109 }
00110
00111 #ifndef ITK_MANUAL_INSTANTIATION
00112 #include "itkSpatialObjectToPointSetFilter.txx"
00113 #endif
00114
00115 #endif
00116