Public Types | Public Member Functions | List of all members
mirtk::ImageSequence< TFrame > Class Template Reference

#include <ImageSequence.h>

Inheritance diagram for mirtk::ImageSequence< TFrame >:
Inheritance graph
Collaboration diagram for mirtk::ImageSequence< TFrame >:
Collaboration graph

Public Types

typedef TFrame::ChannelType ChannelType
 Type of channels.
 
typedef TFrame FrameType
 Type of frames.
 
typedef TFrame::ImageType ImageType
 Type of images.
 

Public Member Functions

void Add (ImageType *image, bool manage=false, bool copy=false)
 
ImageAttributes Attributes () const
 
ChannelTypeChannel (int idx)
 
const ChannelTypeChannel (int idx) const
 
ChannelTypeChannel (int f, int c)
 
const ChannelTypeChannel (int f, int c) const
 
void Clear ()
 Clear image sequence.
 
FrameTypeFrame (int)
 Get frame of sequence.
 
const FrameTypeFrame (int) const
 Get frame of sequence.
 
void GetPixelSize (double *, double *, double *) const
 Get voxel size.
 
void Image (int f, int c, ImageType *image, bool manage, bool copy)
 
void Image (int f, int c, const ImageType *image)
 
ImageTypeImage (int idx) const
 
ImageTypeImage (int f, int c) const
 
 ImageSequence ()
 Constructor.
 
 ImageSequence (const ImageSequence &)
 Copy constructor.
 
void ImageToWorld (double &, double &, double &) const
 Convert voxel to world coordinate.
 
void NumberOfChannels (int) const
 Set number of channels per frame.
 
int NumberOfChannels () const
 Get number of channels per frame.
 
void NumberOfFrames (int) const
 Set number of frames.
 
int NumberOfFrames () const
 Get number of frames.
 
int NumberOfImages () const
 Get number of frames times number of channels.
 
int NumberOfVoxels () const
 Get number of voxels per channel.
 
ImageSequenceoperator= (const ImageSequence &)
 Assignment operator.
 
int T () const
 Get number of frames.
 
double Time (int) const
 Get time of temporal frame.
 
void WorldToImage (double &, double &, double &) const
 Convert world to voxel coordinate.
 
int X () const
 Get number of voxels in x dimension for each channel.
 
double XSize () const
 Get size of each voxel in x dimension.
 
int Y () const
 Get number of voxels in y dimension for each channel.
 
double YSize () const
 Get size of each voxel in y dimension.
 
int Z () const
 Get number of voxels in z dimension for each channel.
 
double ZSize () const
 Get size of each voxel in z dimension.
 
 ~ImageSequence ()
 Destructor.
 
- Public Member Functions inherited from mirtk::Object
virtual const char * NameOfClass () const =0
 Get name of class, which this object is an instance of.
 
virtual ParameterList Parameter () const
 Get parameter name/value pairs.
 
bool Parameter (const ParameterList &)
 Set parameters from name/value pairs.
 
virtual bool Set (const char *name, const char *value)
 
virtual ~Object ()
 Destructor.
 

Additional Inherited Members

- Static Public Member Functions inherited from mirtk::Object
static const char * NameOfType ()
 Get name of this class type.
 
- Protected Member Functions inherited from mirtk::Object
template<typename... Args>
void Throw (ErrorType err, const char *func, Args... args) const
 
- Static Protected Member Functions inherited from mirtk::Object
template<typename... Args>
static void ThrowStatic (ErrorType err, const char *cls, const char *func, Args... args)
 

Detailed Description

template<class TFrame = ImageFrame<>>
class mirtk::ImageSequence< TFrame >

Auxiliary type to store ordered sequence of temporal (multi-channel) image frames

Definition at line 285 of file ImageSequence.h.

Member Function Documentation

§ Add()

template<class TFrame >
void mirtk::ImageSequence< TFrame >::Add ( ImageType image,
bool  manage = false,
bool  copy = false 
)
inline

Add channels or frames to image sequence

Parameters
[in]imageImage to add to this sequence. If the image has a fouth dimension, a copy of each 2D/3D sub-image is added.
[in]manageWhether to manage memory of input image if not copied.
[in]copyWhether to copy image if manage is false even though it has no fourth dimension.

Definition at line 408 of file ImageSequence.hh.

§ Attributes()

template<class TFrame >
ImageAttributes mirtk::ImageSequence< TFrame >::Attributes ( ) const
inline

Get attributes of this image sequence

The spatial attributes of the sequence correspond to those of its frames which are the same for all frames. The temporal attributes are:

  • _t: Number of frames
  • _dt: Temporal size of first frame (in ms)
  • _torigin: Time coordinate of first frame (in ms)

Definition at line 569 of file ImageSequence.hh.

§ Channel() [1/4]

template<class TFrame >
ImageSequence< TFrame >::ChannelType & mirtk::ImageSequence< TFrame >::Channel ( int  idx)
inline

Get channel

Parameters
[in]idxIndex of channel across all frames.

Definition at line 510 of file ImageSequence.hh.

§ Channel() [2/4]

template<class TFrame >
const ImageSequence< TFrame >::ChannelType & mirtk::ImageSequence< TFrame >::Channel ( int  idx) const
inline

Get channel

Parameters
[in]idxIndex of channel across all frames.

Definition at line 518 of file ImageSequence.hh.

§ Channel() [3/4]

template<class TFrame >
ImageSequence< TFrame >::ChannelType & mirtk::ImageSequence< TFrame >::Channel ( int  f,
int  c 
)
inline

Get channel

Parameters
[in]fIndex of frame.
[in]cIndex of channel.

Definition at line 526 of file ImageSequence.hh.

§ Channel() [4/4]

template<class TFrame >
const ImageSequence< TFrame >::ChannelType & mirtk::ImageSequence< TFrame >::Channel ( int  f,
int  c 
) const
inline

Get channel

Parameters
[in]fIndex of frame.
[in]cIndex of channel.

Definition at line 533 of file ImageSequence.hh.

§ Image() [1/4]

template<class TFrame = ImageFrame<>>
void mirtk::ImageSequence< TFrame >::Image ( int  f,
int  c,
ImageType image,
bool  manage,
bool  copy 
)

Set image associated with channel

Parameters
[in]fIndex of frame.
[in]cIndex of channel.
[in]imageImage which is associated with the channel.
[in]manageWhether to manage the memory of the image.
[in]copyWhether to copy the image if manage is false.

§ Image() [2/4]

template<class TFrame = ImageFrame<>>
void mirtk::ImageSequence< TFrame >::Image ( int  f,
int  c,
const ImageType image 
)

Set image associated with channel to copy of given image

Parameters
[in]fIndex of frame.
[in]cIndex of channel.
[in]imageImage of which a copy is associated with the channel.

§ Image() [3/4]

template<class TFrame >
ImageSequence< TFrame >::ImageType * mirtk::ImageSequence< TFrame >::Image ( int  idx) const
inline

Get image associated with channel

Parameters
[in]idxIndex of channel across all frames.

Definition at line 551 of file ImageSequence.hh.

§ Image() [4/4]

template<class TFrame >
ImageSequence< TFrame >::ImageType * mirtk::ImageSequence< TFrame >::Image ( int  f,
int  c 
) const
inline

Get image associated with channel

Parameters
[in]fIndex of frame.
[in]cIndex of channel.

Definition at line 558 of file ImageSequence.hh.


The documentation for this class was generated from the following files: