eLynx SDK
v3.0.1 C++ image processing API reference |
#include <elx/core/CoreTypes.h>
#include "MathLib.h"
#include "inl/Core.inl"
#include "inl/MinMax.inl"
#include "inl/Clamp.inl"
#include "inl/Operator.inl"
#include "inl/Normalize.inl"
Go to the source code of this file.
Namespaces | |
namespace | eLynx |
namespace | eLynx::Math |
Defines | |
#define | CM_Channel0 (1<<0) |
channels masks | |
#define | CM_Channel1 (1<<1) |
#define | CM_Channel2 (1<<2) |
#define | CM_Channel3 (1<<3) |
#define | CM_Channel01 (CM_Channel0 | CM_Channel1) |
#define | CM_Channel02 (CM_Channel0 | CM_Channel2) |
#define | CM_Channel03 (CM_Channel0 | CM_Channel3) |
#define | CM_Channel12 (CM_Channel1 | CM_Channel2) |
#define | CM_Channel13 (CM_Channel1 | CM_Channel3) |
#define | CM_Channel23 (CM_Channel2 | CM_Channel3) |
#define | CM_Channel012 (CM_Channel0 | CM_Channel1 | CM_Channel2) |
#define | CM_Channel013 (CM_Channel0 | CM_Channel1 | CM_Channel3) |
#define | CM_Channel023 (CM_Channel0 | CM_Channel2 | CM_Channel3) |
#define | CM_Channel123 (CM_Channel1 | CM_Channel2 | CM_Channel3) |
#define | CM_Channel0123 (CM_Channel0 | CM_Channel1 | CM_Channel2 | CM_Channel3) |
#define | CM_None (0) |
#define | CM_All (CM_Channel0123) |
Functions | |
Sort function helpers. | |
template<typename T > | |
const T & | eLynx::Math::elxMin (const T &iA, const T &iB) |
template<typename T > | |
const T & | eLynx::Math::elxMin (const T &iA, const T &iB, const T &iC) |
template<typename T > | |
const T & | eLynx::Math::elxMin (const T &iA, const T &iB, const T &iC, const T &iD) |
template<typename T > | |
const T & | eLynx::Math::elxMin (const T &iA, const T &iB, const T &iC, const T &iD, const T &iE) |
template<typename T > | |
const T & | eLynx::Math::elxMin (const T &iA, const T &iB, const T &iC, const T &iD, const T &iE, const T &iF) |
template<typename T > | |
bool | eLynx::Math::elxMin (const T *iprSrc, uint32 iSize, T &oMin) |
template<typename T > | |
bool | eLynx::Math::elxMin (const T *iprSrc, uint32 iSize, uint32 iStep, T *oprMin) |
template<typename T > | |
T | eLynx::Math::elxMin (T iV0, T iV1, T iV2, T iV3, T iV4, T iV5, T iV6, T iV7, T iV8) |
template<typename T > | |
const T & | eLynx::Math::elxMax (const T &iA, const T &iB) |
template<typename T > | |
const T & | eLynx::Math::elxMax (const T &iA, const T &iB, const T &iC) |
template<typename T > | |
const T & | eLynx::Math::elxMax (const T &iA, const T &iB, const T &iC, const T &iD) |
template<typename T > | |
const T & | eLynx::Math::elxMax (const T &iA, const T &iB, const T &iC, const T &iD, const T &iE) |
template<typename T > | |
const T & | eLynx::Math::elxMax (const T &iA, const T &iB, const T &iC, const T &iD, const T &iE, const T &iF) |
template<typename T > | |
bool | eLynx::Math::elxMax (const T *iprSrc, uint32 iSize, T &oMin) |
template<typename T > | |
bool | eLynx::Math::elxMax (const T *iprSrc, uint32 iSize, uint32 iStep, T *oprMax) |
template<typename T > | |
T | eLynx::Math::elxMax (T iV0, T iV1, T iV2, T iV3, T iV4, T iV5, T iV6, T iV7, T iV8) |
template<typename T > | |
bool | eLynx::Math::elxMinMax (const T *iprSrc, uint32 iSize, T &oMin, T &oMax) |
template<typename T > | |
bool | eLynx::Math::elxMinMax (const T *iprSrc, uint32 iSize, uint32 iStep, T *oprMin, T *oprMax) |
template<typename T > | |
T | eLynx::Math::elxNeg (const T iValue) |
negative | |
template<typename T > | |
T | eLynx::Math::elxMedian (T iV0, T iV1, T iV2) |
Median of 3 values. | |
template<typename T > | |
T | eLynx::Math::elxMedian (T iV0, T iV1, T iV2, T iV3) |
Median of 4 values. | |
template<typename T > | |
T | eLynx::Math::elxMedian (T iV0, T iV1, T iV2, T iV3, T iV4, T iV5, T iV6, T iV7, T iV8) |
Median of 9 values. | |
Normalization. | |
template<typename T > | |
bool | eLynx::Math::elxNormalize (T *ioprSrc, uint32 iSize, T iMin, T iMax) |
template<typename T > | |
bool | eLynx::Math::elxNormalize (T *ioprSrc, uint32 iSize, const T *oprMin, const T *oprMax, uint32 iChannelMask, uint32 iChannelCount) |
template<typename T > | |
bool | eLynx::Math::elxNormalize (T *ioprSrc, uint32 iSize) |
template<typename T > | |
bool | eLynx::Math::elxNormalize (T *ioprSrc, uint32 iStep, uint32 iSize, uint32 iChannelMask, uint32 iChannelCount) |
Arithmetic helpers. | |
template<typename T > | |
T | eLynx::Math::elxSign (T iValue) |
template<typename T > | |
T | eLynx::Math::elxAbs (T iX) |
template<typename T > | |
T | eLynx::Math::elxFloor (T iValue) |
template<typename T > | |
T | eLynx::Math::elxCeil (T iValue) |
template<typename T > | |
T | eLynx::Math::elxRound (T iValue) |
template<typename T > | |
int32 | eLynx::Math::elxRint (T iValue) |
template<typename T > | |
T | eLynx::Math::elxMod (T iA, T iB) |
template<typename T > | |
T | eLynx::Math::elxMean (T iV1, T iV2) |
template<typename T > | |
T | eLynx::Math::elxAbsDiff (T iV1, T iV2) |
template<typename T > | |
bool | eLynx::Math::elxIsOdd (T iValue) |
template<typename T > | |
bool | eLynx::Math::elxIsEven (T iValue) |
ExportedByMath int32 | eLynx::Math::elxHighBit (uint32 iVal) |
Miscelaneaous function helpers. | |
template<typename T > | |
T | eLynx::Math::elxSmooth (T iMin, T iMax, T iValue) |
ExportedByMath double | eLynx::Math::elxMidtone (double iX, double iMidtone) |
Random number generator function helpers. | |
ExportedByMath void | eLynx::Math::elxRandomReset () |
ExportedByMath void | eLynx::Math::elxRandomReset (int32 iSeed) |
ExportedByMath int32 | eLynx::Math::elxRandomSign () |
ExportedByMath double | eLynx::Math::elxRandom () |
template<typename T > | |
T | eLynx::Math::elxRandom (T iMax) |
template<typename T > | |
T | eLynx::Math::elxRandom (T iMin, T iMax) |
Exponential, logarithmic and power function helpers. | |
#define | M_SQRT2 (1.4142135623730950488016887242097) |
#define | M_E (2.7182818284590452353602874713527) |
Exponential constant value, e^1. | |
template<typename T > | |
T | eLynx::Math::elxSqr (T iX) |
template<typename T > | |
T | eLynx::Math::elxSqrt (T iX) |
template<typename T > | |
T | eLynx::Math::elxPow (T iX, T iY) |
template<typename T > | |
T | eLynx::Math::elxLog (T iX) |
template<typename T > | |
T | eLynx::Math::elxLog10 (T iX) |
template<typename T > | |
T | eLynx::Math::elxExp (T iX) |
template<typename T > | |
bool | eLynx::Math::elxIsPow2 (T iValue) |
template<typename T > | |
T | eLynx::Math::elxNextPow2 (T iValue) |
Trigonometric and hyperbolic function helpers. | |
PI constant value | |
#define | M_PI (3.1415926535897932384626433832795) |
#define | M_2PI (6.283185307179586476925286766559) |
2*PI constant value | |
#define | M_PIo2 (1.5707963267948966192313216916398) |
PI/2 constant value. | |
#define | M_PIo4 (0.78539816339744830961566084581988) |
PI/4 constant value. | |
#define | M_3PIo2 (4.7123889803846898576939650749193) |
3*PI/2 constant value | |
template<typename T > | |
T | eLynx::Math::elxDeg2Rad (T iDegrees) |
template<typename T > | |
T | eLynx::Math::elxRad2Deg (T iRadian) |
template<typename T > | |
T | eLynx::Math::elxCos (T iRadian) |
template<typename T > | |
T | eLynx::Math::elxSin (T iRadian) |
template<typename T > | |
T | eLynx::Math::elxTan (T iRadian) |
template<typename T > | |
T | eLynx::Math::elxArccos (T iX) |
template<typename T > | |
T | eLynx::Math::elxArcsin (T iX) |
template<typename T > | |
T | eLynx::Math::elxArctan (T iYoX) |
Gaussian family function helpers. | |
#define | M_GAUSS1D (0.39894228040143267793994605993438) |
#define | M_GAUSS2D (0.15915494309189533576888376337251) |
template<typename T > | |
T | eLynx::Math::elxGetGaussianVariance (T iRadius) |
Get variance from a given radius. | |
template<typename T > | |
T | eLynx::Math::elxGaussian (T iX, T iSigma) |
1D Gaussian curve. | |
template<typename T > | |
T | eLynx::Math::elxGaussian (T iX, T iY, T iSigma) |
2D Gaussian curve. | |
template<typename T > | |
T | eLynx::Math::elxMeanGaussian (T iX, T iSigma) |
template<typename T > | |
T | eLynx::Math::elxDoG (T iX, T iSigma) |
First Derivative of Gaussian. | |
template<typename T > | |
T | eLynx::Math::elxLoG (T iX, T iSigma) |
Laplacian of Gaussian. | |
template<typename T > | |
T | eLynx::Math::elxLoG (T iX, T iY, T iSigma) |
2D Laplacian of Gaussian curve. | |
Operators. | |
enum | eLynx::Math::EValueAction { eLynx::Math::R_NoAction, eLynx::Math::R_Clamp, eLynx::Math::R_Cycle } |
List of possible actions with the returned value. More... | |
template<typename T , typename U > | |
void | eLynx::Math::elxClamp (T iIn, U &oOut) |
template<typename T > | |
void | eLynx::Math::elxClamp (T iInMin, T iInMax, T &oOut) |
template<typename T > | |
bool | eLynx::Math::elxAdd (T *ioprSrc, uint32 iSize, T iValue) |
template<typename T > | |
bool | eLynx::Math::elxSub (T *ioprSrc, uint32 iSize, T iValue) |
template<typename T > | |
bool | eLynx::Math::elxMul (T *ioprSrc, uint32 iSize, T iValue) |
template<typename T > | |
bool | eLynx::Math::elxDiv (T *ioprSrc, uint32 iSize, T iValue) |
template<typename T > | |
bool | eLynx::Math::elxDif (T *ioprSrc, uint32 iSize, T iValue) |
template<typename T > | |
bool | eLynx::Math::elxAddClamp (T *ioprSrc, uint32 iSize, T iValue) |
template<typename T > | |
bool | eLynx::Math::elxSubClamp (T *ioprSrc, uint32 iSize, T iValue) |
template<typename T > | |
bool | eLynx::Math::elxMulClamp (T *ioprSrc, uint32 iSize, double iValue) |
template<typename T > | |
bool | eLynx::Math::elxDivClamp (T *ioprSrc, uint32 iSize, double iValue) |
template<typename T > | |
bool | eLynx::Math::elxAddCycle (T *ioprSrc, uint32 iSize, T iValue) |
template<typename T > | |
bool | eLynx::Math::elxSubCycle (T *ioprSrc, uint32 iSize, T iValue) |
template<typename T > | |
bool | eLynx::Math::elxMulCycle (T *ioprSrc, uint32 iSize, double iValue) |
template<typename T > | |
bool | eLynx::Math::elxDivCycle (T *ioprSrc, uint32 iSize, double iValue) |
template<typename T > | |
bool | eLynx::Math::elxAdd (T *ioprSrc, uint32 iSize, T iValue, EValueAction iAction) |
template<typename T > | |
bool | eLynx::Math::elxSub (T *ioprSrc, uint32 iSize, T iValue, EValueAction iAction) |
template<typename T > | |
bool | eLynx::Math::elxMul (T *ioprSrc, uint32 iSize, double iValue, EValueAction iAction) |
template<typename T > | |
bool | eLynx::Math::elxDiv (T *ioprSrc, uint32 iSize, double iValue, EValueAction iAction) |
template<typename T > | |
bool | eLynx::Math::elxAdd (T *ioprSrc, uint32 iSize, double iValue, EValueAction iAction) |
template<typename T > | |
bool | eLynx::Math::elxSub (T *ioprSrc, uint32 iSize, double iValue, EValueAction iAction) |
template<typename T > | |
bool | eLynx::Math::elxAddNorm (T *ioprSrc, uint32 iSize, double iValue, EValueAction iAction) |
template<typename T > | |
bool | eLynx::Math::elxSubNorm (T *ioprSrc, uint32 iSize, double iValue, EValueAction iAction) |
template<typename T > | |
bool | eLynx::Math::elxMulNorm (T *ioprSrc, uint32 iSize, double iValue, EValueAction iAction) |
template<typename T > | |
bool | eLynx::Math::elxDivNorm (T *ioprSrc, uint32 iSize, double iValue, EValueAction iAction) |
#define CM_Channel0 (1<<0) |
#define CM_Channel1 (1<<1) |
Definition at line 29 of file MathCore.h.
#define CM_Channel2 (1<<2) |
Definition at line 30 of file MathCore.h.
#define CM_Channel3 (1<<3) |
Definition at line 31 of file MathCore.h.
#define CM_Channel01 (CM_Channel0 | CM_Channel1) |
Definition at line 33 of file MathCore.h.
#define CM_Channel02 (CM_Channel0 | CM_Channel2) |
Definition at line 34 of file MathCore.h.
#define CM_Channel03 (CM_Channel0 | CM_Channel3) |
Definition at line 35 of file MathCore.h.
#define CM_Channel12 (CM_Channel1 | CM_Channel2) |
Definition at line 36 of file MathCore.h.
#define CM_Channel13 (CM_Channel1 | CM_Channel3) |
Definition at line 37 of file MathCore.h.
#define CM_Channel23 (CM_Channel2 | CM_Channel3) |
Definition at line 38 of file MathCore.h.
#define CM_Channel012 (CM_Channel0 | CM_Channel1 | CM_Channel2) |
Definition at line 40 of file MathCore.h.
#define CM_Channel013 (CM_Channel0 | CM_Channel1 | CM_Channel3) |
Definition at line 41 of file MathCore.h.
#define CM_Channel023 (CM_Channel0 | CM_Channel2 | CM_Channel3) |
Definition at line 42 of file MathCore.h.
#define CM_Channel123 (CM_Channel1 | CM_Channel2 | CM_Channel3) |
Definition at line 43 of file MathCore.h.
#define CM_Channel0123 (CM_Channel0 | CM_Channel1 | CM_Channel2 | CM_Channel3) |
Definition at line 45 of file MathCore.h.
#define CM_None (0) |
Definition at line 47 of file MathCore.h.
#define CM_All (CM_Channel0123) |
Definition at line 48 of file MathCore.h.
#define M_SQRT2 (1.4142135623730950488016887242097) |
Definition at line 422 of file MathCore.h.
#define M_E (2.7182818284590452353602874713527) |
#define M_PI (3.1415926535897932384626433832795) |
Definition at line 487 of file MathCore.h.
#define M_2PI (6.283185307179586476925286766559) |
#define M_PIo2 (1.5707963267948966192313216916398) |
#define M_PIo4 (0.78539816339744830961566084581988) |
#define M_3PIo2 (4.7123889803846898576939650749193) |
#define M_GAUSS1D (0.39894228040143267793994605993438) |
Definition at line 582 of file MathCore.h.
#define M_GAUSS2D (0.15915494309189533576888376337251) |
Definition at line 587 of file MathCore.h.