Node class to define a non linear data mapping.
More...
#include <MeshViz/nodes/PoNonLinearDataMapping.h>
Public Types | |
| typedef const SbColor * | PoDataMappingColorCB (float value) |
| typedef const SbColor * | PoDataMappingColorCB2 (void *userData, float value) |
| typedef float | PoDataMappingTransparencyCB (float value) |
| typedef float | PoDataMappingTransparencyCB2 (void *userData, float value) |
Public Member Functions | |
| virtual SoType | getTypeId () const |
| PoNonLinearDataMapping () | |
| void | setColorFunction (PoDataMappingColorCB2 *func, void *userData) |
| void | setColorFunction (PoDataMappingColorCB *func) |
| void | setTransparencyFunction (PoDataMappingTransparencyCB2 *func, void *userData) |
| void | setTransparencyFunction (PoDataMappingTransparencyCB *func) |
| virtual const SbColor * | getColor (float value) |
| virtual const SbColor * | getColor (float value, float &transparency) |
Static Public Member Functions | |
| static SoType | getClassTypeId () |
Node class to define a non linear data mapping.
This node defines the current data mapping for all subsequent MeshViz representations which use it. There is no data mapping until a PoDataMapping node is traversed.
This node defines a non linear association between colors, transparencies and floating-point values. In other words, this association is defined by 2 functions F(c,v) and F(c,t):
F(c,v)(V) = C (with c being a color and v being a value).
F(t,v)(V) = T (with t being a transparency and v being a value).
F(c,v) and F(t,v) are given by the user. If they are not given by the user, default one are used. The default F(c,v) computes a linear data mapping between black and white. The default F(c,t) returns always 0.
| typedef const SbColor* PoNonLinearDataMapping::PoDataMappingColorCB(float value) |
Color callback prototype.
| typedef const SbColor* PoNonLinearDataMapping::PoDataMappingColorCB2(void *userData, float value) |
Color callback prototype.
| typedef float PoNonLinearDataMapping::PoDataMappingTransparencyCB(float value) |
Transparency callback prototype.
| typedef float PoNonLinearDataMapping::PoDataMappingTransparencyCB2(void *userData, float value) |
Transparency callback prototype.
| PoNonLinearDataMapping::PoNonLinearDataMapping | ( | ) |
Constructor.
| static SoType PoNonLinearDataMapping::getClassTypeId | ( | ) | [static] |
Returns the type identifier for this class.
Reimplemented from PoDataMapping.
| virtual const SbColor* PoNonLinearDataMapping::getColor | ( | float | value, | |
| float & | transparency | |||
| ) | [virtual] |
Returns the color and transparency associated to a value.
Implements PoDataMapping.
| virtual const SbColor* PoNonLinearDataMapping::getColor | ( | float | value | ) | [virtual] |
Returns the color associated to a value.
Implements PoDataMapping.
| virtual SoType PoNonLinearDataMapping::getTypeId | ( | ) | const [virtual] |
Returns the type identifier for this specific instance.
Reimplemented from PoDataMapping.
| void PoNonLinearDataMapping::setColorFunction | ( | PoDataMappingColorCB * | func | ) |
Deprecated.
| void PoNonLinearDataMapping::setColorFunction | ( | PoDataMappingColorCB2 * | func, | |
| void * | userData | |||
| ) |
Sets pointer to a callback function which computes a color from a real value.
| void PoNonLinearDataMapping::setTransparencyFunction | ( | PoDataMappingTransparencyCB * | func | ) |
Deprecated.
| void PoNonLinearDataMapping::setTransparencyFunction | ( | PoDataMappingTransparencyCB2 * | func, | |
| void * | userData | |||
| ) |
Sets pointer to a callback function which computes a transparency from a real value.