MIRA
Classes | Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | List of all members
Colormap Class Referenceabstract

Base class for color colormaps. More...

#include <image/Colormap.h>

Inheritance diagram for Colormap:
Inheritance graph
[legend]

Classes

class  iterator
 Iterator that can iterate over the whole color colormap similar to STL iterators on containers. More...
 

Public Types

typedef iterator const_iterator
 

Public Member Functions

virtual std::size_t size () const =0
 Returns the number of elements in the colormap. More...
 
virtual Color::RGB get (std::size_t idx) const =0
 Returns the color in the colormap at the given index. More...
 
Color::RGB operator() (std::size_t idx)
 Returns the color in the colormap at the given index. More...
 
Color::RGB operator[] (std::size_t idx)
 Returns the color in the colormap at the given index. More...
 
iterator begin ()
 Gives an iterator to the beginning of the colormap. More...
 
const_iterator begin () const
 Gives a const iterator to the beginning of the colormap. More...
 
iterator end ()
 Gives an iterator to the end of the colormap. More...
 
const_iterator end () const
 Gives an const iterator to the end of the colormap. More...
 
Class const & getClass () const
 call the virtual internalGetClass(). More...
 

Static Public Member Functions

static PseudoClass const & CLASS ()
 

Protected Member Functions

virtual Class const & internalGetClass () const =0
 

Detailed Description

Base class for color colormaps.

Member Typedef Documentation

◆ const_iterator

Member Function Documentation

◆ size()

virtual std::size_t size ( ) const
pure virtual

Returns the number of elements in the colormap.

Some colormaps like ContinuousColormap can be resized dynamically.

Implemented in TabularColormap, and ContinuousColormap.

◆ get()

virtual Color::RGB get ( std::size_t  idx) const
pure virtual

Returns the color in the colormap at the given index.

Implemented in TabularColormap, and ContinuousColormap.

◆ operator()()

Color::RGB operator() ( std::size_t  idx)
inline

Returns the color in the colormap at the given index.

◆ operator[]()

Color::RGB operator[] ( std::size_t  idx)
inline

Returns the color in the colormap at the given index.

◆ begin() [1/2]

iterator begin ( )
inline

Gives an iterator to the beginning of the colormap.

◆ begin() [2/2]

const_iterator begin ( ) const
inline

Gives a const iterator to the beginning of the colormap.

◆ end() [1/2]

iterator end ( )
inline

Gives an iterator to the end of the colormap.

◆ end() [2/2]

const_iterator end ( ) const
inline

Gives an const iterator to the end of the colormap.

◆ getClass()

Class const& getClass ( ) const
inlineinherited

call the virtual internalGetClass().

◆ CLASS()

static PseudoClass const& CLASS ( )
inlinestaticinherited

◆ internalGetClass()

virtual Class const& internalGetClass ( ) const
protectedpure virtualinherited

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