diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2021-08-29 03:14:46 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2021-08-29 03:54:17 +0200 |
commit | 48d1d1a06eb6acad0b0f436dcc73a19b408edb32 (patch) | |
tree | b4cc0710af11622ea2f05c1a8f14200943e98d9c /tracker-pt/module | |
parent | a3fa8fe6f6b783358a107f3779f65249291a190d (diff) |
tracker/{pt,wii}: pass camera options through bundle
Diffstat (limited to 'tracker-pt/module')
-rw-r--r-- | tracker-pt/module/camera.cpp | 5 | ||||
-rw-r--r-- | tracker-pt/module/camera.h | 2 |
2 files changed, 5 insertions, 2 deletions
diff --git a/tracker-pt/module/camera.cpp b/tracker-pt/module/camera.cpp index a70698de..99bea617 100644 --- a/tracker-pt/module/camera.cpp +++ b/tracker-pt/module/camera.cpp @@ -73,8 +73,11 @@ Camera::result Camera::get_frame(pt_frame& frame_) return { false, {} }; } -bool Camera::start(const QString& name, int fps, int res_x, int res_y) +bool Camera::start(const pt_settings& s) { + int fps = s.cam_fps, res_x = s.cam_res_x, res_y = s.cam_res_y; + QString name = s.camera_name; + if (fps >= 0 && res_x >= 0 && res_y >= 0) { if (cam_desired.name != name || diff --git a/tracker-pt/module/camera.h b/tracker-pt/module/camera.h index e2ba159f..f9b62282 100644 --- a/tracker-pt/module/camera.h +++ b/tracker-pt/module/camera.h @@ -23,7 +23,7 @@ struct Camera final : pt_camera { Camera(const QString& module_name); - bool start(const QString& name, int fps, int res_x, int res_y) override; + bool start(const pt_settings& s) override; void stop() override; result get_frame(pt_frame& Frame) override; |