18 #ifndef VIDEOZOOMWIDGET_H
19 #define VIDEOZOOMWIDGET_H
21 #include "sharedframe.h"
26 class VideoZoomWidget :
public QWidget
40 explicit VideoZoomWidget();
45 QPoint getSelectedPixel();
46 void setSelectedPixel(QPoint pixel);
49 PixelValues getPixelValues(
const QPoint& pixel);
50 void setOffset(QPoint offset);
53 void pixelSelected(
const QPoint&);
54 void zoomChanged(
int zoom);
57 void lock(
bool locked);
60 virtual QSize sizeHint() const Q_DECL_OVERRIDE;
62 void paintEvent(QPaintEvent*) Q_DECL_OVERRIDE;
63 void mouseMoveEvent(QMouseEvent *event)Q_DECL_OVERRIDE;
64 void mousePressEvent(QMouseEvent *event)Q_DECL_OVERRIDE;
65 void wheelEvent(QWheelEvent *event)Q_DECL_OVERRIDE;
67 QPoint pixelToPos(const QPoint& pixel);
68 QPoint posToPixel(const QPoint& pos);
69 PixelValues pixelToValues(const QPoint& pixel);
72 bool m_selectionInProgress;
75 QPoint m_mouseGrabPixel;
76 QPoint m_selectedPixel;
83 #endif // VIDEOZOOMWIDGET_H