|
The Vish Visualization Shell 0.3
Vish
|
A range of double values, to be used to map certain values from one range to another. More...
#include <ocean/shrimp/Range.hpp>
Public Member Functions | |
| double | applyFunctor (double x) const override |
| Implementation of the functor operation, calls map_01_to_minmax() | |
| double | bias () const |
| Alias for minimum. | |
| bool | contains (double d) const |
| Check whether the given value fits into the range. | |
| void | expand (const Range &R) |
| Expand the current range by the other range. | |
| void | expand (double d) |
| Expand the current range to contain the given value. | |
| bool | invalid () const |
| Return info if the range is valid, i.e. has positive range. | |
| bool | isIdentity () const |
| Check if this range is from 0.0 to 1.0, which would be the identity map. | |
| double | map_01_to_minmax (double d) const |
| Map a value in the range [0,1] to the range [min,max]. | |
| double | map_minmax_to_01 (double d) const |
| Map value in the range [min,max] to the range [0,1]. | |
| double & | Max () |
| modifyable maximum value | |
| double | Max () const |
| maximum value | |
| double & | Min () |
| modifyable minimum value | |
| double | Min () const |
| minimum value | |
| double | offset () const |
| Alias for minimum. | |
| bool | operator!= (const Range &R) const |
| Check for exact inequality. | |
| double | operator() (double x) const |
| Implementation of the functor operation, which is just the value mapping into the range interval, ie. [0,1] --> [min,max]. | |
| bool | operator== (const Range &R) const |
| Check for exact equality. | |
| Range | operator~ () const |
| Compute the inverse range mapping. | |
| Range (const Range &R) | |
| Copy constructor. | |
| Range (const Range &R, bool) | |
| Computational constructor constructing the inverse range mapping. | |
| Range (double theMin=0.0, double theMax=1.0) | |
| Constructor, specify min and max. | |
| Range (double theScale, double theOffset, bool) | |
| Construct a range from scale and offset. | |
| double | scale () const |
| Range interval length (max-min) | |
| void | setRange (const Range &R) |
| copies values | |
| void | setScaleOffset (double theScale, double theOffset) |
| Set range to [offset, offset+scale]. | |
A range of double values, to be used to map certain values from one range to another.
Mapping formula is