go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
itkGPUMatrixOffsetTransformBase.h
Go to the documentation of this file.
1/*=========================================================================
2 *
3 * Copyright UMC Utrecht and contributors
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 __itkGPUMatrixOffsetTransformBase_h
19#define __itkGPUMatrixOffsetTransformBase_h
20
21#include "itkGPUTransformBase.h"
22#include "itkMatrix.h"
23
24namespace itk
25{
27itkGPUKernelClassMacro( GPUMatrixOffsetTransformBaseKernel );
28
40template<
41typename TScalarType = float, // Data type for scalars
42unsigned int NInputDimensions = 3, // Number of dimensions in the input space
43unsigned int NOutputDimensions = 3 >
44// Number of dimensions in the output space
46{
47public:
48
52
55
57 bool IsMatrixOffsetTransform( void ) const override { return true; }
58
61
63 itkStaticConstMacro( InputSpaceDimension, unsigned int, NInputDimensions );
64 itkStaticConstMacro( OutputSpaceDimension, unsigned int, NOutputDimensions );
65 itkStaticConstMacro( ParametersDimension, unsigned int, NOutputDimensions * ( NInputDimensions + 1 ) );
66
68 typedef Matrix< TScalarType, itkGetStaticConstMacro( OutputSpaceDimension ),
69 itkGetStaticConstMacro( InputSpaceDimension ) > CPUMatrixType;
70 typedef Matrix< TScalarType, itkGetStaticConstMacro( InputSpaceDimension ),
71 itkGetStaticConstMacro( OutputSpaceDimension ) > CPUInverseMatrixType;
72 typedef Vector< TScalarType,
73 itkGetStaticConstMacro( OutputSpaceDimension ) > CPUOutputVectorType;
74
76 virtual const CPUMatrixType & GetCPUMatrix( void ) const = 0;
77
79 virtual const CPUInverseMatrixType & GetCPUInverseMatrix( void ) const = 0;
80
82 virtual const CPUOutputVectorType & GetCPUOffset( void ) const = 0;
83
84protected:
85
88
91 bool GetSourceCode( std::string & source ) const override;
92
95
96private:
97
98 GPUMatrixOffsetTransformBase( const Self & other ); // purposely not implemented
99 const Self & operator=( const Self & ); // purposely not implemented
100
101 std::vector< std::string > m_Sources;
102};
103
104} // end namespace itk
105
106#ifndef ITK_MANUAL_INSTANTIATION
107#include "itkGPUMatrixOffsetTransformBase.hxx"
108#endif
109
110#endif /* itkGPUMatrixOffsetTransformBase_h */
Base version of the GPU MatrixOffsetTransform.
Matrix< TScalarType, itkGetStaticConstMacro(InputSpaceDimension), itkGetStaticConstMacro(OutputSpaceDimension) > CPUInverseMatrixType
itkStaticConstMacro(InputSpaceDimension, unsigned int, NInputDimensions)
virtual const CPUMatrixType & GetCPUMatrix(void) const =0
const Self & operator=(const Self &)
virtual const CPUOutputVectorType & GetCPUOffset(void) const =0
itkStaticConstMacro(ParametersDimension, unsigned int, NOutputDimensions *(NInputDimensions+1))
bool GetSourceCode(std::string &source) const override
Vector< TScalarType, itkGetStaticConstMacro(OutputSpaceDimension) > CPUOutputVectorType
GPUMatrixOffsetTransformBase(const Self &other)
itkStaticConstMacro(OutputSpaceDimension, unsigned int, NOutputDimensions)
Matrix< TScalarType, itkGetStaticConstMacro(OutputSpaceDimension), itkGetStaticConstMacro(InputSpaceDimension) > CPUMatrixType
GPUDataManager::Pointer GetParametersDataManager(void) const override
virtual const CPUInverseMatrixType & GetCPUInverseMatrix(void) const =0
Base class for all GPU transforms.
itkGPUKernelClassMacro(GPUBSplineTransformKernel)


Generated on 1667476801 for elastix by doxygen 1.9.4 elastix logo