From 09aeee333b807be87f456fa226fc0442d5a37364 Mon Sep 17 00:00:00 2001 From: Stanislaw Halik Date: Wed, 27 Nov 2013 02:32:24 +0100 Subject: make hatire actually buildable Remove 'captain obvious' comments, references to , fix spelling errors, use UI layouts, and so on Signed-off-by: Stanislaw Halik --- ftnoir_tracker_hatire/ftnoir_tracker_hat.h | 59 +++++++++++------------------- 1 file changed, 21 insertions(+), 38 deletions(-) (limited to 'ftnoir_tracker_hatire/ftnoir_tracker_hat.h') diff --git a/ftnoir_tracker_hatire/ftnoir_tracker_hat.h b/ftnoir_tracker_hatire/ftnoir_tracker_hat.h index 54e67f48..af583d11 100644 --- a/ftnoir_tracker_hatire/ftnoir_tracker_hat.h +++ b/ftnoir_tracker_hatire/ftnoir_tracker_hat.h @@ -1,33 +1,28 @@ #ifndef FTNOIR_TRACKER_HAT_H #define FTNOIR_TRACKER_HAT_H -#include "..\ftnoir_tracker_base\ftnoir_tracker_base.h" +#include "facetracknoir/global-settings.h" +#include "ftnoir_tracker_base/ftnoir_tracker_base.h" #include "ftnoir_tracker_hat_settings.h" #include "ftnoir_arduino_type.h" -#include -#include +#include #include -#include #include #include -#include "Windows.h" -#include "math.h" - -class QextSerialPort; -class QExtSerialEnumerator; +#include +#include +#include class FTNoIR_Tracker : public ITracker, QThread { public: FTNoIR_Tracker(); - ~FTNoIR_Tracker(); + virtual ~FTNoIR_Tracker() virt_override; - void Initialize( QFrame *videoframe ); - void StartTracker( HWND parent_window ); - void StopTracker( bool exit ); - bool GiveHeadPoseData(THeadPoseData *data); + virtual void StartTracker( QFrame* frame ) virt_override; + virtual bool GiveHeadPoseData(double *data) virt_override; void applysettings(const TrackerSettings& settings); void notifyCenter(); @@ -39,18 +34,12 @@ public: protected: void run(); // qthread override run method - private: - // Handles to neatly terminate thread... - HANDLE m_StopThread; - HANDLE m_WaitThread; - TArduinoData ArduinoData, HAT ; // Trame from Arduino QByteArray datagram; - QextSerialPort *SerialPort; - QReadWriteLock rwlock; - QList* ListErrInf ; - int waitTimeout; + QSerialPort* SerialPort; + volatile bool stop; + QMutex lock; QString sSerialPortName; // Port serial name bool bEnableRoll; bool bEnablePitch; @@ -67,28 +56,22 @@ private: bool bInvertZ; - int iRollAxe; - int iPitchAxe; - int iYawAxe; - int iXAxe; - int iYAxe; - int iZAxe; + int iRollAxis; + int iPitchAxis; + int iYawAxis; + int iXAxis; + int iYAxis; + int iZAxis; }; - -//******************************************************************************************************* -// FaceTrackNoIR Tracker DLL. Functions used to get general info on the Tracker -//******************************************************************************************************* -class FTNoIR_TrackerDll : public ITrackerDll +class FTNoIR_TrackerDll : public Metadata { public: FTNoIR_TrackerDll(); ~FTNoIR_TrackerDll(); - void Initialize(); - - void getFullName(QString *strToBeFilled); + void getFullName(QString *strToBeFilled); void getShortName(QString *strToBeFilled); void getDescription(QString *strToBeFilled); void getIcon(QIcon *icon); @@ -99,4 +82,4 @@ private: QString trackerDescription; }; -#endif // FTNOIR_TRACKER_HAT_H \ No newline at end of file +#endif // FTNOIR_TRACKER_HAT_H -- cgit v1.2.3