diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2019-02-03 08:13:50 +0100 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2019-02-03 08:15:45 +0100 |
commit | 4ca4b13b62426c7f6921d88f72cd0a15986dca29 (patch) | |
tree | ffebcb4db25f09fe58413f8ad8d66abab1460828 /tracker-aruco/ftnoir_tracker_aruco.cpp | |
parent | 1beb7dfe8cd9a288893783862ce9f2e4a39239ab (diff) |
tracker/aruco: avoid busy-loop on camera failure
Diffstat (limited to 'tracker-aruco/ftnoir_tracker_aruco.cpp')
-rw-r--r-- | tracker-aruco/ftnoir_tracker_aruco.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/tracker-aruco/ftnoir_tracker_aruco.cpp b/tracker-aruco/ftnoir_tracker_aruco.cpp index bddec739..986eb943 100644 --- a/tracker-aruco/ftnoir_tracker_aruco.cpp +++ b/tracker-aruco/ftnoir_tracker_aruco.cpp @@ -374,7 +374,10 @@ void aruco_tracker::run() QMutexLocker l(&camera_mtx); if (!camera.read(color)) + { + portable::sleep(100); continue; + } } cv::cvtColor(color, grayscale, cv::COLOR_BGR2GRAY); |