ITK 6.0.0
Insight Toolkit
 
Loading...
Searching...
No Matches
itkGPUNeighborhoodOperatorImageFilter.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 * https://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 itkGPUNeighborhoodOperatorImageFilter_h
19#define itkGPUNeighborhoodOperatorImageFilter_h
20
21#include "itkGPUImage.h"
25#include "itkImage.h"
28
29namespace itk
30{
42
44itkGPUKernelClassMacro(GPUNeighborhoodOperatorImageFilterKernel);
45
46template <typename TInputImage,
47 typename TOutputImage,
48 typename TOperatorValueType = typename TOutputImage::PixelType,
50class ITK_TEMPLATE_EXPORT GPUNeighborhoodOperatorImageFilter
51 : public GPUImageToImageFilter<TInputImage, TOutputImage, TParentImageFilter>
52{
53public:
54 ITK_DISALLOW_COPY_AND_MOVE(GPUNeighborhoodOperatorImageFilter);
55
58 using CPUSuperclass = TParentImageFilter;
62
64 itkNewMacro(Self);
65
67 itkOverrideGetNameOfClassMacro(GPUNeighborhoodOperatorImageFilter);
68
71 using OutputPixelType = typename TOutputImage::PixelType;
72 using OutputInternalPixelType = typename TOutputImage::InternalPixelType;
73 using InputPixelType = typename TInputImage::PixelType;
74 using InputInternalPixelType = typename TInputImage::InternalPixelType;
75 using OperatorValueType = TOperatorValueType;
76
79
81
83 static constexpr unsigned int ImageDimension = TInputImage::ImageDimension;
84 static constexpr unsigned int InputImageDimension = TInputImage::ImageDimension;
85 static constexpr unsigned int OutputImageDimension = TOutputImage::ImageDimension;
86
88 using InputImageType = TInputImage;
89 using OutputImageType = TOutputImage;
90 using InputImagePointer = typename InputImageType::Pointer;
91
94
97
99 using OutputImageRegionType = typename GPUSuperclass::OutputImageRegionType;
100
103
105 itkGetOpenCLSourceFromKernelMacro(GPUNeighborhoodOperatorImageFilterKernel);
106
110 void
112
116
124
128
137
138 // Begin concept checking
139 // itkConceptMacro( SameDimensionCheck,
140 // ( Concept::SameDimension< InputImageDimension, ImageDimension > ) );
141 // itkConceptMacro( OperatorConvertibleToOutputCheck,
142 // ( Concept::Convertible< OperatorValueType, OutputPixelType > ) );
143 // itkConceptMacro( InputConvertibleToOperatorCheck,
144 // ( Concept::Convertible< InputPixelValueType, OperatorValueType > ) );
145 // itkConceptMacro( OperatorMultiplyOperatorCheck,
146 // ( Concept::MultiplyOperator< OperatorValueType > ) );
147 // itkConceptMacro( OperatorAdditiveOperatorsCheck,
148 // ( Concept::AdditiveOperators< OperatorValueType > ) );
149 // End concept checking
150
151protected:
154
168
169 void
170 GPUGenerateData() override;
171
172 void
173 PrintSelf(std::ostream & os, Indent indent) const override
174 {
175 GPUSuperclass::PrintSelf(os, indent);
176 }
177
178private:
181
185
188
190
192};
193} // end namespace itk
194
195#ifndef ITK_MANUAL_INSTANTIATION
196# include "itkGPUNeighborhoodOperatorImageFilter.hxx"
197#endif
198
199#endif
void PrintSelf(std::ostream &os, Indent indent) const override
Templated n-dimensional image class for the GPU.
Definition itkGPUImage.h:41
SmartPointer< Self > Pointer
Definition itkGPUImage.h:47
typename NumericTraits< InputPixelType >::ValueType InputPixelValueType
void SetOperator(const OutputNeighborhoodType &p)
~GPUNeighborhoodOperatorImageFilter() override=default
typename TOutputImage::InternalPixelType OutputInternalPixelType
Neighborhood< OperatorValueType, Self::ImageDimension > OutputNeighborhoodType
ZeroFluxNeumannBoundaryCondition< InputImageType > DefaultBoundaryCondition
typename NumericTraits< OutputPixelType >::RealType ComputingPixelType
void PrintSelf(std::ostream &os, Indent indent) const override
itkGetOpenCLSourceFromKernelMacro(GPUNeighborhoodOperatorImageFilterKernel)
GPUImage< TOperatorValueType, Self::ImageDimension > NeighborhoodGPUBufferType
ImageBoundaryCondition< InputImageType > * ImageBoundaryConditionPointerType
typename GPUSuperclass::OutputImageRegionType OutputImageRegionType
typename TInputImage::InternalPixelType InputInternalPixelType
GPUImageToImageFilter< TInputImage, TOutputImage, TParentImageFilter > GPUSuperclass
A virtual base object that defines an interface to a class of boundary condition objects for use by n...
Control indentation during Print() invocation.
Definition itkIndent.h:50
Applies a single NeighborhoodOperator to an image region.
A light-weight container object for storing an N-dimensional neighborhood of values.
Implements transparent reference counting.
A function object that determines a neighborhood of values at an image boundary according to a Neuman...
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....
itkGPUKernelClassMacro(GPUImageOpsKernel)