#ifndef MAGNIFIERWIDGET_H
#define MAGNIFIERWIDGET_H

#include <QWidget>

class MagnifierWidget : public QWidget
{
    Q_OBJECT
public:
    explicit MagnifierWidget(QWidget *parent = 0);
    MagnifierWidget(int w, int h, QWidget *parent);

    void setZoomRegionCenter(int x, int y);
    void setLoupeScale(float value);
    void setLoupePixmap(QPixmap pix);

protected:
    void paintEvent(QPaintEvent *);

signals:

public slots:

private:
    QPixmap srcPixmap;
    QPixmap scaledRoiPixmap;

    float loupeScale;
    int zoomRegionCenterX;
    int zoomRegionCenterY;

    int widgetWidth;
    int widgetHeight;
};

#endif // MAGNIFIERWIDGET_H
