18#ifndef VIDEOZOOMWIDGET_H
19#define VIDEOZOOMWIDGET_H
21#include "sharedframe.h"
26class VideoZoomWidget :
public QWidget
41 explicit VideoZoomWidget();
44 void putFrame(SharedFrame frame);
46 QPoint getSelectedPixel();
47 void setSelectedPixel(QPoint pixel);
50 PixelValues getPixelValues(
const QPoint &pixel);
51 void setOffset(QPoint offset);
54 void pixelSelected(
const QPoint &);
55 void zoomChanged(
int zoom);
58 void lock(
bool locked);
61 virtual QSize sizeHint() const Q_DECL_OVERRIDE;
63 void paintEvent(QPaintEvent *) Q_DECL_OVERRIDE;
64 void mouseMoveEvent(QMouseEvent *event) Q_DECL_OVERRIDE;
65 void mousePressEvent(QMouseEvent *event) Q_DECL_OVERRIDE;
66 void wheelEvent(QWheelEvent *event) Q_DECL_OVERRIDE;
68 QPoint pixelToPos(const QPoint &pixel);
69 QPoint posToPixel(const QPoint &pos);
70 PixelValues pixelToValues(const QPoint &pixel);
73 bool m_selectionInProgress;
76 QPoint m_mouseGrabPixel;
77 QPoint m_selectedPixel;