MDSTk Libraries  1.1.0
Medical Data Segmentation Toolkit
Public Types | Public Member Functions | Static Public Attributes | Protected Member Functions | Protected Attributes
mds::img::CVolumeAnisotropicFilter< V > Class Template Reference

Anisotropic filtering based on the diffusion process. More...

#include <mdsAnisotropic.h>

Inheritance diagram for mds::img::CVolumeAnisotropicFilter< V >:
Inheritance graph
[legend]

List of all members.

Public Types

enum  { TEMPLATE_PARAMETER_IS_NOT_VOLUME = V::CLASS_VOLUME }
 Check that type V is a volume. More...
enum  { BLOCK_SIZE = 32 }
 Size of the processing block (volume window). More...
typedef CVolumeFilter< V > base
 Volume filter base.
typedef mds::base::CFunctor
< bool, int, int
tProgressFunc
 Progress observer (= functor).
typedef CProgressInitializer tProgressInitializer
 Helper class which can be used to call methods beginProgress() and endProgress() automatically.
typedef base::tVolume tVolume
 Volume type.
typedef base::tVoxel tVoxel
 Volume voxel type.

Public Member Functions

void beginProgress ()
 This function must be called by the class realizing an operation before it starts.
 CVolumeAnisotropicFilter (double dKappa, tSize NumOfIters=-1)
 Constructor.
void deregisterProgressFunc ()
 Sets the default empty observer.
void endProgress ()
 The function must be called by the class realizing an operation every time the operation finishes.
tSize getNumOfIters () const
 Returns number of iterations of diffusion process.
int getProgressCount () const
 Returns current value of the internal progress value.
int getProgressMax () const
 Returns the maximum allowed value of the internal progress counter.
bool operator() (const tVolume &SrcVolume, tVolume &DstVolume)
 Filtering of input/source volume.
bool progress (int iIncrement=1)
 Calls the registered observer.
void registerProgressFunc (const tProgressFunc &Func)
 Sets observer/functor called to inform a calling process about the current state of the running operation.
void setNumOfIters (tSize NumOfIters)
 Sets the number of iterations of diffusion process.
void setProgressMax (int iValue)
 Sets the maximal counter value.
 ~CVolumeAnisotropicFilter ()
 Destructor.

Static Public Attributes

static const double DT = 0.166666666666667
static const double MIN_CHANGE = 0.1

Protected Member Functions

double getDiffusionStrength (double dGrad)
 Returns value of the diffusion function.

Protected Attributes

double m_dInvKappa
double m_dKappa
 Filter parameters.
tSize m_NumOfIters
 Number of iterations of the diffusion process.

Detailed Description

template<class V>
class mds::img::CVolumeAnisotropicFilter< V >

Anisotropic filtering based on the diffusion process.


Member Typedef Documentation

template<class V >
typedef CVolumeFilter<V> mds::img::CVolumeAnisotropicFilter< V >::base

Volume filter base.

Progress observer (= functor).

  • You may return false from the observer if you want to terminate the running operation.
  • Parameters describe current and final state of the pending operation (counter and maximal value).
  • If the second parameter is equal to -1, termination time cannot be determined, the current state is unknown.

Helper class which can be used to call methods beginProgress() and endProgress() automatically.

Create static object of this type at the begining of a method that realizes an operation.

template<class V >
typedef base::tVolume mds::img::CVolumeAnisotropicFilter< V >::tVolume

Volume type.

Reimplemented from mds::img::CVolumeFilter< V >.

template<class V >
typedef base::tVoxel mds::img::CVolumeAnisotropicFilter< V >::tVoxel

Volume voxel type.

Reimplemented from mds::img::CVolumeFilter< V >.


Member Enumeration Documentation

template<class V>
anonymous enum [inherited]

Check that type V is a volume.

You will see name of this enum somewhere in compiler error message if the type V is not volume.

Enumerator:
TEMPLATE_PARAMETER_IS_NOT_VOLUME 
template<class V >
anonymous enum

Size of the processing block (volume window).

The input volume is divided into smaller blocks - cubes for the processing.

  • This is used to reduce amount of the memory required by the filtering.
Enumerator:
BLOCK_SIZE 

Constructor & Destructor Documentation

template<class V >
mds::img::CVolumeAnisotropicFilter< V >::CVolumeAnisotropicFilter ( double  dKappa,
tSize  NumOfIters = -1 
)

Constructor.

Destructor.


Member Function Documentation

void mds::mod::CProgress::beginProgress ( ) [inherited]

This function must be called by the class realizing an operation before it starts.

Sets the default empty observer.

void mds::mod::CProgress::endProgress ( ) [inherited]

The function must be called by the class realizing an operation every time the operation finishes.

  • Sets the default observer.
template<class V >
double CVolumeAnisotropicFilter::getDiffusionStrength ( double  dGrad) [protected]

Returns value of the diffusion function.

template<class V >
tSize mds::img::CVolumeAnisotropicFilter< V >::getNumOfIters ( ) const

Returns number of iterations of diffusion process.

Returns current value of the internal progress value.

Returns the maximum allowed value of the internal progress counter.

template<class V >
bool CVolumeAnisotropicFilter::operator() ( const tVolume SrcVolume,
tVolume DstVolume 
) [virtual]

Filtering of input/source volume.

Point filter responses are written to the destination volume.

  • Returns false on failure.

Implements mds::img::CVolumeFilter< V >.

bool mds::mod::CProgress::progress ( int  iIncrement = 1) [inherited]

Calls the registered observer.

  • Returns false if the running operation should be terminated as soon as possible.
  • It must be called periodically by the class realizing the operation.
void mds::mod::CProgress::registerProgressFunc ( const tProgressFunc Func) [inherited]

Sets observer/functor called to inform a calling process about the current state of the running operation.

  • This function should be called before any operation starts.
template<class V >
void mds::img::CVolumeAnisotropicFilter< V >::setNumOfIters ( tSize  NumOfIters)

Sets the number of iterations of diffusion process.

void mds::mod::CProgress::setProgressMax ( int  iValue) [inherited]

Sets the maximal counter value.


Member Data Documentation

template<class V >
const double CVolumeAnisotropicFilter::DT = 0.166666666666667 [static]
template<class V >
double mds::img::CVolumeAnisotropicFilter< V >::m_dInvKappa [protected]
template<class V >
double mds::img::CVolumeAnisotropicFilter< V >::m_dKappa [protected]

Filter parameters.

template<class V >
tSize mds::img::CVolumeAnisotropicFilter< V >::m_NumOfIters [protected]

Number of iterations of the diffusion process.

template<class V >
const double CVolumeAnisotropicFilter::MIN_CHANGE = 0.1 [static]

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