Gray C++ Libraries  0.0.2
A set of C++ libraries for MSVC, GNU on Windows, WinCE, Linux
GrayLib::cValueRange< TYPE > Class Template Reference

#include <cValueRange.h>

Inheritance diagram for GrayLib::cValueRange< TYPE >:
Gray::cRangeT< TYPE >

Public Member Functions

 cValueRange (TYPE tLo=cTypeLimit< TYPE >::k_Min, TYPE tHi=cTypeLimit< TYPE >::k_Min)
 
void InitX (TYPE nVal=cTypeLimit< TYPE >::k_Min)
 
bool isRangeValid () const
 
TYPE GetLinearX (TYPE nVal2, TYPE nRange2) const
 
TYPE GetLinearI (int nVal2, int nRange2=1000) const
 
- Public Member Functions inherited from Gray::cRangeT< TYPE >
TYPE get_Min () const
 
TYPE get_Max () const
 
TYPE get_Avg () const
 
TYPE GetClampValue (TYPE nVal) const
 
bool IsInsideI (TYPE nVal) const
 
bool IsInsideX (TYPE nVal) const
 
TYPE get_RangeI () const
 
TYPE get_RangeX () const
 
TYPE GetLinear1 (float fOne) const
 
int GetSpinValueI (int iVal) const
 
void SetZero ()
 
void put_Min (TYPE iLo)
 
void put_Max (TYPE iHi)
 
void SetRange (TYPE iLo, TYPE iHi)
 
void NormalizeRange ()
 
void UnionValue (TYPE nVal)
 
bool IsRangeOverlapI (const THIS_t &x) const
 
void SetUnionRange (const THIS_t &x)
 

Additional Inherited Members

- Public Attributes inherited from Gray::cRangeT< TYPE >
TYPE m_Lo
 low range value. More...
 
TYPE m_Hi
 inclusive high side of range. int size = (hi-lo)+1, float size = hi-lo ?? weird. More...
 

Detailed Description

template<typename TYPE>
class GrayLib::cValueRange< TYPE >

Simple linearity range from m_Lo to m_Hi. Similar to cStreamProgressT<>

Note
allow reverse ranges (Not Normalized). Lo>Hi. for odd linearity

Constructor & Destructor Documentation

◆ cValueRange()

template<typename TYPE >
GrayLib::cValueRange< TYPE >::cValueRange ( TYPE  tLo = cTypeLimit<TYPE>::k_Min,
TYPE  tHi = cTypeLimit<TYPE>::k_Min 
)
inline

Member Function Documentation

◆ GetLinearI()

template<typename TYPE >
TYPE GrayLib::cValueRange< TYPE >::GetLinearI ( int  nVal2,
int  nRange2 = 1000 
) const
inline

As nVal2 is to nRange2

  • nVal2 = 0 to nRange2
    Returns
    linear iPercent in m_Lo to m_Hi. the linear equiv in m_Lo to m_Hi. inclusive.

◆ GetLinearX()

template<typename TYPE >
TYPE GrayLib::cValueRange< TYPE >::GetLinearX ( TYPE  nVal2,
TYPE  nRange2 
) const
inline

As nVal2 is to nRange2

Returns
the linear equiv in m_Lo to m_Hi. exclusive.

◆ InitX()

template<typename TYPE >
void GrayLib::cValueRange< TYPE >::InitX ( TYPE  nVal = cTypeLimit<TYPE>::k_Min)
inline

◆ isRangeValid()

template<typename TYPE >
bool GrayLib::cValueRange< TYPE >::isRangeValid ( ) const
inline

Has been set yet ?


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