ITK  5.0.0
Insight Segmentation and Registration Toolkit
itkMiniPipelineSeparableImageFilter.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 itkMiniPipelineSeparableImageFilter_h
19 #define itkMiniPipelineSeparableImageFilter_h
20 
21 #include "itkBoxImageFilter.h"
22 
23 namespace itk
24 {
49 template< typename TInputImage, typename TOutputImage, typename TFilter >
50 class ITK_TEMPLATE_EXPORT MiniPipelineSeparableImageFilter:
51  public BoxImageFilter< TInputImage, TOutputImage >
52 {
53 public:
54  ITK_DISALLOW_COPY_AND_ASSIGN(MiniPipelineSeparableImageFilter);
55 
61 
63  itkNewMacro(Self);
64 
68 
70  using InputImageType = TInputImage;
72  using SizeType = typename TInputImage::SizeType;
74  using PixelType = typename TInputImage::PixelType;
75  using OffsetType = typename TInputImage::OffsetType;
76 
77  using OutputImageType = TOutputImage;
78  using OutputPixelType = typename TOutputImage::PixelType;
79 
80  using FilterType = TFilter;
82 
84  static constexpr unsigned int ImageDimension = TInputImage::ImageDimension;
85 
88 
89  void SetRadius(const RadiusType &) override;
90 
91  void SetRadius(const SizeValueType & radius) override
92  {
93  // needed because of the overloading of the method
94  Superclass::SetRadius(radius);
95  }
96 
97  void Modified() const override;
98 
99  void SetNumberOfWorkUnits(ThreadIdType nb) override;
100 
101 protected:
104 
105  void GenerateData() override;
106 
107  typename FilterType::Pointer m_Filters[ImageDimension];
109 };
110 }
111 
112 #ifndef ITK_MANUAL_INSTANTIATION
113 #include "itkMiniPipelineSeparableImageFilter.hxx"
114 #endif
115 
116 #endif
typename TInputImage::SizeType RadiusType
unsigned long SizeValueType
Definition: itkIntTypes.h:83
Rank filter of a greyscale image.
typename TInputImage::IndexType IndexType
typename TOutputImage::PixelType OutputPixelType
typename TInputImage::RegionType RegionType
The base class for all process objects (source, filters, mappers) in the Insight data processing pipe...
Base class for all process objects that output image data.
void SetRadius(const SizeValueType &radius) override
typename TInputImage::OffsetType OffsetType
typename TInputImage::SizeType SizeType
TOutputImage OutputImageType
A base class for all the filters working on a box neighborhood.
unsigned int ThreadIdType
Definition: itkIntTypes.h:99
A separable filter for filter which are using radius.
Casts input pixels to output pixel type.