go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep > Class Template Reference

#include <itkGPUInterpolatorCopier.h>

Detailed Description

template<typename TTypeList, typename NDimensions, typename TInterpolator, typename TOutputCoordRep>
class itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >

A helper class which creates an GPU interpolator which is perfect copy of the CPU interpolator.

This class is NOT a filter. Although it has an API similar to a filter, this class is not intended to be used in a pipeline. Instead, the typical use will be like it is illustrated in the following code:

struct OCLImageDims
{
itkStaticConstMacro( Support1D, bool, true );
itkStaticConstMacro( Support2D, bool, true );
itkStaticConstMacro( Support3D, bool, true );
};
using ImageType = itk::Image< short, 3 >;
using OCLImageTypes = typelist::MakeTypeList< short, float >::Type;
using InterpolatorType = itk::InterpolateImageFunction< ImageType, float >;
auto copier = CopierType::New();
copier->SetInputInterpolator(CPUInterpolator);
copier->Update();
TransformType::Pointer GPUInterpolator = copier->GetModifiableOutput();
A helper class which creates an GPU interpolator which is perfect copy of the CPU interpolator.

Note that the Update() method must be called explicitly in the filter that provides the input to the GPUInterpolatorCopier object. This is needed because the GPUInterpolatorCopier is not a pipeline filter.

Author
Denis P. Shamonin and Marius Staring. Division of Image Processing, Department of Radiology, Leiden, The Netherlands
Note
This work was funded by the Netherlands Organisation for Scientific Research (NWO NRG-2010.02 and NWO 639.021.124).

Definition at line 65 of file itkGPUInterpolatorCopier.h.

Inheritance diagram for itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >:

Public Types

using ConstPointer = SmartPointer<const Self>
 
using CPUCoordRepType = typename CPUInterpolatorType::CoordRepType
 
using CPUInputImagePixelType = typename CPUInputImageType::PixelType
 
using CPUInputImageType = typename CPUInterpolatorType::InputImageType
 
using CPUInterpolatorConstPointer = typename CPUInterpolatorType::ConstPointer
 
using CPUInterpolatorType = TInterpolator
 
using GPUCoordRepType = TOutputCoordRep
 
using GPUExplicitInterpolatorConstPointer = typename GPUExplicitInterpolatorType::ConstPointer
 
using GPUExplicitInterpolatorPointer = typename GPUExplicitInterpolatorType::Pointer
 
using GPUExplicitInterpolatorType = InterpolateImageFunction<GPUInputImageType, GPUCoordRepType>
 
using GPUInputImageType = itk::GPUImage<CPUInputImagePixelType, CPUInputImageType::ImageDimension>
 
using GPUInterpolatorConstPointer = typename GPUInterpolatorType::ConstPointer
 
using GPUInterpolatorPointer = typename GPUInterpolatorType::Pointer
 
using GPUInterpolatorType = InterpolateImageFunction<CPUInputImageType, GPUCoordRepType>
 
using Pointer = SmartPointer<Self>
 
using Self = GPUInterpolatorCopier
 
using Superclass = Object
 

Public Member Functions

virtual const char * GetClassName () const
 
virtual bool GetExplicitMode () const
 
 ITK_DISALLOW_COPY_AND_MOVE (GPUInterpolatorCopier)
 
 itkGetModifiableObjectMacro (ExplicitOutput, GPUExplicitInterpolatorType)
 
 itkGetModifiableObjectMacro (Output, GPUInterpolatorType)
 
virtual void SetExplicitMode (bool _arg)
 
virtual void SetInputInterpolator (const CPUInterpolatorType *_arg)
 
void Update ()
 

Static Public Member Functions

static Pointer New ()
 

Protected Member Functions

 GPUInterpolatorCopier ()
 
void PrintSelf (std::ostream &os, Indent indent) const override
 
 ~GPUInterpolatorCopier () override=default
 

Private Attributes

bool m_ExplicitMode {}
 
GPUExplicitInterpolatorPointer m_ExplicitOutput {}
 
CPUInterpolatorConstPointer m_InputInterpolator {}
 
ModifiedTimeType m_InternalTransformTime {}
 
GPUInterpolatorPointer m_Output {}
 

Member Typedef Documentation

◆ ConstPointer

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
using itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::ConstPointer = SmartPointer<const Self>

Definition at line 74 of file itkGPUInterpolatorCopier.h.

◆ CPUCoordRepType

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
using itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::CPUCoordRepType = typename CPUInterpolatorType::CoordRepType

Definition at line 86 of file itkGPUInterpolatorCopier.h.

◆ CPUInputImagePixelType

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
using itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::CPUInputImagePixelType = typename CPUInputImageType::PixelType

Typedef's for explicit GPU interpolator definitions.

Definition at line 95 of file itkGPUInterpolatorCopier.h.

◆ CPUInputImageType

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
using itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::CPUInputImageType = typename CPUInterpolatorType::InputImageType

Definition at line 85 of file itkGPUInterpolatorCopier.h.

◆ CPUInterpolatorConstPointer

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
using itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::CPUInterpolatorConstPointer = typename CPUInterpolatorType::ConstPointer

Definition at line 84 of file itkGPUInterpolatorCopier.h.

◆ CPUInterpolatorType

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
using itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::CPUInterpolatorType = TInterpolator

Type CPU definitions for the interpolator.

Definition at line 83 of file itkGPUInterpolatorCopier.h.

◆ GPUCoordRepType

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
using itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::GPUCoordRepType = TOutputCoordRep

Definition at line 87 of file itkGPUInterpolatorCopier.h.

◆ GPUExplicitInterpolatorConstPointer

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
using itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::GPUExplicitInterpolatorConstPointer = typename GPUExplicitInterpolatorType::ConstPointer

Definition at line 99 of file itkGPUInterpolatorCopier.h.

◆ GPUExplicitInterpolatorPointer

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
using itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::GPUExplicitInterpolatorPointer = typename GPUExplicitInterpolatorType::Pointer

Definition at line 98 of file itkGPUInterpolatorCopier.h.

◆ GPUExplicitInterpolatorType

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
using itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::GPUExplicitInterpolatorType = InterpolateImageFunction<GPUInputImageType, GPUCoordRepType>

Definition at line 97 of file itkGPUInterpolatorCopier.h.

◆ GPUInputImageType

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
using itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::GPUInputImageType = itk::GPUImage<CPUInputImagePixelType, CPUInputImageType::ImageDimension>

Definition at line 96 of file itkGPUInterpolatorCopier.h.

◆ GPUInterpolatorConstPointer

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
using itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::GPUInterpolatorConstPointer = typename GPUInterpolatorType::ConstPointer

Definition at line 92 of file itkGPUInterpolatorCopier.h.

◆ GPUInterpolatorPointer

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
using itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::GPUInterpolatorPointer = typename GPUInterpolatorType::Pointer

Definition at line 91 of file itkGPUInterpolatorCopier.h.

◆ GPUInterpolatorType

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
using itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::GPUInterpolatorType = InterpolateImageFunction<CPUInputImageType, GPUCoordRepType>

Typedef's for non explicit GPU interpolator definitions.

Definition at line 90 of file itkGPUInterpolatorCopier.h.

◆ Pointer

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
using itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::Pointer = SmartPointer<Self>

Definition at line 73 of file itkGPUInterpolatorCopier.h.

◆ Self

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
using itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::Self = GPUInterpolatorCopier

Standard class typedefs.

Definition at line 71 of file itkGPUInterpolatorCopier.h.

◆ Superclass

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
using itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::Superclass = Object

Definition at line 72 of file itkGPUInterpolatorCopier.h.

Constructor & Destructor Documentation

◆ GPUInterpolatorCopier()

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::GPUInterpolatorCopier ( )
protected

◆ ~GPUInterpolatorCopier()

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::~GPUInterpolatorCopier ( )
overrideprotecteddefault

Member Function Documentation

◆ GetClassName()

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
virtual const char * itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::GetClassName ( ) const
virtual

Run-time type information (and related methods).

◆ GetExplicitMode()

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
virtual bool itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::GetExplicitMode ( ) const
virtual

Get/Set the explicit mode. The default is true. If the explicit mode has been set to false that means that early in the code the factories has been created. ObjectFactoryBase::RegisterFactory( GPUNearestNeighborInterpolateImageFunctionFactory::New() ); ObjectFactoryBase::RegisterFactory( GPULinearInterpolateImageFunctionFactory::New() ); ObjectFactoryBase::RegisterFactory( GPUBSplineInterpolateImageFunctionFactory::New() );

◆ ITK_DISALLOW_COPY_AND_MOVE()

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::ITK_DISALLOW_COPY_AND_MOVE ( GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep > )

◆ itkGetModifiableObjectMacro() [1/2]

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::itkGetModifiableObjectMacro ( ExplicitOutput ,
GPUExplicitInterpolatorType  )

Compute of the explicit output interpolator. This output should be used when ExplicitMode has been set to true.

◆ itkGetModifiableObjectMacro() [2/2]

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::itkGetModifiableObjectMacro ( Output ,
GPUInterpolatorType  )

Compute of the non explicit output interpolator.

◆ New()

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
static Pointer itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::New ( )
static

Method for creation through the object factory.

◆ PrintSelf()

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
void itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::PrintSelf ( std::ostream & os,
Indent indent ) const
overrideprotected

◆ SetExplicitMode()

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
virtual void itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::SetExplicitMode ( bool _arg)
virtual

◆ SetInputInterpolator()

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
virtual void itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::SetInputInterpolator ( const CPUInterpolatorType * _arg)
virtual

Get/Set the input interpolator.

◆ Update()

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
void itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::Update ( )

Update method.

Field Documentation

◆ m_ExplicitMode

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
bool itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::m_ExplicitMode {}
private

Definition at line 141 of file itkGPUInterpolatorCopier.h.

◆ m_ExplicitOutput

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
GPUExplicitInterpolatorPointer itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::m_ExplicitOutput {}
private

Definition at line 139 of file itkGPUInterpolatorCopier.h.

◆ m_InputInterpolator

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
CPUInterpolatorConstPointer itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::m_InputInterpolator {}
private

Definition at line 137 of file itkGPUInterpolatorCopier.h.

◆ m_InternalTransformTime

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
ModifiedTimeType itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::m_InternalTransformTime {}
private

Definition at line 140 of file itkGPUInterpolatorCopier.h.

◆ m_Output

template<typename TTypeList , typename NDimensions , typename TInterpolator , typename TOutputCoordRep >
GPUInterpolatorPointer itk::GPUInterpolatorCopier< TTypeList, NDimensions, TInterpolator, TOutputCoordRep >::m_Output {}
private

Definition at line 138 of file itkGPUInterpolatorCopier.h.



Generated on 2024-07-17 for elastix by doxygen 1.11.0 (9b424b03c9833626cd435af22a444888fbbb192d) elastix logo