summaryrefslogtreecommitdiffhomepage
path: root/ftnoir_tracker_aruco/ar_video_widget.cpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2014-10-12 16:10:23 +0200
committerStanislaw Halik <sthalik@misaki.pl>2014-10-12 16:10:23 +0200
commit2de1c44a994fb72142ef020546efcd22ac8c6a83 (patch)
tree34551a02053a354a834e085b09ba274785159edd /ftnoir_tracker_aruco/ar_video_widget.cpp
parenta63156fc2cddccf03c2e2959df50a2bcc0585f2a (diff)
aruco cleanup, experimental contrast fix
Diffstat (limited to 'ftnoir_tracker_aruco/ar_video_widget.cpp')
-rw-r--r--ftnoir_tracker_aruco/ar_video_widget.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/ftnoir_tracker_aruco/ar_video_widget.cpp b/ftnoir_tracker_aruco/ar_video_widget.cpp
index 9a089213..61a611ea 100644
--- a/ftnoir_tracker_aruco/ar_video_widget.cpp
+++ b/ftnoir_tracker_aruco/ar_video_widget.cpp
@@ -40,3 +40,15 @@ void ArucoVideoWidget::update_and_repaint()
texture = qframe2;
update();
}
+
+void ArucoVideoWidget::paintEvent(QPaintEvent* e)
+{
+ QMutexLocker foo(&mtx);
+ QPainter(this).drawImage(e->rect(), texture);
+}
+
+ArucoVideoWidget::ArucoVideoWidget(QWidget* parent): QWidget(parent)
+{
+ connect(&timer, SIGNAL(timeout()), this, SLOT(update_and_repaint()));
+ timer.start(60);
+} \ No newline at end of file