g4tools  5.4.0
Public Member Functions | List of all members
tools::sg::const_colormap Class Reference
Inheritance diagram for tools::sg::const_colormap:
Inheritance graph
[legend]
Collaboration diagram for tools::sg::const_colormap:
Collaboration graph
[legend]

Public Member Functions

virtual void get_color (float, colorf &a_col) const
 
virtual void * cast (const std::string &a_class) const
 
 const_colormap (const colorf &aColor)
 
 const_colormap (const const_colormap &aFrom)
 
const_colormapoperator= (const const_colormap &aFrom)
 
virtual ~const_colormap ()
 
- Public Member Functions inherited from tools::sg::base_colormap
 base_colormap ()
 
 base_colormap (const base_colormap &aFrom)
 
base_colormapoperator= (const base_colormap &aFrom)
 
virtual ~base_colormap ()
 
size_t colorn () const
 
size_t valn () const
 
colorf color (size_t a_index) const
 
float value (size_t a_index) const
 
void set_colors (void(*aGet)(float, colorf &), size_t a_ncell)
 
void set_PAW_coloring ()
 

Additional Inherited Members

- Static Protected Member Functions inherited from tools::sg::base_colormap
static float take_log (float aVal)
 
- Protected Attributes inherited from tools::sg::base_colormap
std::vector< float > m_values
 
std::vector< colorfm_colors
 

Detailed Description

Definition at line 415 of file colormap.

Constructor & Destructor Documentation

◆ const_colormap() [1/2]

tools::sg::const_colormap::const_colormap ( const colorf aColor)
inline

Definition at line 427 of file colormap.

427 {m_colors.push_back(aColor);}

◆ const_colormap() [2/2]

tools::sg::const_colormap::const_colormap ( const const_colormap aFrom)
inline

Definition at line 428 of file colormap.

428 :base_colormap(aFrom){}

◆ ~const_colormap()

virtual tools::sg::const_colormap::~const_colormap ( )
inlinevirtual

Definition at line 433 of file colormap.

433 {}

Member Function Documentation

◆ cast()

virtual void* tools::sg::const_colormap::cast ( const std::string &  a_class) const
inlinevirtual

Implements tools::sg::base_colormap.

Definition at line 422 of file colormap.

422  {
423  if(void* p = cmp_cast<const_colormap>(this,a_class)) {return p;}
424  else return 0;
425  }

◆ get_color()

virtual void tools::sg::const_colormap::get_color ( float  ,
colorf a_col 
) const
inlinevirtual

Implements tools::sg::base_colormap.

Definition at line 419 of file colormap.

419  { //a_value in [0,1]
420  a_col = m_colors[0];
421  }

◆ operator=()

const_colormap& tools::sg::const_colormap::operator= ( const const_colormap aFrom)
inline

Definition at line 429 of file colormap.

429  {
431  return *this;
432  }

The documentation for this class was generated from the following file:
tools::sg::base_colormap::m_colors
std::vector< colorf > m_colors
Definition: colormap:102
tools::sg::base_colormap::operator=
base_colormap & operator=(const base_colormap &aFrom)
Definition: colormap:40
tools::sg::base_colormap::base_colormap
base_colormap()
Definition: colormap:29