Cortex
10.0.0-a4
|
#include <ScaledDataConversion.h>
Public Member Functions | |
T | operator() (F f) const |
![]() | |
T | operator() (F f) const |
InverseType | inverse () const |
Additional Inherited Members | |
![]() | |
typedef F | FromType |
typedef T | ToType |
typedef void | InverseType |
The type of the converter that can perform the inverse transformation. | |
typedef boost::false_type | IsIdentity |
A DataConversion which converts one numeric type to another, maximising the use of the range of the target type. For example, converting a char value of 127 (half way through the range of the char type) to a short would yield a short value of 32767 (half way through the range of the short type). Care is taken when dealing with floating point types, which are assumed to have no practical "range". So, in the example above, a char value of 127 when converter to float, double, or half, would have a value of approximately 0.498 (127/255).
When conversion is attempted between a signed type and an unsigned type, appropriate clamping is performed.
This conversion is employed primarily in the ImageWriter-derived classes.