diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2014-10-12 16:10:23 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2014-10-12 16:10:23 +0200 |
commit | 2de1c44a994fb72142ef020546efcd22ac8c6a83 (patch) | |
tree | 34551a02053a354a834e085b09ba274785159edd /ftnoir_tracker_aruco/ar_video_widget.h | |
parent | a63156fc2cddccf03c2e2959df50a2bcc0585f2a (diff) |
aruco cleanup, experimental contrast fix
Diffstat (limited to 'ftnoir_tracker_aruco/ar_video_widget.h')
-rw-r--r-- | ftnoir_tracker_aruco/ar_video_widget.h | 22 |
1 files changed, 7 insertions, 15 deletions
diff --git a/ftnoir_tracker_aruco/ar_video_widget.h b/ftnoir_tracker_aruco/ar_video_widget.h index e2cf4d9f..820ba7d0 100644 --- a/ftnoir_tracker_aruco/ar_video_widget.h +++ b/ftnoir_tracker_aruco/ar_video_widget.h @@ -22,26 +22,18 @@ class ArucoVideoWidget : public QWidget { Q_OBJECT - -public: - ArucoVideoWidget(QWidget *parent) : QWidget(parent) { - connect(&timer, SIGNAL(timeout()), this, SLOT(update_and_repaint())); - timer.start(60); - } - void update_image(const cv::Mat& frame); -protected slots: - void paintEvent( QPaintEvent* e ) { - QMutexLocker foo(&mtx); - QPainter painter(this); - painter.drawImage(e->rect(), texture); - } - void update_and_repaint(); - + private: QMutex mtx; QImage texture; QTimer timer; cv::Mat _frame; +private slots: + void update_and_repaint(); +public: + ArucoVideoWidget(QWidget *parent); + void update_image(const cv::Mat& frame); + void paintEvent( QPaintEvent*) override; }; #endif // VIDEOWIDGET_H |