|
ITK
5.1.0
Insight Toolkit
|
Go to the documentation of this file.
18 #ifndef itkMaskImageFilter_h
19 #define itkMaskImageFilter_h
35 template <
typename TInput,
typename TMask,
typename TOutput = TInput>
56 return !(*
this != other);
64 return static_cast<TOutput>(A);
101 template <
typename TPixelType>
108 template <
typename TValue>
155 template <
typename TInputImage,
typename TMaskImage,
typename TOutputImage = TInputImage>
167 MaskInput<typename TInputImage::PixelType, typename TMaskImage::PixelType, typename TOutputImage::PixelType>;
189 this->
SetNthInput(1, const_cast<MaskImageType *>(maskImage));
210 const typename TOutputImage::PixelType &
229 const typename TMaskImage::PixelType &
235 #ifdef ITK_USE_CONCEPT_CHECKING
251 os << indent <<
"OutsideValue: " << this->
GetOutsideValue() << std::endl;
257 using PixelType =
typename TOutputImage::PixelType;
273 template <
typename TPixelType>
278 template <
typename TValue>
291 if (currentValue == zeroVector)
293 zeroVector.SetSize(this->
GetOutput()->GetVectorLength());
300 <<
" is not the same as the "
301 <<
"number of components in the image: " << this->
GetOutput()->GetVectorLength());
void Fill(TValue const &v)
const TOutputImage::PixelType & GetOutsideValue() const
unsigned int GetSize() const
void BeforeThreadedGenerateData() override
Implements pixel-wise generic operation of two images, or of an image and a constant.
Control indentation during Print() invocation.
bool NotExactlyEquals(const TInput1 &x1, const TInput2 &x2)
virtual const FunctorType & GetFunctor() const
void SetOutsideValue(const typename TOutputImage::PixelType &outsideValue)
void CheckOutsideValue(const TPixelType *)
MaskImageFilter()=default
void SetMaskingValue(const typename TMaskImage::PixelType &maskingValue)
Base class for all process objects that output image data.
Mask an image with a mask.
void PrintSelf(std::ostream &os, Indent indent) const override
const TMaskImage::PixelType & GetMaskingValue() const
~MaskImageFilter() override=default
void SetMaskImage(const MaskImageType *maskImage)
Represents an array whose length can be defined at run-time.
void CheckOutsideValue(const VariableLengthVector< TValue > *)
Define additional traits for native types such as int or float.
#define itkConceptMacro(name, concept)
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....
The base class for all process objects (source, filters, mappers) in the Insight data processing pipe...
virtual void SetNthInput(DataObjectPointerArraySizeType num, DataObject *input)
FunctorType & GetFunctor()
void PrintSelf(std::ostream &os, Indent indent) const override
const MaskImageType * GetMaskImage()
OutputImageType * GetOutput()
virtual void Modified() const
DataObject * GetInput(const DataObjectIdentifierType &key)
Return an input.
void SetFunctor(const std::function< ConstRefFunctionType > &f)
Functor::MaskInput< typename TInputImage::PixelType, typename TMaskImage::PixelType, typename TOutputImage::PixelType > FunctorType