#include <itkGridForwardWarpImageFilter.h>
Warps a grid using an input deformation field.
GridForwardWarpImageFilter warps a grid with respect to a given deformation field.
A displacement field is represented as a image whose pixel type is some vector type with at least N elements, where N is the dimension of the input image. The vector type must support element access via operator [].
The output image is produced by forward mapping.
Each vector in the displacement field represent the distance between a geometric point in the input space and a point in the output space such that:
\[ p_{in} = p_{out} + d \]
Typically the mapped position does not correspond to an integer pixel position in the output image. We round it.
Warning: the functionality provided by this class is currently implemented with more options and multi-threaded in itk::GridImageSource by setting up an appropriate itk::ResampleImageFilter instance to such an object.
This implementation was taken from the Insight Journal paper: https://doi.org/10.54294/ux2obj
Definition at line 59 of file itkGridForwardWarpImageFilter.h.
Inheritance diagram for itk::GridForwardWarpImageFilter< TDisplacementField, TOutputImage >:
Collaboration diagram for itk::GridForwardWarpImageFilter< TDisplacementField, TOutputImage >:Static Public Member Functions | |
| static Pointer | New () |
Static Public Member Functions inherited from itk::ImageToImageFilter< TDisplacementField, TOutputImage > | |
| static double | GetGlobalDefaultCoordinateTolerance () |
| static double | GetGlobalDefaultCoordinateTolerance () |
| static double | GetGlobalDefaultDirectionTolerance () |
| static double | GetGlobalDefaultDirectionTolerance () |
| static void | SetGlobalDefaultCoordinateTolerance (double) |
| static void | SetGlobalDefaultCoordinateTolerance (double) |
| static void | SetGlobalDefaultDirectionTolerance (double) |
| static void | SetGlobalDefaultDirectionTolerance (double) |
Static Public Member Functions inherited from itk::Object | |
| static bool | GetGlobalWarningDisplay () |
| static void | GlobalWarningDisplayOff () |
| static void | GlobalWarningDisplayOn () |
| static Pointer | New () |
| static void | SetGlobalWarningDisplay (bool val) |
Static Public Member Functions inherited from itk::LightObject | |
| static void | BreakOnError () |
| static Pointer | New () |
Static Public Attributes | |
| static constexpr unsigned int | DisplacementFieldDimension = TDisplacementField::ImageDimension |
| static constexpr unsigned int | ImageDimension = TOutputImage::ImageDimension |
Static Public Attributes inherited from itk::ImageToImageFilter< TDisplacementField, TOutputImage > | |
| static constexpr unsigned int | InputImageDimension |
| static constexpr unsigned int | InputImageDimension |
| static constexpr unsigned int | OutputImageDimension |
| static constexpr unsigned int | OutputImageDimension |
Static Public Attributes inherited from itk::ImageSource< TOutputImage > | |
| static constexpr unsigned int | OutputImageDimension = TOutputImage::ImageDimension |
Private Attributes | |
| PixelType | m_BackgroundValue {} |
| PixelType | m_ForegroundValue {} |
| unsigned int | m_GridPixSpacing { 5 } |
Additional Inherited Members | |
Protected Types inherited from itk::ImageToImageFilter< TDisplacementField, TOutputImage > | |
| using | InputToOutputRegionCopierType |
| using | OutputToInputRegionCopierType |
Static Protected Member Functions inherited from itk::ImageSource< TOutputImage > | |
| static const ImageRegionSplitterBase * | GetGlobalDefaultSplitter () |
| static ITK_THREAD_RETURN_FUNCTION_CALL_CONVENTION | ThreaderCallback (void *arg) |
Static Protected Member Functions inherited from itk::ProcessObject | |
| template<typename TSourceObject> | |
| static void | MakeRequiredOutputs (TSourceObject &sourceObject, const DataObjectPointerArraySizeType numberOfRequiredOutputs) |
| static constexpr float | progressFixedToFloat (uint32_t fixed) |
| static uint32_t | progressFloatToFixed (float f) |
Protected Attributes inherited from itk::ImageSource< TOutputImage > | |
| bool | m_DynamicMultiThreading { true } |
Protected Attributes inherited from itk::ProcessObject | |
| TimeStamp | m_OutputInformationMTime {} |
| bool | m_Updating {} |
Protected Attributes inherited from itk::LightObject | |
| std::atomic< int > | m_ReferenceCount {} |
| using itk::GridForwardWarpImageFilter< TDisplacementField, TOutputImage >::ConstPointer = SmartPointer<const Self> |
Definition at line 68 of file itkGridForwardWarpImageFilter.h.
| using itk::GridForwardWarpImageFilter< TDisplacementField, TOutputImage >::DisplacementFieldConstPointer = typename DisplacementFieldType::ConstPointer |
Definition at line 93 of file itkGridForwardWarpImageFilter.h.
| using itk::GridForwardWarpImageFilter< TDisplacementField, TOutputImage >::DisplacementFieldType = TDisplacementField |
Deformation field type alias support
Definition at line 92 of file itkGridForwardWarpImageFilter.h.
| using itk::GridForwardWarpImageFilter< TDisplacementField, TOutputImage >::DisplacementType = typename DisplacementFieldType::PixelType |
Definition at line 94 of file itkGridForwardWarpImageFilter.h.
| using itk::GridForwardWarpImageFilter< TDisplacementField, TOutputImage >::IndexType = typename OutputImageType::IndexType |
Definition at line 82 of file itkGridForwardWarpImageFilter.h.
| using itk::GridForwardWarpImageFilter< TDisplacementField, TOutputImage >::OutputImageRegionType = typename TOutputImage::RegionType |
Typedef to describe the output image region type.
Definition at line 77 of file itkGridForwardWarpImageFilter.h.
| using itk::GridForwardWarpImageFilter< TDisplacementField, TOutputImage >::PixelType = typename OutputImageType::PixelType |
Definition at line 84 of file itkGridForwardWarpImageFilter.h.
| using itk::GridForwardWarpImageFilter< TDisplacementField, TOutputImage >::Pointer = SmartPointer<Self> |
Definition at line 67 of file itkGridForwardWarpImageFilter.h.
| using itk::GridForwardWarpImageFilter< TDisplacementField, TOutputImage >::Self = GridForwardWarpImageFilter |
Standard class type aliases.
Definition at line 65 of file itkGridForwardWarpImageFilter.h.
| using itk::GridForwardWarpImageFilter< TDisplacementField, TOutputImage >::SizeType = typename OutputImageType::SizeType |
Definition at line 83 of file itkGridForwardWarpImageFilter.h.
| using itk::GridForwardWarpImageFilter< TDisplacementField, TOutputImage >::SpacingType = typename OutputImageType::SpacingType |
Definition at line 85 of file itkGridForwardWarpImageFilter.h.
| using itk::GridForwardWarpImageFilter< TDisplacementField, TOutputImage >::Superclass = ImageToImageFilter<TDisplacementField, TOutputImage> |
Definition at line 66 of file itkGridForwardWarpImageFilter.h.
|
protected |
Referenced by GetNameOfClass().
|
overrideprotecteddefault |
|
virtual |
Create an object from an instance, potentially deferring to a factory. This method allows you to create an instance of an object that is exactly the same type as the referring object. This is useful in cases where an object has been cast back to a base class.
Reimplemented from itk::LightObject.
|
overrideprotectedvirtual |
This method causes the filter to generate its output.
Reimplemented from itk::ProcessObject.
|
virtual |
Get the background value
|
virtual |
Get the foreground value
References DisplacementFieldDimension, and ImageDimension.
|
virtual |
Reimplemented from itk::ImageToImageFilter< TDisplacementField, TOutputImage >.
References GridForwardWarpImageFilter().
|
static |
Method for creation through the object factory.
|
overrideprotectedvirtual |
Methods invoked by Print() to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.
Reimplemented from itk::LightObject.
|
virtual |
Set the background value
|
virtual |
Set the foreground value
|
staticconstexpr |
Definition at line 89 of file itkGridForwardWarpImageFilter.h.
Referenced by GetForegroundValue().
|
staticconstexpr |
Determine the image dimension.
Definition at line 88 of file itkGridForwardWarpImageFilter.h.
Referenced by GetForegroundValue().
|
private |
Definition at line 123 of file itkGridForwardWarpImageFilter.h.
|
private |
Definition at line 124 of file itkGridForwardWarpImageFilter.h.
|
private |
Definition at line 125 of file itkGridForwardWarpImageFilter.h.