SMIL  0.8
 All Classes Functions Variables Groups Pages
Base measures
+ Collaboration diagram for Base measures:

Functions

template<class T >
size_t area (const Image< T > &imIn)
 Area of an image. More...
 
template<class T >
bool isBinary (const Image< T > &imIn)
 Test if an image is binary. More...
 
template<class T >
maxVal (const Image< T > &imIn, bool onlyNonZero=false)
 Max value of an image. More...
 
template<class T >
Vector_double meanVal (const Image< T > &imIn, bool onlyNonZero=false)
 Mean value and standard deviation. More...
 
template<class T >
Vector_UINT measBoundBox (Image< T > &im)
 Bounding Box measure. More...
 
template<class T >
vector< double > measCenteredCovariance (const Image< T > &imIn, size_t dx, size_t dy, size_t dz, UINT maxSteps=0, bool normalize=false)
 Centered auto-covariance. More...
 
template<class T >
vector< double > measCovariance (const Image< T > &imIn1, const Image< T > &imIn2, size_t dx, size_t dy, size_t dz, UINT maxSteps=0, bool normalize=false)
 Covariance between two images. More...
 
template<class T >
vector< double > measCovariance (const Image< T > &imIn, size_t dx, size_t dy, size_t dz, UINT maxSteps=0, bool normalize=false)
 Auto-covariance. More...
 
template<class T >
Vector_double measInertiaMatrix (const Image< T > &im, const bool onlyNonZero=true)
 Measure inertia moments. More...
 
template<class T >
measModeVal (const Image< T > &imIn, bool onlyNonZero=true)
 Get the mode of the histogram present in the image, i.e. More...
 
template<class T >
minVal (const Image< T > &imIn, bool onlyNonZero=false)
 Min value of an image. More...
 
template<class T >
Vector_UINT nonZeroOffsets (Image< T > &imIn)
 Non-zero point offsets. More...
 
template<class T >
vector< T > profile (const Image< T > &im, size_t x0, size_t y0, size_t x1, size_t y1, size_t z=0)
 Get image values along a profile.
 
template<class T >
vector< T > rangeVal (const Image< T > &imIn, bool onlyNonZero=false)
 Min and Max values of an image. More...
 
template<class T >
vector< T > valueList (const Image< T > &imIn, bool onlyNonZero=true)
 Get the list of the pixel values present in the image.
 
template<class T >
double vol (const Image< T > &imIn)
 Volume of an image. More...
 

Detailed Description

Function Documentation

size_t smil::area ( const Image< T > &  imIn)

Area of an image.

Returns the number of non-zero pixels

Parameters
imInInput image.
bool smil::isBinary ( const Image< T > &  imIn)

Test if an image is binary.

Return true if the only pixel values are ImDtTypes<T>::min() and ImDtTypes<T>::max()

T smil::maxVal ( const Image< T > &  imIn,
bool  onlyNonZero = false 
)

Max value of an image.

Returns the min of the pixel values.

Parameters
imInInput image.
Vector_double smil::meanVal ( const Image< T > &  imIn,
bool  onlyNonZero = false 
)

Mean value and standard deviation.

Returns mean and standard deviation of the pixel values. If onlyNonZero is true, only non-zero pixels are considered.

Parameters
imInInput image.
Vector_UINT smil::measBoundBox ( Image< T > &  im)

Bounding Box measure.

Returns
xMin, yMin (,zMin), xMax, yMax (,zMax)
vector<double> smil::measCenteredCovariance ( const Image< T > &  imIn,
size_t  dx,
size_t  dy,
size_t  dz,
UINT  maxSteps = 0,
bool  normalize = false 
)

Centered auto-covariance.

The direction is given by dx, dy and dz. The lenght corresponds to the max number of steps maxSteps

vector<double> smil::measCovariance ( const Image< T > &  imIn1,
const Image< T > &  imIn2,
size_t  dx,
size_t  dy,
size_t  dz,
UINT  maxSteps = 0,
bool  normalize = false 
)

Covariance between two images.

The direction is given by dx, dy and dz. The lenght corresponds to the max number of steps maxSteps

vector<double> smil::measCovariance ( const Image< T > &  imIn,
size_t  dx,
size_t  dy,
size_t  dz,
UINT  maxSteps = 0,
bool  normalize = false 
)

Auto-covariance.

The direction is given by dx, dy and dz. The lenght corresponds to the max number of steps maxSteps

Vector_double smil::measInertiaMatrix ( const Image< T > &  im,
const bool  onlyNonZero = true 
)

Measure inertia moments.

Returns
* For 2D images: m00, m10, m01, m11, m20, m02
* For 3D images: m000, m100, m010, m110, m200, m020, m001, m101, m011, m002

http://en.wikipedia.org/wiki/Image_moment

T smil::measModeVal ( const Image< T > &  imIn,
bool  onlyNonZero = true 
)

Get the mode of the histogram present in the image, i.e.

the value that appears most often.

T smil::minVal ( const Image< T > &  imIn,
bool  onlyNonZero = false 
)

Min value of an image.

Returns the min of the pixel values.

Parameters
imInInput image.
Vector_UINT smil::nonZeroOffsets ( Image< T > &  imIn)

Non-zero point offsets.

Return a vector conatining the offset of all non-zero points in image.

vector<T> smil::rangeVal ( const Image< T > &  imIn,
bool  onlyNonZero = false 
)

Min and Max values of an image.

Returns the min and the max of the pixel values.

Parameters
imInInput image.
double smil::vol ( const Image< T > &  imIn)

Volume of an image.

Returns the sum of the pixel values.

Parameters
imInInput image.