summaryrefslogtreecommitdiffhomepage
path: root/tracker-fusion/fusion.h
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2017-05-27 12:35:05 +0200
committerStanislaw Halik <sthalik@misaki.pl>2017-05-28 03:06:37 +0200
commit4b68e4e6104ff4b9c1e6857cf22edc568e68ec5e (patch)
tree1481341dde394227f6ec147b8f350f9c81d46b73 /tracker-fusion/fusion.h
parent4be9a6542e03b07fc6edeeb3b1fb0a7b2b2108eb (diff)
tracker/fusion: use translation-neutral module ident
Also, manage QLibrary lifetime to a minimum. They are refcounted internally anyway. Remove bogus assert -- video feed trackers drop the layout on their own typically.
Diffstat (limited to 'tracker-fusion/fusion.h')
-rw-r--r--tracker-fusion/fusion.h27
1 files changed, 13 insertions, 14 deletions
diff --git a/tracker-fusion/fusion.h b/tracker-fusion/fusion.h
index a943fe06..28e584da 100644
--- a/tracker-fusion/fusion.h
+++ b/tracker-fusion/fusion.h
@@ -1,6 +1,7 @@
#pragma once
#include "api/plugin-api.hpp"
#include "api/plugin-support.hpp"
+#include <QObject>
#include <QFrame>
#include <QCoreApplication>
@@ -9,35 +10,33 @@ using namespace options;
struct fusion_settings final : opts
{
- value<QString> rot_tracker_name;
- value<QString> pos_tracker_name;
+ value<QVariant> rot_tracker_name, pos_tracker_name;
fusion_settings();
};
-struct has_modules
+class fusion_tracker : public QObject, public ITracker
{
- Modules modules;
- has_modules();
-};
-
-struct fusion_tracker : public ITracker, has_modules
-{
- fusion_tracker();
- ~fusion_tracker() override;
- void start_tracker(QFrame *) override;
- void data(double *data) override;
+ Q_OBJECT
double rot_tracker_data[6], pos_tracker_data[6];
std::unique_ptr<QFrame> other_frame;
std::shared_ptr<dylib> rot_dylib, pos_dylib;
std::shared_ptr<ITracker> rot_tracker, pos_tracker;
+
+public:
+ fusion_tracker();
+ ~fusion_tracker() override;
+ void start_tracker(QFrame*) override;
+ void data(double* data) override;
+
+ static const QString& caption();
};
#include "ui_fusion.h"
-class fusion_dialog : public ITrackerDialog, has_modules
+class fusion_dialog : public ITrackerDialog
{
Q_OBJECT