Open Inventor Release 2024.2.0
 
Loading...
Searching...
No Matches
MiColorMapping< _TValue, _TColor > Class Template Referenceabstract

MeshViz Interface class defining a color mapping function. More...

#include <MeshVizXLM/mapping/interfaces/MiColorMapping.h>

Public Member Functions

virtual ~MiColorMapping ()
 
virtual _TColor getColor (_TValue value) const =0
 Returns the color associated with the given value.
 
virtual void getRange (_TValue &min, _TValue &max) const
 Returns the range of values for the colormap.
 
virtual size_t getTimeStamp () const =0
 Returns for this colormap a unique time stamp across all colormaps in the application.
 

Detailed Description

template<typename _TValue, typename _TColor>
class MiColorMapping< _TValue, _TColor >

MeshViz Interface class defining a color mapping function.

This abstract class specifies the interface used to map a value of a scalar data set to a color. It is used when displaying scalar data sets as colors.

In order to define a custom color mapping, create a class derived from this class.

Definition at line 43 of file MiColorMapping.h.

Constructor & Destructor Documentation

◆ ~MiColorMapping()

template<typename _TValue , typename _TColor >
virtual MiColorMapping< _TValue, _TColor >::~MiColorMapping ( )
inlinevirtual

Definition at line 46 of file MiColorMapping.h.

Member Function Documentation

◆ getColor()

template<typename _TValue , typename _TColor >
virtual _TColor MiColorMapping< _TValue, _TColor >::getColor ( _TValue  value) const
pure virtual

Returns the color associated with the given value.

◆ getRange()

template<typename _TValue , typename _TColor >
virtual void MiColorMapping< _TValue, _TColor >::getRange ( _TValue &  min,
_TValue &  max 
) const
inlinevirtual

Returns the range of values for the colormap.

Note
This method should be pure virtual, but, for compatibility reasons, it throws an exception instead.

Definition at line 57 of file MiColorMapping.h.

◆ getTimeStamp()

template<typename _TValue , typename _TColor >
virtual size_t MiColorMapping< _TValue, _TColor >::getTimeStamp ( ) const
pure virtual

Returns for this colormap a unique time stamp across all colormaps in the application.

When the content of the colormap changes, the time stamp must increase. The time stamp allows representations to identify this colormap and to be aware of any changes to it.

Note
MxTimeStamp can be used to generate a valid time stamp.

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