summaryrefslogtreecommitdiffhomepage
path: root/tracker-rs/ftnoir_tracker_rs_worker.h
diff options
context:
space:
mode:
authorXavier Hallade <xavier.hallade@intel.com>2016-02-03 23:40:48 +0100
committerXavier Hallade <xavier.hallade@intel.com>2016-02-03 23:40:48 +0100
commitf41f404de607b4f8f5aa270e36ae7c43baf63862 (patch)
tree662e30d2765275a13fbff952135b134802168a20 /tracker-rs/ftnoir_tracker_rs_worker.h
parente3044329f73fcfb136bb8316df87c4bafd2c2bee (diff)
tracker/rs: added camera preview, removed separate process and TCP socket
the RS implementation still resides in a different DLL as it has to be compiled separately by MSVC compiler.
Diffstat (limited to 'tracker-rs/ftnoir_tracker_rs_worker.h')
-rw-r--r--tracker-rs/ftnoir_tracker_rs_worker.h38
1 files changed, 38 insertions, 0 deletions
diff --git a/tracker-rs/ftnoir_tracker_rs_worker.h b/tracker-rs/ftnoir_tracker_rs_worker.h
new file mode 100644
index 00000000..098d6c10
--- /dev/null
+++ b/tracker-rs/ftnoir_tracker_rs_worker.h
@@ -0,0 +1,38 @@
+/*
+ * Copyright (c) 2015, Intel Corporation
+ * Author: Xavier Hallade <xavier.hallade@intel.com>
+ * Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies.
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ */
+
+#pragma once
+
+#include <QThread>
+#include <QMutex>
+
+class RSTrackerWorkerThread : public QThread
+{
+ Q_OBJECT
+
+public:
+ RSTrackerWorkerThread();
+ ~RSTrackerWorkerThread();
+
+ void getPose(double* pose);
+ const QImage getPreview();
+
+protected:
+ void run() override;
+
+private:
+ double mPose[6];
+ uchar* mPreviewRawData;
+ QMutex mMutex;
+ const int kPreviewStreamWidth = 640;
+ const int kPreviewStreamHeight = 480;
+
+signals:
+ void trackingHasStarted();
+ void trackingHasFinished(int);
+
+};