diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2019-05-02 18:50:05 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2019-05-02 18:55:46 +0200 |
commit | 4793e57051bf17620e93f62e2651fc5df1708935 (patch) | |
tree | 806da084534c822d4107e614f46db32c1aef9a96 /tracker-aruco | |
parent | bac58c2d5e45d838e32bc1d5cc0b12a19365c569 (diff) |
tracker/{aruco,easy,pt}: bail out when camera missing
Diffstat (limited to 'tracker-aruco')
-rw-r--r-- | tracker-aruco/ftnoir_tracker_aruco.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tracker-aruco/ftnoir_tracker_aruco.cpp b/tracker-aruco/ftnoir_tracker_aruco.cpp index d9cb2b96..bdb41d44 100644 --- a/tracker-aruco/ftnoir_tracker_aruco.cpp +++ b/tracker-aruco/ftnoir_tracker_aruco.cpp @@ -164,6 +164,10 @@ bool aruco_tracker::open_camera() QMutexLocker l(&camera_mtx); camera = video::make_camera(s.camera_name); + + if (!camera) + return false; + video::impl::camera::info args {}; if (res.width) |