28#ifndef itkInPlaceImageFilter_h
29#define itkInPlaceImageFilter_h
76template <
typename TInputImage,
typename TOutputImage = TInputImage>
105 static constexpr unsigned int InputImageDimension = TInputImage::ImageDimension;
106 static constexpr unsigned int OutputImageDimension = TOutputImage::ImageDimension;
113 itkSetMacro(InPlace,
bool);
114 itkGetConstMacro(InPlace,
bool);
115 itkBooleanMacro(InPlace);
151 if (std::is_same_v<TInputImage, TOutputImage>)
153 this->InternalAllocateOutputs();
157 this->m_RunningInPlace =
false;
158 this->Superclass::AllocateOutputs();
179 itkGetConstMacro(RunningInPlace,
bool);
185 bool m_InPlace{
true };
186 bool m_RunningInPlace{
false };
190#ifndef ITK_MANUAL_INSTANTIATION
191# include "itkInPlaceImageFilter.hxx"
typename OutputImageType::PixelType OutputImagePixelType
typename OutputImageType::RegionType OutputImageRegionType
TOutputImage OutputImageType
typename OutputImageType::Pointer OutputImagePointer
Base class for filters that take an image as input and produce an image as output.
Base class for filters that take an image as input and overwrite that image as the output.
~InPlaceImageFilter() override=default
typename InputImageType::Pointer InputImagePointer
void InternalAllocateOutputs()
virtual bool CanRunInPlace() const
void PrintSelf(std::ostream &os, Indent indent) const override
void AllocateOutputs() override
typename InputImageType::ConstPointer InputImageConstPointer
typename InputImageType::PixelType InputImagePixelType
void ReleaseInputs() override
TInputImage InputImageType
InPlaceImageFilter()=default
typename InputImageType::RegionType InputImageRegionType
Control indentation during Print() invocation.
SmartPointer< const Self > ConstPointer
SmartPointer< Self > Pointer
ImageBaseType::RegionType RegionType
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....