
Simple colormaps with N colors. More...
#include <Image/ColorMap.H>


Public Member Functions | |
| ColorMap () | |
| Default constructor (empty colormap). | |
| ColorMap (const int n) | |
| Default constructor (uninitialized color values, n entries). | |
| ColorMap (const Image< PixRGB< byte > > &cmap) | |
| Build from an Image of pixels (used by the pseudo-constructors). | |
| virtual | ~ColorMap () |
| Destructor. | |
Static Public Member Functions | |
| static ColorMap | GREY (const int n=256) |
| Pseudo-constructor for a greyscale with n entries. | |
| static ColorMap | GRADIENT (const PixRGB< byte > &from, const PixRGB< byte > &to, const int n=256) |
| Pseudo-constructor for a transition from 'from' to 'to' with n entries. | |
| static ColorMap | JET (const int n=256) |
| Pseudo-constructor for "jet" colormap a la matlab. | |
| static ColorMap | LINES (const int n=256) |
| Pseudo-constructor for "lines" colormap a la matlab. | |
Simple colormaps with N colors.
ColorMap derives from Image< PixRGB<byte> > and hence inherits all the associated functions. Here we just provide a bunch of constructors. A ColorMap then is merely an Image< PixRGB<byte> > of width N and height 1.
Definition at line 49 of file ColorMap.H.
| ColorMap::ColorMap | ( | ) |
Default constructor (empty colormap).
Definition at line 47 of file ColorMap.C.
Referenced by GRADIENT(), GREY(), JET(), and LINES().
| ColorMap::ColorMap | ( | const int | n | ) |
Default constructor (uninitialized color values, n entries).
Definition at line 52 of file ColorMap.C.
Build from an Image of pixels (used by the pseudo-constructors).
Will throw a fatal error if cmap has height != 1
Definition at line 57 of file ColorMap.C.
References Image< PixRGB< byte > >::getHeight().
| ColorMap::~ColorMap | ( | ) | [virtual] |
Destructor.
Definition at line 64 of file ColorMap.C.
| ColorMap ColorMap::GRADIENT | ( | const PixRGB< byte > & | from, | |
| const PixRGB< byte > & | to, | |||
| const int | n = 256 | |||
| ) | [static] |
Pseudo-constructor for a transition from 'from' to 'to' with n entries.
Definition at line 78 of file ColorMap.C.
References Image< T >::beginw(), ColorMap(), and NO_INIT.
| ColorMap ColorMap::GREY | ( | const int | n = 256 |
) | [static] |
Pseudo-constructor for a greyscale with n entries.
Definition at line 68 of file ColorMap.C.
References Image< T >::beginw(), ColorMap(), and NO_INIT.
| ColorMap ColorMap::JET | ( | const int | n = 256 |
) | [static] |
Pseudo-constructor for "jet" colormap a la matlab.
Definition at line 93 of file ColorMap.C.
References Image< T >::beginw(), ColorMap(), and NO_INIT.
| ColorMap ColorMap::LINES | ( | const int | n = 256 |
) | [static] |
Pseudo-constructor for "lines" colormap a la matlab.
Definition at line 140 of file ColorMap.C.
References Image< T >::beginw(), ColorMap(), and NO_INIT.
1.6.3