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 TOutputPo
intSet>
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 typedef TOutputPointSet
OutputPointSetType;
00042 typedef typename OutputPointSetType::Pointer
OutputPointSetPointer;
00043
00045 typedef DataObject::Pointer DataObjectPointer;
00046
00048
itkNewMacro(
Self);
00049
00051
itkTypeMacro(SpatialObjectToPointSetFilter,
ProcessObject);
00052
00054 typedef TInputSpatialObject
InputSpatialObjectType;
00055 typedef typename InputSpatialObjectType::Pointer
InputSpatialObjectPointer;
00056 typedef typename InputSpatialObjectType::ConstPointer
InputSpatialObjectConstPointer;
00057 typedef typename TInputSpatialObject::ChildrenListType
ChildrenListType;
00058
00059
00061
itkStaticConstMacro(ObjectDimension,
unsigned int,
00062 InputSpatialObjectType::ObjectDimension);
00063
00064 typedef itk::SpatialObjectPoint<itkGetStaticConstMacro(ObjectDimension)> PointType;
00065 typedef itk::PointBasedSpatialObject<itkGetStaticConstMacro(ObjectDimension)> PointBasedSpatialObjectType;
00066
00068
virtual void SetInput(
const InputSpatialObjectType *object);
00069
virtual void SetInput(
unsigned int,
const InputSpatialObjectType * object);
00070
const InputSpatialObjectType * GetInput(
void);
00071
const InputSpatialObjectType * GetInput(
unsigned int idx);
00072
00077
itkSetMacro(ChildrenDepth,
unsigned int);
00078
itkGetMacro(ChildrenDepth,
unsigned int);
00079
00080
00081
00082
00083
itkSetMacro(SamplingFactor,
unsigned int);
00084
itkGetMacro(SamplingFactor,
unsigned int);
00085
00086
protected:
00087 SpatialObjectToPointSetFilter();
00088 ~SpatialObjectToPointSetFilter();
00089
00090
virtual void GenerateOutputInformation(){};
00091
virtual void GenerateData();
00092
00093
unsigned int m_ChildrenDepth;
00094
00095 virtual void PrintSelf(std::ostream& os,
Indent indent)
const;
00096
00097
private:
00098 SpatialObjectToPointSetFilter(
const Self&);
00099
void operator=(
const Self&);
00100
00101
unsigned int m_SamplingFactor;
00102
00103
00104 };
00105
00106 }
00107
00108
#ifndef ITK_MANUAL_INSTANTIATION
00109
#include "itkSpatialObjectToPointSetFilter.txx"
00110
#endif
00111
00112
#endif