summaryrefslogtreecommitdiffhomepage
path: root/proto-ft/ftnoir_protocol_ft.h
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2018-05-22 17:09:19 +0200
committerStanislaw Halik <sthalik@misaki.pl>2018-05-22 17:09:19 +0200
commit9a6ca1e6dce0b7e29b7a47c0ea7b47dd4266f18f (patch)
treed0bde87dd5d1a96fcc86b5b7102526bbb8e6ec0c /proto-ft/ftnoir_protocol_ft.h
parentdec40bea45d222a1a2447ca126631bc744ba7faa (diff)
proto/ft: revert npclient-related changes
Diffstat (limited to 'proto-ft/ftnoir_protocol_ft.h')
-rw-r--r--proto-ft/ftnoir_protocol_ft.h29
1 files changed, 13 insertions, 16 deletions
diff --git a/proto-ft/ftnoir_protocol_ft.h b/proto-ft/ftnoir_protocol_ft.h
index 18a5596f..4ddda8de 100644
--- a/proto-ft/ftnoir_protocol_ft.h
+++ b/proto-ft/ftnoir_protocol_ft.h
@@ -7,21 +7,21 @@
*/
#pragma once
-
#include "ui_ftnoir_ftcontrols.h"
-
-#include "freetrackclient/fttypes.h"
-
-#include "compat/shm.h"
-#include "compat/tr.hpp"
-#include "options/options.hpp"
#include "api/plugin-api.hpp"
#include <QProcess>
#include <QString>
#include <QMutex>
+#include <QDebug>
+
#include <cinttypes>
+#include "freetrackclient/fttypes.h"
+
+#include "compat/shm.h"
+#include "options/options.hpp"
+
#include <memory>
using namespace options;
@@ -34,30 +34,26 @@ struct settings : opts {
{}
};
-class freetrack : public TR, public IProtocol
+class freetrack : TR, public IProtocol
{
Q_OBJECT
public:
- freetrack();
+ freetrack() = default;
~freetrack() override;
module_status initialize() override;
- void pose( const double *headpose );
- QString game_name() override {
- QMutexLocker foo(&game_name_mutex);
- return connected_game;
- }
+ void pose(const double* pose) override;
+ QString game_name() override;
private:
settings s;
shm_wrapper shm { FREETRACK_HEAP, FREETRACK_MUTEX, sizeof(FTHeap) };
- FTHeap *pMemData { (FTHeap*) shm.ptr() };
+ FTHeap* pMemData { (FTHeap*) shm.ptr() };
QProcess dummyTrackIR;
int intGameID = -1;
QString connected_game;
QMutex game_name_mutex;
- unsigned data_id = 0;
void start_dummy();
static float degrees_to_rads(double degrees);
@@ -86,6 +82,7 @@ class freetrackDll : public Metadata
{
Q_OBJECT
+public:
QString name() { return tr("freetrack 2.0 Enhanced"); }
QIcon icon() { return QIcon(":/images/freetrack.png"); }
};