#ifndef ADJUSTPICTUREDIALOG_H
#define ADJUSTPICTUREDIALOG_H

#include <QDialog>
#include <QGraphicsScene>

namespace Ui {
class AdjustPictureDialog;
}

class AdjustPictureDialog : public QDialog
{
    Q_OBJECT

public:
    explicit AdjustPictureDialog(QWidget *parent = nullptr, std::string imagePath = "");
    ~AdjustPictureDialog();
    std::string decode();
    QPixmap pixmap;
    QImage img;

    void computeContrastLookupTable();
    std::vector<unsigned short> contrastLUT[100];
signals:
    void decodedData(std::string data);

private slots:

    // void on_buttonBox_accepted();
    void accept() override;

    void on_contrastSlider_sliderMoved(int position);

private:
    Ui::AdjustPictureDialog *ui;
    QGraphicsScene *scene;
};

#endif // ADJUSTPICTUREDIALOG_H
