18 #ifndef itkLabelMapMaskImageFilter_h
19 #define itkLabelMapMaskImageFilter_h
45 template<
typename TInputImage,
typename TOutputImage>
66 using LabelType =
typename LabelObjectType::LabelType;
79 static constexpr
unsigned int InputImageDimension = TInputImage::ImageDimension;
80 static constexpr
unsigned int OutputImageDimension = TOutputImage::ImageDimension;
81 static constexpr
unsigned int ImageDimension = TOutputImage::ImageDimension;
93 this->SetNthInput( 1, const_cast<TOutputImage *>(input) );
105 this->SetInput( input );
111 this->SetFeatureImage( input );
118 itkSetMacro(BackgroundValue, OutputImagePixelType);
119 itkGetConstMacro(BackgroundValue, OutputImagePixelType);
125 itkSetMacro(Label, InputImagePixelType);
126 itkGetConstMacro(Label, InputImagePixelType);
132 itkSetMacro(Negated,
bool);
133 itkGetConstReferenceMacro(Negated,
bool);
134 itkBooleanMacro(Negated);
140 itkSetMacro(Crop,
bool);
141 itkGetConstReferenceMacro(Crop,
bool);
142 itkBooleanMacro(Crop);
150 itkGetConstReferenceMacro(CropBorder,
SizeType);
160 void GenerateInputRequestedRegion()
override;
163 void EnlargeOutputRequestedRegion(
DataObject *itkNotUsed(output))
override;
165 void GenerateOutputInformation()
override;
167 void GenerateData()
override;
169 void DynamicThreadedGenerateData(
const OutputImageRegionType& outputRegionForThread)
override;
174 Superclass::DynamicThreadedGenerateData(outputRegion);
177 void ThreadedProcessLabelObject( LabelObjectType * labelObject )
override;
179 void PrintSelf(std::ostream& os,
Indent indent)
const override;
184 bool m_Negated{
false };
185 bool m_Crop{
false };
193 #ifndef ITK_MANUAL_INSTANTIATION
194 #include "itkLabelMapMaskImageFilter.hxx"
TimeStamp m_CropTimeStamp
typename OutputImageType::Pointer OutputImagePointer
void SetInput1(const TInputImage *input)
void SetInput2(const TOutputImage *input)
typename InputImageType::LabelObjectType LabelObjectType
The base class for all process objects (source, filters, mappers) in the Insight data processing pipe...
typename LabelObjectType::LengthType LengthType
typename OutputImageType::RegionType RegionType
Base class for all process objects that output image data.
void SetFeatureImage(const TOutputImage *input)
TInputImage InputImageType
typename OutputImageType::ConstPointer OutputImageConstPointer
typename OutputImageType::PixelType OutputImagePixelType
typename InputImageType::PixelType InputImagePixelType
typename InputImageType::Pointer InputImagePointer
ImageBaseType::SizeType SizeType
typename OutputImageType::RegionType OutputImageRegionType
ImageBaseType::IndexType IndexType
typename OutputImageType::SizeType SizeType
TOutputImage OutputImageType
typename LabelObjectType::LabelType LabelType
Generate a unique, increasing time value.
Base class for filters that take an image as input and overwrite that image as the output...
DataObject * GetInput(const DataObjectIdentifierType &key)
Return an input.
typename InputImageType::RegionType InputImageRegionType
Control indentation during Print() invocation.
void SuperclassDynamicTGD(const OutputImageRegionType &outputRegion)
const OutputImageType * GetFeatureImage()
ImageBaseType::RegionType RegionType
typename OutputImageType::IndexType IndexType
OutputImagePixelType m_BackgroundValue
typename InputImageType::ConstPointer InputImageConstPointer
InputImagePixelType m_Label
Base class for all data objects in ITK.
Mask and image with a LabelMap.