18 #ifndef itkShapePositionLabelMapFilter_h
19 #define itkShapePositionLabelMapFilter_h
37 template<
typename TImage>
59 itkStaticConstMacro(ImageDimension,
unsigned int,
60 TImage::ImageDimension);
69 #ifdef ITK_USE_CONCEPT_CHECKING
88 this->SetAttribute( LabelObjectType::GetAttributeFromName( s ) );
96 virtual void ThreadedProcessLabelObject( LabelObjectType * labelObject ) ITK_OVERRIDE;
98 template<
typename TAttributeAccessor >
101 typedef typename TAttributeAccessor::AttributeValueType AttributeValueType;
102 AttributeValueType position = accessor( labelObject );
107 typedef double CoordinateType;
110 for(
unsigned int i=0; i<ImageDimension; i++ )
118 this->GetOutput()->TransformPhysicalPointToIndex( point, idx );
123 for(
unsigned int i=0; i<ImageDimension; i++ )
129 labelObject->Clear();
131 labelObject->AddIndex( idx );
134 void PrintSelf(std::ostream& os,
Indent indent)
const ITK_OVERRIDE;
145 #ifndef ITK_MANUAL_INSTANTIATION
146 #include "itkShapePositionLabelMapFilter.hxx"
void SetAttribute(const std::string &s)
SmartPointer< const Self > ConstPointer
Light weight base class for most itk classes.
void TemplatedThreadedProcessLabelObject(const TAttributeAccessor &accessor, bool physical, LabelObjectType *labelObject)
signed long OffsetValueType
signed long IndexValueType
ImageType::LabelObjectType LabelObjectType
~ShapePositionLabelMapFilter() override
AttributeType m_Attribute
ImageType::PixelType PixelType
InPlaceLabelMapFilter< TImage > Superclass
ImageType::ConstPointer ImageConstPointer
ImageType::Pointer ImagePointer
Mark a single pixel in the label object which correspond to a position given by an attribute...
Base class for filters that takes an image as input and overwrites that image as the output...
LabelObjectType::AttributeType AttributeType
Control indentation during Print() invocation.
ImageType::IndexType IndexType
ShapePositionLabelMapFilter Self
SmartPointer< Self > Pointer
A templated class holding a geometric point in n-Dimensional space.
ImageBaseType::IndexType IndexType