summaryrefslogtreecommitdiffhomepage
path: root/facetracknoir/tracker.cpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2013-10-16 18:30:59 +0200
committerStanislaw Halik <sthalik@misaki.pl>2013-10-16 18:30:59 +0200
commitbb710c8d207337d4d0cc2a6657e954bbc2823e7f (patch)
tree928195af1d8849d96121fde4ae8ea40981109a0e /facetracknoir/tracker.cpp
parent8e988b5a8509cf811ababd8e49ce85aa4afe4da0 (diff)
initial implementation
To-be-reviewed-by: mm0zct
Diffstat (limited to 'facetracknoir/tracker.cpp')
-rw-r--r--facetracknoir/tracker.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/facetracknoir/tracker.cpp b/facetracknoir/tracker.cpp
index b965140b..d1218098 100644
--- a/facetracknoir/tracker.cpp
+++ b/facetracknoir/tracker.cpp
@@ -31,7 +31,8 @@
/** constructor **/
Tracker::Tracker( FaceTrackNoIR *parent ) :
should_quit(false),
- do_center(false)
+ do_center(false),
+ enabled(true)
{
// Retieve the pointer to the parent
mainApp = parent;
@@ -145,17 +146,14 @@ void Tracker::run() {
get_curve(new_camera.axes[i], output_camera.axes[i], mainApp->axis(i));
}
- //
// Send the headpose to the game
- //
- if (Libraries->pProtocol) {
+ if (Libraries->pProtocol && enabled) {
gameoutput_camera = output_camera;
Libraries->pProtocol->sendHeadposeToGame( gameoutput_camera.axes, newpose ); // degrees & centimeters
}
}
}
- //for lower cpu load
msleep(8);
}
#if defined(_WIN32)