User Documentation
User Documentation
DEVELOP IN NAMESPACE AMMA TREE ROOT AMMA SEARCH AMMA HOME
 

namespace StdMath
User Level:
Library: Mag2
Example: exMat2d.cc

Comments:

Reads and sets the elements of the matrix 'm' from the input stream 'inS'.

Methods:

#include "amma/StdMath.hh"
BooleanT IsSmall(const RealT a,const RealT norm,const RealT isSmall = 1e-8)
Is a small relative to 'norm' ?
This code used to be as follows, but it was changed because using x==y for floats is a bad idea, and eventually caused trouble on Visual C++. (AJS) float b = (float) ((double) ::Abs(a) + norm); return (b == (float) norm);

void SetToZero(DataT & dat)
Set 'dat' to zero.
In cases where this doesn't work, a specialised version should be provided.

DataT MinComponent(DataT a)
Returns the smallest component from 'a'.

DataT MaxComponent(DataT a)
Returns the Biggest component from 'a'.

DataT ScaleMin(DataT a,DataT b)
Returns the argument which has the smallest component from 'a' and 'b'. In a manner suitable for scaling operations.

DataT ScaleMax(DataT a,DataT b)
Returns the argument which has the smallest component from 'a' and 'b'. In a manner suitable for scaling operations.

#include "amma/Vector2d.hh"
void SetToZero(Vector2dC & dat)
Set 'dat' to zero.

#include "amma/Matrix2d.hh"
void SetToZero(Matrix2d2C & dat)
Set 'dat' to zero.

#include "amma/RGBValue.hh"
void SetToZero(ByteRGBValueC & dat)

void SetToZero(ByteRGBXValueC & dat)

void SetToZero(RGBValueU16C & dat)

void SetToZero(RGBValueC & dat)

void SetToZero(RGBPointC & dat)

RealT MinComponent(const RGBPointC & a)
Returns the minimum component from 'a'.

RealT MaxComponent(const RGBPointC & a)
Returns the maximum component from 'a'.

#include "amma/Image/SubSamp2Intl.hh"
DataT Average(const DataT & d1,const DataT & d2,const DataT & d3,const DataT & d4)
Average of 4 values.

ByteT Average(const ByteT & d1,const ByteT & d2,const ByteT & d3,const ByteT & d4)
Average of 4 values.

ByteRGBValueC Average(const ByteRGBValueC & d1,const ByteRGBValueC & d2,const ByteRGBValueC & d3,const ByteRGBValueC & d4)
Average of 4 values.

ByteYUVValueC Average(const ByteYUVValueC & d1,const ByteYUVValueC & d2,const ByteYUVValueC & d3,const ByteYUVValueC & d4)
Average of 4 values.

ByteVYUValueC Average(const ByteVYUValueC & d1,const ByteVYUValueC & d2,const ByteVYUValueC & d3,const ByteVYUValueC & d4)
Average of 4 values.

#include "amma/Image/BGRXValue.hh"
void SetToZero(ByteBGRXValueC & dat)


Documentation by CxxDoc: Tue Mar 20 10:50:51 2001
Centre for Vision, Speech & Signal Processing