go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Member Functions
itk::NDImageBase< TPixel > Class Template Referenceabstract

#include <itkNDImageBase.h>

Detailed Description

template<class TPixel>
class itk::NDImageBase< TPixel >

An image whose dimension can be specified at runtime.

The NDImageBase class is needed for the FullSearch optimizer. It allows run-time construction of an N-dimensional image. It has most of the functionality of a normal itk::Image.

Todo:
not all! An internal writer and reader are included for convenience.

The NewNDImage function defines the dimension of the image. CreateNewImage creates an instance of an itk::Image, with dimension as specified by NewNDImage. Note: the NewNDImage does not return an itk::Image, but an elx::NDImageTemplate.

Suggested way of using this class:
NDImageBase<short> var1 = NDImageBase::NewNDImage(3);
var1->CreateNewImage();
The result is similar as:
itk::Image<short,3>::Pointer var1 = itk::Image<short,3>::New();
except that the actual itk::Image is stored as member variable in the NDImageTemplate.

See also
FullSearchOptimizer, NDImageTemplate

Definition at line 58 of file itkNDImageBase.h.

+ Inheritance diagram for itk::NDImageBase< TPixel >:

Public Types

typedef Image< TPixel, 2 >::AccessorType AccessorType
 
typedef SmartPointer< const SelfConstPointer
 
typedef DataObjectType::Pointer DataObjectPointer
 
typedef DataObject DataObjectType
 
typedef Array< IndexValueTypeIndexType
 
typedef ImageBase< 2 >::IndexValueType IndexValueType
 
typedef Image< TPixel, 2 >::InternalPixelType InternalPixelType
 
typedef Array< OffsetValueTypeOffsetType
 
typedef ImageBase< 2 >::OffsetValueType OffsetValueType
 
typedef Image< TPixel, 2 >::PixelContainer PixelContainer
 
typedef Image< TPixel, 2 >::PixelContainerConstPointer PixelContainerConstPointer
 
typedef Image< TPixel, 2 >::PixelContainerPointer PixelContainerPointer
 
typedef ImageBase< 2 >::PointType Point2DType
 
typedef SmartPointer< SelfPointer
 
typedef Array< PointValueTypePointType
 
typedef Point2DType::ValueType PointValueType
 
typedef NDImageBase Self
 
typedef Array< SizeValueTypeSizeType
 
typedef ImageBase< 2 >::SizeValueType SizeValueType
 
typedef ImageBase< 2 >::SpacingType Spacing2DType
 
typedef Array< SpacingValueTypeSpacingType
 
typedef Spacing2DType::ValueType SpacingValueType
 
typedef Object Superclass
 
typedef Image< TPixel, 2 >::ValueType ValueType
 

Public Member Functions

virtual void Allocate (void)=0
 
virtual IndexType ComputeIndex (OffsetValueType offset) const =0
 
virtual OffsetValueType ComputeOffset (const IndexType &ind) const =0
 
virtual void CopyInformation (const DataObject *data)=0
 
virtual void CreateNewImage (void)=0
 
virtual void FillBuffer (const TPixel &value)=0
 
virtual const TPixel * GetBufferPointer () const =0
 
virtual TPixel * GetBufferPointer ()=0
 
virtual const char * GetClassName () const
 
virtual unsigned int GetImageDimension (void)=0
 
virtual ImageIOBaseGetImageIOReader (void)=0
 
virtual ImageIOBaseGetImageIOWriter (void)=0
 
virtual const char * GetInputFileName (void)=0
 
virtual const OffsetValueTypeGetOffsetTable () const =0
 
virtual PointType GetOrigin (void)=0
 
virtual const char * GetOutputFileName (void)=0
 
virtual const TPixel & GetPixel (const IndexType &index) const =0
 
virtual TPixel & GetPixel (const IndexType &index)=0
 
virtual const AccessorType GetPixelAccessor (void) const =0
 
virtual AccessorType GetPixelAccessor (void)=0
 
virtual const PixelContainerGetPixelContainer () const =0
 
virtual PixelContainerGetPixelContainer ()=0
 
virtual SpacingType GetSpacing (void)=0
 
virtual unsigned int ImageDimension (void)=0
 
virtual void Initialize (void)=0
 
TPixel & operator[] (const IndexType &index)
 
const TPixel & operator[] (const IndexType &index) const
 
virtual void Read (void)=0
 
virtual void SetImageIOReader (ImageIOBase *_arg)=0
 
virtual void SetImageIOWriter (ImageIOBase *_arg)=0
 
virtual void SetInputFileName (const char *)=0
 
virtual void SetOrigin (const PointType &origin)=0
 
virtual void SetOutputFileName (const char *)=0
 
virtual void SetPixel (const IndexType &index, const TPixel &value)=0
 
virtual void SetPixelContainer (PixelContainer *container)=0
 
virtual void SetRegions (SizeType size)=0
 
virtual void SetRequestedRegion (DataObject *data)=0
 
virtual void SetSpacing (const SpacingType &spacing)=0
 
virtual void Write (void)=0
 

Static Public Member Functions

static Pointer NewNDImage (unsigned int dim)
 

Protected Member Functions

 NDImageBase ()
 
 ~NDImageBase () override
 

Private Member Functions

 NDImageBase (const Self &)
 
void operator= (const Self &)
 

Member Typedef Documentation

◆ AccessorType

template<class TPixel >
typedef Image<TPixel,2>::AccessorType itk::NDImageBase< TPixel >::AccessorType

Definition at line 83 of file itkNDImageBase.h.

◆ ConstPointer

template<class TPixel >
typedef SmartPointer< const Self > itk::NDImageBase< TPixel >::ConstPointer

Definition at line 66 of file itkNDImageBase.h.

◆ DataObjectPointer

template<class TPixel >
typedef DataObjectType::Pointer itk::NDImageBase< TPixel >::DataObjectPointer

Definition at line 77 of file itkNDImageBase.h.

◆ DataObjectType

template<class TPixel >
typedef DataObject itk::NDImageBase< TPixel >::DataObjectType

Definition at line 76 of file itkNDImageBase.h.

◆ IndexType

template<class TPixel >
typedef Array< IndexValueType > itk::NDImageBase< TPixel >::IndexType

ND versions of the index and sizetypes. Unlike in their counterparts in the itk::Image, their size can be defined at runtime. The elx::NDImageTemplate takes care of converting from/to these types to to/from the corresponding types in itk::Image.

Definition at line 102 of file itkNDImageBase.h.

◆ IndexValueType

template<class TPixel >
typedef ImageBase<2>::IndexValueType itk::NDImageBase< TPixel >::IndexValueType

Definition at line 93 of file itkNDImageBase.h.

◆ InternalPixelType

template<class TPixel >
typedef Image<TPixel,2>::InternalPixelType itk::NDImageBase< TPixel >::InternalPixelType

Definition at line 82 of file itkNDImageBase.h.

◆ OffsetType

template<class TPixel >
typedef Array< OffsetValueType > itk::NDImageBase< TPixel >::OffsetType

Definition at line 106 of file itkNDImageBase.h.

◆ OffsetValueType

template<class TPixel >
typedef ImageBase<2>::OffsetValueType itk::NDImageBase< TPixel >::OffsetValueType

Definition at line 95 of file itkNDImageBase.h.

◆ PixelContainer

template<class TPixel >
typedef Image<TPixel,2>::PixelContainer itk::NDImageBase< TPixel >::PixelContainer

Definition at line 84 of file itkNDImageBase.h.

◆ PixelContainerConstPointer

template<class TPixel >
typedef Image<TPixel,2>::PixelContainerConstPointer itk::NDImageBase< TPixel >::PixelContainerConstPointer

Definition at line 86 of file itkNDImageBase.h.

◆ PixelContainerPointer

template<class TPixel >
typedef Image<TPixel,2>::PixelContainerPointer itk::NDImageBase< TPixel >::PixelContainerPointer

Definition at line 85 of file itkNDImageBase.h.

◆ Point2DType

template<class TPixel >
typedef ImageBase<2>::PointType itk::NDImageBase< TPixel >::Point2DType

Definition at line 89 of file itkNDImageBase.h.

◆ Pointer

template<class TPixel >
typedef SmartPointer< Self > itk::NDImageBase< TPixel >::Pointer

Definition at line 65 of file itkNDImageBase.h.

◆ PointType

template<class TPixel >
typedef Array< PointValueType > itk::NDImageBase< TPixel >::PointType

Definition at line 105 of file itkNDImageBase.h.

◆ PointValueType

template<class TPixel >
typedef Point2DType::ValueType itk::NDImageBase< TPixel >::PointValueType

Definition at line 92 of file itkNDImageBase.h.

◆ Self

template<class TPixel >
typedef NDImageBase itk::NDImageBase< TPixel >::Self

Standard class typedefs.

Definition at line 63 of file itkNDImageBase.h.

◆ SizeType

template<class TPixel >
typedef Array< SizeValueType > itk::NDImageBase< TPixel >::SizeType

Definition at line 103 of file itkNDImageBase.h.

◆ SizeValueType

template<class TPixel >
typedef ImageBase<2>::SizeValueType itk::NDImageBase< TPixel >::SizeValueType

Definition at line 94 of file itkNDImageBase.h.

◆ Spacing2DType

template<class TPixel >
typedef ImageBase<2>::SpacingType itk::NDImageBase< TPixel >::Spacing2DType

Definition at line 88 of file itkNDImageBase.h.

◆ SpacingType

template<class TPixel >
typedef Array< SpacingValueType > itk::NDImageBase< TPixel >::SpacingType

Definition at line 104 of file itkNDImageBase.h.

◆ SpacingValueType

template<class TPixel >
typedef Spacing2DType::ValueType itk::NDImageBase< TPixel >::SpacingValueType

Definition at line 91 of file itkNDImageBase.h.

◆ Superclass

template<class TPixel >
typedef Object itk::NDImageBase< TPixel >::Superclass

Definition at line 64 of file itkNDImageBase.h.

◆ ValueType

template<class TPixel >
typedef Image<TPixel,2>::ValueType itk::NDImageBase< TPixel >::ValueType

Definition at line 81 of file itkNDImageBase.h.

Constructor & Destructor Documentation

◆ NDImageBase() [1/2]

template<class TPixel >
itk::NDImageBase< TPixel >::NDImageBase ( )
inlineprotected

Definition at line 214 of file itkNDImageBase.h.

◆ ~NDImageBase()

template<class TPixel >
itk::NDImageBase< TPixel >::~NDImageBase ( )
inlineoverrideprotected

Definition at line 215 of file itkNDImageBase.h.

◆ NDImageBase() [2/2]

template<class TPixel >
itk::NDImageBase< TPixel >::NDImageBase ( const Self )
private

Member Function Documentation

◆ Allocate()

template<class TPixel >
virtual void itk::NDImageBase< TPixel >::Allocate ( void  )
pure virtual

◆ ComputeIndex()

template<class TPixel >
virtual IndexType itk::NDImageBase< TPixel >::ComputeIndex ( OffsetValueType  offset) const
pure virtual

◆ ComputeOffset()

template<class TPixel >
virtual OffsetValueType itk::NDImageBase< TPixel >::ComputeOffset ( const IndexType ind) const
pure virtual

◆ CopyInformation()

template<class TPixel >
virtual void itk::NDImageBase< TPixel >::CopyInformation ( const DataObject *  data)
pure virtual
Todo:
Transform IndexToPoint methods.

Implemented in itk::NDImageTemplate< TPixel, VDimension >.

◆ CreateNewImage()

template<class TPixel >
virtual void itk::NDImageBase< TPixel >::CreateNewImage ( void  )
pure virtual

Use New method to create a new actual image

Implemented in itk::NDImageTemplate< TPixel, VDimension >.

◆ FillBuffer()

template<class TPixel >
virtual void itk::NDImageBase< TPixel >::FillBuffer ( const TPixel &  value)
pure virtual

◆ GetBufferPointer() [1/2]

template<class TPixel >
virtual const TPixel * itk::NDImageBase< TPixel >::GetBufferPointer ( ) const
pure virtual

◆ GetBufferPointer() [2/2]

template<class TPixel >
virtual TPixel * itk::NDImageBase< TPixel >::GetBufferPointer ( )
pure virtual

◆ GetClassName()

template<class TPixel >
virtual const char * itk::NDImageBase< TPixel >::GetClassName ( ) const
virtual

Method for creation through the object factory. Run-time type information (and related methods).

Reimplemented in itk::NDImageTemplate< TPixel, VDimension >.

◆ GetImageDimension()

template<class TPixel >
virtual unsigned int itk::NDImageBase< TPixel >::GetImageDimension ( void  )
pure virtual

◆ GetImageIOReader()

template<class TPixel >
virtual ImageIOBase * itk::NDImageBase< TPixel >::GetImageIOReader ( void  )
pure virtual

◆ GetImageIOWriter()

template<class TPixel >
virtual ImageIOBase * itk::NDImageBase< TPixel >::GetImageIOWriter ( void  )
pure virtual

◆ GetInputFileName()

template<class TPixel >
virtual const char * itk::NDImageBase< TPixel >::GetInputFileName ( void  )
pure virtual

◆ GetOffsetTable()

template<class TPixel >
virtual const OffsetValueType * itk::NDImageBase< TPixel >::GetOffsetTable ( ) const
pure virtual

◆ GetOrigin()

template<class TPixel >
virtual PointType itk::NDImageBase< TPixel >::GetOrigin ( void  )
pure virtual

◆ GetOutputFileName()

template<class TPixel >
virtual const char * itk::NDImageBase< TPixel >::GetOutputFileName ( void  )
pure virtual

◆ GetPixel() [1/2]

template<class TPixel >
virtual const TPixel & itk::NDImageBase< TPixel >::GetPixel ( const IndexType index) const
pure virtual

◆ GetPixel() [2/2]

template<class TPixel >
virtual TPixel & itk::NDImageBase< TPixel >::GetPixel ( const IndexType index)
pure virtual

◆ GetPixelAccessor() [1/2]

template<class TPixel >
virtual const AccessorType itk::NDImageBase< TPixel >::GetPixelAccessor ( void  ) const
pure virtual

◆ GetPixelAccessor() [2/2]

template<class TPixel >
virtual AccessorType itk::NDImageBase< TPixel >::GetPixelAccessor ( void  )
pure virtual

◆ GetPixelContainer() [1/2]

template<class TPixel >
virtual const PixelContainer * itk::NDImageBase< TPixel >::GetPixelContainer ( ) const
pure virtual

◆ GetPixelContainer() [2/2]

template<class TPixel >
virtual PixelContainer * itk::NDImageBase< TPixel >::GetPixelContainer ( )
pure virtual

◆ GetSpacing()

template<class TPixel >
virtual SpacingType itk::NDImageBase< TPixel >::GetSpacing ( void  )
pure virtual

◆ ImageDimension()

template<class TPixel >
virtual unsigned int itk::NDImageBase< TPixel >::ImageDimension ( void  )
pure virtual

Extra functions for NDImage. Get the Dimension.

Implemented in itk::NDImageTemplate< TPixel, VDimension >.

◆ Initialize()

template<class TPixel >
virtual void itk::NDImageBase< TPixel >::Initialize ( void  )
pure virtual

◆ NewNDImage()

template<class TPixel >
NDImageBase< TPixel >::Pointer itk::NDImageBase< TPixel >::NewNDImage ( unsigned int  dim)
static

Definition at line 235 of file itkNDImageBase.h.

◆ operator=()

template<class TPixel >
void itk::NDImageBase< TPixel >::operator= ( const Self )
private

◆ operator[]() [1/2]

template<class TPixel >
TPixel & itk::NDImageBase< TPixel >::operator[] ( const IndexType index)
inline

Definition at line 138 of file itkNDImageBase.h.

◆ operator[]() [2/2]

template<class TPixel >
const TPixel & itk::NDImageBase< TPixel >::operator[] ( const IndexType index) const
inline

Definition at line 140 of file itkNDImageBase.h.

◆ Read()

template<class TPixel >
virtual void itk::NDImageBase< TPixel >::Read ( void  )
pure virtual

Read image data from file into the actual image

Implemented in itk::NDImageTemplate< TPixel, VDimension >.

◆ SetImageIOReader()

template<class TPixel >
virtual void itk::NDImageBase< TPixel >::SetImageIOReader ( ImageIOBase _arg)
pure virtual

◆ SetImageIOWriter()

template<class TPixel >
virtual void itk::NDImageBase< TPixel >::SetImageIOWriter ( ImageIOBase _arg)
pure virtual

◆ SetInputFileName()

template<class TPixel >
virtual void itk::NDImageBase< TPixel >::SetInputFileName ( const char *  )
pure virtual

◆ SetOrigin()

template<class TPixel >
virtual void itk::NDImageBase< TPixel >::SetOrigin ( const PointType origin)
pure virtual

◆ SetOutputFileName()

template<class TPixel >
virtual void itk::NDImageBase< TPixel >::SetOutputFileName ( const char *  )
pure virtual

Set/Get the Input/OutputFileName

Implemented in itk::NDImageTemplate< TPixel, VDimension >.

◆ SetPixel()

template<class TPixel >
virtual void itk::NDImageBase< TPixel >::SetPixel ( const IndexType index,
const TPixel &  value 
)
pure virtual

◆ SetPixelContainer()

template<class TPixel >
virtual void itk::NDImageBase< TPixel >::SetPixelContainer ( PixelContainer container)
pure virtual

◆ SetRegions()

template<class TPixel >
virtual void itk::NDImageBase< TPixel >::SetRegions ( SizeType  size)
pure virtual
Todo:
: extend to direction cosines; but not needed for now in elastix

Region typedef support. A region is used to specify a subset of an image.

Todo:
an NDRegionType should first be declared, in the same way as NDImage use SetRegions(size) for now. then knowlegde of the RegionType is not necessary. alternative: forget about the regiontype and add the functions SetLargestPossibleRegion, SetRegions etc with arguments (index,size) or maybe: ImageIORegion

Implemented in itk::NDImageTemplate< TPixel, VDimension >.

◆ SetRequestedRegion()

template<class TPixel >
virtual void itk::NDImageBase< TPixel >::SetRequestedRegion ( DataObject *  data)
pure virtual

◆ SetSpacing()

template<class TPixel >
virtual void itk::NDImageBase< TPixel >::SetSpacing ( const SpacingType spacing)
pure virtual

◆ Write()

template<class TPixel >
virtual void itk::NDImageBase< TPixel >::Write ( void  )
pure virtual

Write the actual image to file.

Implemented in itk::NDImageTemplate< TPixel, VDimension >.



Generated on 1667476801 for elastix by doxygen 1.9.4 elastix logo