ITK  5.2.0
Insight Toolkit
itkVectorNeighborhoodOperatorImageFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright NumFOCUS
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 itkVectorNeighborhoodOperatorImageFilter_h
19 #define itkVectorNeighborhoodOperatorImageFilter_h
20 
21 #include "itkImageToImageFilter.h"
23 #include "itkImage.h"
25 
26 namespace itk
27 {
57 template <typename TInputImage, typename TOutputImage>
58 class ITK_TEMPLATE_EXPORT VectorNeighborhoodOperatorImageFilter : public ImageToImageFilter<TInputImage, TOutputImage>
59 {
60 public:
61  ITK_DISALLOW_COPY_AND_MOVE(VectorNeighborhoodOperatorImageFilter);
62 
68 
70  itkNewMacro(Self);
71 
74 
77  using InputImagePointer = typename TInputImage::Pointer;
78  using OutputImagePointer = typename TOutputImage::Pointer;
79  using OutputPixelType = typename TOutputImage::PixelType;
80  using OutputInternalPixelType = typename TOutputImage::InternalPixelType;
81  using InputPixelType = typename TInputImage::PixelType;
82  using InputInternalPixelType = typename TInputImage::InternalPixelType;
83  using ScalarValueType = typename OutputPixelType::ValueType;
84 
86  static constexpr unsigned int ImageDimension = TOutputImage::ImageDimension;
87 
89  using InputImageType = TInputImage;
90  using OutputImageType = TOutputImage;
91 
94 
96  using OutputImageRegionType = typename Superclass::OutputImageRegionType;
97 
101  void
103  {
104  m_Operator = p;
105  this->Modified();
106  }
108 
114  void
116  {
117  m_BoundsCondition = i;
118  }
119 
127  void
128  GenerateInputRequestedRegion() override;
129 
130 #ifdef ITK_USE_CONCEPT_CHECKING
131  // Begin concept checking
133  itkConceptMacro(OutputHasNumericTraitsCheck,
135  // End concept checking
136 #endif
137 
138 protected:
140  : m_BoundsCondition(nullptr)
141  {
142  this->DynamicMultiThreadingOn();
143  this->ThreaderUpdateProgressOff();
144  }
145 
146  ~VectorNeighborhoodOperatorImageFilter() override = default;
147 
158  void
159  DynamicThreadedGenerateData(const OutputImageRegionType & outputRegionForThread) override;
160 
161 
162  void
163  PrintSelf(std::ostream & os, Indent indent) const override
164  {
165  Superclass::PrintSelf(os, indent);
166  }
167 
168 private:
171 
175 };
176 } // end namespace itk
177 
178 #ifndef ITK_MANUAL_INSTANTIATION
179 # include "itkVectorNeighborhoodOperatorImageFilter.hxx"
180 #endif
181 
182 #endif
itk::VectorNeighborhoodOperatorImageFilter::InputInternalPixelType
typename TInputImage::InternalPixelType InputInternalPixelType
Definition: itkVectorNeighborhoodOperatorImageFilter.h:82
itk::Concept::HasNumericTraits
Definition: itkConceptChecking.h:714
itk::ImageSource::OutputImagePointer
typename OutputImageType::Pointer OutputImagePointer
Definition: itkImageSource.h:91
itk::VectorNeighborhoodOperatorImageFilter::ScalarValueType
typename OutputPixelType::ValueType ScalarValueType
Definition: itkVectorNeighborhoodOperatorImageFilter.h:83
itk::VectorNeighborhoodOperatorImageFilter::m_BoundsCondition
ImageBoundaryConditionPointerType m_BoundsCondition
Definition: itkVectorNeighborhoodOperatorImageFilter.h:174
itkNeighborhoodOperator.h
itk::VectorNeighborhoodOperatorImageFilter::InputPixelType
typename TInputImage::PixelType InputPixelType
Definition: itkVectorNeighborhoodOperatorImageFilter.h:81
itk::Neighborhood< ScalarValueType, Self::ImageDimension >
itkImage.h
itk::VectorNeighborhoodOperatorImageFilter::OutputInternalPixelType
typename TOutputImage::InternalPixelType OutputInternalPixelType
Definition: itkVectorNeighborhoodOperatorImageFilter.h:80
itk::SmartPointer< Self >
itk::Indent
Control indentation during Print() invocation.
Definition: itkIndent.h:49
itk::ImageBoundaryCondition< OutputImageType >
itk::VectorNeighborhoodOperatorImageFilter::VectorNeighborhoodOperatorImageFilter
VectorNeighborhoodOperatorImageFilter()
Definition: itkVectorNeighborhoodOperatorImageFilter.h:139
itkImageBoundaryCondition.h
itk::ImageToImageFilter
Base class for filters that take an image as input and produce an image as output.
Definition: itkImageToImageFilter.h:108
itk::ImageSource
Base class for all process objects that output image data.
Definition: itkImageSource.h:67
itk::VectorNeighborhoodOperatorImageFilter
Applies a single scalar NeighborhoodOperator to an itk::Vector image region.
Definition: itkVectorNeighborhoodOperatorImageFilter.h:58
itk::VectorNeighborhoodOperatorImageFilter::OverrideBoundaryCondition
void OverrideBoundaryCondition(const ImageBoundaryConditionPointerType i)
Definition: itkVectorNeighborhoodOperatorImageFilter.h:115
itk::ImageToImageFilter::InputImagePointer
typename InputImageType::Pointer InputImagePointer
Definition: itkImageToImageFilter.h:130
itk::VectorNeighborhoodOperatorImageFilter::m_Operator
Neighborhood< ScalarValueType, Self::ImageDimension > m_Operator
Definition: itkVectorNeighborhoodOperatorImageFilter.h:170
itk::ImageToImageFilter::InputImageType
TInputImage InputImageType
Definition: itkImageToImageFilter.h:129
itkImageToImageFilter.h
itk::VectorNeighborhoodOperatorImageFilter::PrintSelf
void PrintSelf(std::ostream &os, Indent indent) const override
Definition: itkVectorNeighborhoodOperatorImageFilter.h:163
itk::ImageSource::OutputImageRegionType
typename OutputImageType::RegionType OutputImageRegionType
Definition: itkImageSource.h:92
itkConceptMacro
#define itkConceptMacro(name, concept)
Definition: itkConceptChecking.h:65
itk
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....
Definition: itkAnnulusOperator.h:24
itk::VectorNeighborhoodOperatorImageFilter::SetOperator
void SetOperator(const Neighborhood< ScalarValueType, Self::ImageDimension > &p)
Definition: itkVectorNeighborhoodOperatorImageFilter.h:102
itk::ProcessObject
The base class for all process objects (source, filters, mappers) in the Insight data processing pipe...
Definition: itkProcessObject.h:138
itk::ImageSource::OutputImageType
TOutputImage OutputImageType
Definition: itkImageSource.h:90
itk::VectorNeighborhoodOperatorImageFilter::OutputPixelType
typename TOutputImage::PixelType OutputPixelType
Definition: itkVectorNeighborhoodOperatorImageFilter.h:79