19#ifndef DDT_DATAVISUALISATION_DDTWIDGETS_COLOURMAPWIDGET_HPP
20#define DDT_DATAVISUALISATION_DDTWIDGETS_COLOURMAPWIDGET_HPP
22#include <QtUiPlugin/QDesignerExportWidget>
46 void mousePressEvent(QMouseEvent* event)
final;
47 void mouseMoveEvent(QMouseEvent* event)
final;
48 void mouseReleaseEvent(QMouseEvent* event)
final;
66 QLabel* colourbar_label;
67 QLabel* colourscale_label;
68 QVector<QRgb> orig_colourmap;
69 QVector<QRgb> current_colourmap;
70 int colourbar_clicked_pos_x;
71 const int MAX_COLOR_MAP_ENTRIES = 256;
72 const int MAX_COLOR_MAP_VALUE = 255;
73 const int PIXMAP_HEIGHT = 20;
75 std::atomic<bool> inverted;
90 void ConvertAndEmit();
95 void ShiftColourmap();
100 void RotateColourmap();
105 void ScaleColourmap();
110 void UpdateColourmap(QVector<QRgb> colourmap);
115 void ResetColourmap();
117 int GetPosX(
const QPoint pos)
const;
119 void UpdateColourscale(
double min_value,
double max_value,
120 int scaling_function);
121 void DrawScale(
double min_value,
double max_value, QPainter& painter,
122 int scaling_function);
123 void DrawScaleLog(
double min_value,
double max_value, QPainter& painter);
124 int CalculateTickPositionLinear(
double tick,
double min_value,
double width,
126 int CalculateTickPositionSqrt(
double tick,
double min_value,
double width,
129 void enterEvent(QEvent*
const event)
override;
130 void leaveEvent(QEvent*
const event)
override;
137 void SetCurrentColourmap(QVector<QRgb> colourmap);
146 void UpdateColourbarAxis(
double min_value,
double max_value,
147 int scaling_function);
158 void InvertColourmap(
const bool invert);
Image Handling class, offers access to image handling functions. This file is part of the DDT Image H...
std::array< std::array< float, COLOR_MAP_ENTRY_SIZE >, MAX_COLOR_MAP_ENTRIES > colorMap_t
Definition: imageColor.hpp:57
std::array< unsigned int, MAX_COLOR_MAP_ENTRIES > colorMapARGB_t
Definition: imageColor.hpp:67