ITK  5.1.0
Insight Toolkit
itkPadImageFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 #ifndef itkPadImageFilter_h
19 #define itkPadImageFilter_h
20 
21 #include "itkPadImageFilterBase.h"
22 
24 
25 namespace itk
26 {
46 template <typename TInputImage, typename TOutputImage>
47 class ITK_TEMPLATE_EXPORT PadImageFilter : public PadImageFilterBase<TInputImage, TOutputImage>
48 {
49 public:
50  ITK_DISALLOW_COPY_AND_ASSIGN(PadImageFilter);
51 
57 
59  itkNewMacro(Self);
60 
64 
66  using OutputImagePixelType = typename TOutputImage::PixelType;
67  using InputImagePixelType = typename TInputImage::PixelType;
68 
74  using SizeType = typename TInputImage::SizeType;
76 
80 
82  itkTypeMacro(PadImageFilter, PadImageFilterBase);
83 
85  static constexpr unsigned int ImageDimension = TInputImage::ImageDimension;
86 
89  itkSetMacro(PadLowerBound, SizeType);
90  itkSetMacro(PadUpperBound, SizeType);
91  itkGetConstReferenceMacro(PadLowerBound, SizeType);
92  itkGetConstReferenceMacro(PadUpperBound, SizeType);
93  itkSetVectorMacro(PadLowerBound, const SizeValueType, ImageDimension);
94  itkSetVectorMacro(PadUpperBound, const SizeValueType, ImageDimension);
96 
97  void
99  {
100  this->SetPadLowerBound(bound);
101  this->SetPadUpperBound(bound);
102  }
103 
104 protected:
105  PadImageFilter();
106  ~PadImageFilter() override = default;
107  void
108  PrintSelf(std::ostream & os, Indent indent) const override;
109 
116  void
117  GenerateOutputInformation() override;
118 
119 private:
122 };
123 } // end namespace itk
124 
125 #ifndef ITK_MANUAL_INSTANTIATION
126 # include "itkPadImageFilter.hxx"
127 #endif
128 
129 #endif
itk::PadImageFilter::InputImageIndexType
typename TInputImage::IndexType InputImageIndexType
Definition: itkPadImageFilter.h:71
itk::PadImageFilterBase
Increase the image size by padding. Superclass for filters that fill in extra pixels.
Definition: itkPadImageFilterBase.h:47
itk::PadImageFilter::OutputImageSizeType
typename TOutputImage::SizeType OutputImageSizeType
Definition: itkPadImageFilter.h:72
itk::PadImageFilter::OutputImageIndexType
typename TOutputImage::IndexType OutputImageIndexType
Definition: itkPadImageFilter.h:70
itk::PadImageFilter::SizeValueType
typename TInputImage::SizeValueType SizeValueType
Definition: itkPadImageFilter.h:75
itk::GTest::TypedefsAndConstructors::Dimension2::SizeType
ImageBaseType::SizeType SizeType
Definition: itkGTestTypedefsAndConstructors.h:49
itk::SmartPointer< Self >
itk::Indent
Control indentation during Print() invocation.
Definition: itkIndent.h:49
itk::ImageBoundaryCondition
A virtual base object that defines an interface to a class of boundary condition objects for use by n...
Definition: itkImageBoundaryCondition.h:52
itk::PadImageFilter::InputImageSizeType
typename TInputImage::SizeType InputImageSizeType
Definition: itkPadImageFilter.h:73
itkImageBoundaryCondition.h
itk::ImageToImageFilter::InputImagePixelType
typename InputImageType::PixelType InputImagePixelType
Definition: itkImageToImageFilter.h:133
itk::GTest::TypedefsAndConstructors::Dimension2::IndexType
ImageBaseType::IndexType IndexType
Definition: itkGTestTypedefsAndConstructors.h:50
itk::ImageSource
Base class for all process objects that output image data.
Definition: itkImageSource.h:67
itk::PadImageFilter::SizeType
typename TInputImage::SizeType SizeType
Definition: itkPadImageFilter.h:74
itk::GTest::TypedefsAndConstructors::Dimension2::RegionType
ImageBaseType::RegionType RegionType
Definition: itkGTestTypedefsAndConstructors.h:54
itk::PadImageFilter
Increase the image size by padding. Superclass for filters that fill in extra pixels.
Definition: itkPadImageFilter.h:47
itk::ImageSource::OutputImageRegionType
typename OutputImageType::RegionType OutputImageRegionType
Definition: itkImageSource.h:92
itk
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....
Definition: itkArray.h:26
itk::ProcessObject
The base class for all process objects (source, filters, mappers) in the Insight data processing pipe...
Definition: itkProcessObject.h:135
itk::ImageSource::OutputImagePixelType
typename OutputImageType::PixelType OutputImagePixelType
Definition: itkImageSource.h:93
itk::PadImageFilter::m_PadLowerBound
SizeType m_PadLowerBound
Definition: itkPadImageFilter.h:120
itk::PadImageFilter::m_PadUpperBound
SizeType m_PadUpperBound
Definition: itkPadImageFilter.h:121
itk::PadImageFilter::SetPadBound
void SetPadBound(const InputImageSizeType &bound)
Definition: itkPadImageFilter.h:98
itk::ImageToImageFilter::InputImageRegionType
typename InputImageType::RegionType InputImageRegionType
Definition: itkImageToImageFilter.h:132
itkPadImageFilterBase.h
itk::SizeValueType
unsigned long SizeValueType
Definition: itkIntTypes.h:83