#include <genesis/utils/color/normalization.hpp>
Inherited by ColorNormalizationBoundary, and ColorNormalizationLinear.
Base class for color normalization.
Definition at line 52 of file normalization.hpp.
|
virtual bool | is_valid_ () const =0 |
| Return whether ranges and other values are correct. More...
|
|
virtual double | normalize_ (double value) const =0 |
| Normalization function. More...
|
|
◆ ColorNormalization() [1/3]
◆ ~ColorNormalization()
◆ ColorNormalization() [2/3]
◆ ColorNormalization() [3/3]
◆ is_valid()
Return whether ranges and other values are correct.
Definition at line 91 of file normalization.hpp.
◆ is_valid_()
virtual bool is_valid_ |
( |
| ) |
const |
|
protectedpure virtual |
◆ mask_value() [1/2]
double mask_value |
( |
| ) |
const |
|
inline |
Mask value that identifies invalid values.
When querying a value that compares equal to the mask value, the color functions return mask_color() instead of a Color from the palette. This is meant as a simple means of filtering and visualizing invalid values.
The mask value is initialized to quiet_NaN
, so that it never compares equal to anything. Thus, it is not used by default has to be explicitly set to a different value.
Definition at line 83 of file normalization.hpp.
◆ mask_value() [2/2]
Mask value that identifies invalid values.
When querying a value that compares equal to the mask value, the color functions return mask_color() instead of a Color from the palette. This is meant as a simple means of filtering and visualizing invalid values.
The mask value is initialized to quiet_NaN
, so that it never compares equal to anything. Thus, it is not used by default has to be explicitly set to a different value.
Definition at line 103 of file normalization.hpp.
◆ normalize_()
virtual double normalize_ |
( |
double |
value | ) |
const |
|
protectedpure virtual |
◆ operator()() [1/3]
double operator() |
( |
double |
value | ) |
const |
|
inline |
Normalize a value
into range [ 0.0, 1.0 ]
.
The function first checks whether the value is finite or mask_value(), and returns quiet_NaN
if so. If not, the normalization is applied.
Definition at line 119 of file normalization.hpp.
◆ operator()() [2/3]
std::vector<double> operator() |
( |
ForwardIterator |
first, |
|
|
ForwardIterator |
last |
|
) |
| const |
|
inline |
Return the normalized values for a range of values.
Simply applies operator() ( double value ) to all values.
Definition at line 144 of file normalization.hpp.
◆ operator()() [3/3]
std::vector<double> operator() |
( |
std::vector< double > const & |
values | ) |
const |
|
inline |
Return the normalized values for a vector of values
.
Simply applies operator() ( double value ) to all values.
Definition at line 132 of file normalization.hpp.
◆ operator=() [1/2]
◆ operator=() [2/2]
The documentation for this class was generated from the following file: