master
Hannes Matuschek 12 years ago
parent 86900ecc89
commit f4202d46b1

@ -23,8 +23,8 @@ ColorMap::~ColorMap() {
/* ****************************************************************************************** * /* ****************************************************************************************** *
* Implementation of GrayScaleColorMap * Implementation of GrayScaleColorMap
* ****************************************************************************************** */ * ****************************************************************************************** */
GrayScaleColorMap::GrayScaleColorMap(double mindB) GrayScaleColorMap::GrayScaleColorMap(double min, double max)
: ColorMap(mindB, 0) : ColorMap(min, max)
{ {
// pass... // pass...
} }
@ -49,7 +49,7 @@ WaterFallView::WaterFallView(Spectrum *spectrum, size_t height, QWidget *parent)
// Fill waterfall pixmap // Fill waterfall pixmap
_waterfall.fill(Qt::black); _waterfall.fill(Qt::black);
// Create color map // Create color map
_colorMap = new GrayScaleColorMap(); _colorMap = new GrayScaleColorMap(-120, 0);
// Get notified once a new spectrum is available: // Get notified once a new spectrum is available:
QObject::connect(_spectrum, SIGNAL(spectrumUpdated()), this, SLOT(_onSpectrumUpdated())); QObject::connect(_spectrum, SIGNAL(spectrumUpdated()), this, SLOT(_onSpectrumUpdated()));

@ -43,9 +43,9 @@ class GrayScaleColorMap: public ColorMap
{ {
public: public:
/** Constructor. /** Constructor.
* @param mindB Specifices the minimum value in dB of the color-scale. Mapping values [0, mindB] * @param mindB Specifices the minimum value in dB of the color-scale. Mapping values [min, max]
* to a gray-scale. */ * to a gray-scale. */
GrayScaleColorMap(double mindB=-120); GrayScaleColorMap(double min, double max);
/** Destructor. */ /** Destructor. */
virtual ~GrayScaleColorMap(); virtual ~GrayScaleColorMap();
/** Implements the color mapping. */ /** Implements the color mapping. */

Loading…
Cancel
Save