Prepare for three channels STF

This commit is contained in:
2023-10-10 22:48:40 +02:00
parent 0c2c5f908c
commit 0a803ace10
10 changed files with 125 additions and 41 deletions
+14 -1
View File
@@ -2,15 +2,28 @@
#define STRETCHTOOLBAR_H
#include <QToolBar>
#include <QStackedWidget>
#include "stfslider.h"
class Image;
struct MTFParam
{
float blackPoint[3] = {0.0f, 0.0f, 0.0f};
float midPoint[3] = {0.5f, 0.5f, 0.5f};
float whitePoint[3] = {1.0f, 1.0f, 1.0f};
};
class StretchToolbar : public QToolBar
{
Q_OBJECT
STFSlider *m_stfSlider;
STFSlider *m_stfSliderR;
STFSlider *m_stfSliderG;
STFSlider *m_stfSliderB;
QAction *m_autoStretchOnLoad;
QStackedWidget *m_stack;
MTFParam m_mtfParam;
public:
explicit StretchToolbar(QWidget *parent = nullptr);
public slots:
@@ -18,7 +31,7 @@ public slots:
void resetMTF();
void imageLoaded(Image *img);
signals:
void paramChanged(float low, float mid, float high);
void paramChanged(const MTFParam &params);
void autoStretch();
void invert(bool enable);
void superPixel(bool enable);