#include <ColourMapper.h>
Definition at line 27 of file ColourMapper.h.
Public Types | |
| enum | StandardMap { DefaultColours, Sunset, WhiteOnBlack, BlackOnWhite, RedOnBlue, YellowOnBlack, BlueOnBlack, FruitSalad, Banded, Highlight, Printer } |
Public Member Functions | |
| ColourMapper (int map, float minValue, float maxValue) | |
| virtual | ~ColourMapper () |
| int | getMap () const |
| float | getMinValue () const |
| float | getMaxValue () const |
| QColor | map (float value) const |
| QColor | getContrastingColour () const |
| bool | hasLightBackground () const |
Static Public Member Functions | |
| static int | getColourMapCount () |
| static QString | getColourMapName (int n) |
Protected Attributes | |
| int | m_map |
| float | m_min |
| float | m_max |
| DefaultColours | |
| Sunset | |
| WhiteOnBlack | |
| BlackOnWhite | |
| RedOnBlue | |
| YellowOnBlack | |
| BlueOnBlack | |
| FruitSalad | |
| Banded | |
| Highlight | |
| Printer |
Definition at line 35 of file ColourMapper.h.
| ColourMapper::ColourMapper | ( | int | map, | |
| float | minValue, | |||
| float | maxValue | |||
| ) |
| ColourMapper::~ColourMapper | ( | ) | [virtual] |
Definition at line 35 of file ColourMapper.cpp.
| int ColourMapper::getMap | ( | ) | const [inline] |
| float ColourMapper::getMinValue | ( | ) | const [inline] |
| float ColourMapper::getMaxValue | ( | ) | const [inline] |
| int ColourMapper::getColourMapCount | ( | ) | [static] |
Definition at line 40 of file ColourMapper.cpp.
Referenced by getColourMapName(), getContrastingColour(), TimeValueLayer::getPropertyRangeAndValue(), SpectrogramLayer::getPropertyRangeAndValue(), SliceLayer::getPropertyRangeAndValue(), Colour3DPlotLayer::getPropertyRangeAndValue(), hasLightBackground(), and map().
| QString ColourMapper::getColourMapName | ( | int | n | ) | [static] |
Definition at line 46 of file ColourMapper.cpp.
References Banded, BlackOnWhite, BlueOnBlack, DefaultColours, FruitSalad, getColourMapCount(), Highlight, map(), Printer, RedOnBlue, Sunset, WhiteOnBlack, and YellowOnBlack.
Referenced by TimeValueLayer::getPropertyValueLabel(), SpectrogramLayer::getPropertyValueLabel(), SliceLayer::getPropertyValueLabel(), and Colour3DPlotLayer::getPropertyValueLabel().
| QColor ColourMapper::map | ( | float | value | ) | const |
Definition at line 69 of file ColourMapper.cpp.
References Banded, BlackOnWhite, BlueOnBlack, DefaultColours, FruitSalad, getColourMapCount(), Highlight, m_map, m_max, m_min, Printer, RedOnBlue, Sunset, WhiteOnBlack, and YellowOnBlack.
Referenced by Colour3DPlotLayer::fillCache(), getColourMapName(), getContrastingColour(), hasLightBackground(), SpectrogramLayer::initialisePalette(), SpectrumLayer::paint(), and SliceLayer::paint().
| QColor ColourMapper::getContrastingColour | ( | ) | const |
Definition at line 193 of file ColourMapper.cpp.
References Banded, BlackOnWhite, BlueOnBlack, DefaultColours, FruitSalad, getColourMapCount(), Highlight, m_map, map(), Printer, RedOnBlue, Sunset, WhiteOnBlack, and YellowOnBlack.
Referenced by SpectrogramLayer::initialisePalette(), and SpectrumLayer::paintCrosshairs().
| bool ColourMapper::hasLightBackground | ( | ) | const |
Definition at line 238 of file ColourMapper.cpp.
References BlackOnWhite, getColourMapCount(), m_map, map(), and Printer.
int ColourMapper::m_map [protected] |
Definition at line 62 of file ColourMapper.h.
Referenced by getContrastingColour(), getMap(), hasLightBackground(), and map().
float ColourMapper::m_min [protected] |
Definition at line 63 of file ColourMapper.h.
Referenced by ColourMapper(), getMinValue(), and map().
float ColourMapper::m_max [protected] |
Definition at line 64 of file ColourMapper.h.
Referenced by ColourMapper(), getMaxValue(), and map().
1.5.1