summaryrefslogtreecommitdiffhomepage
path: root/facetracknoir/facetracknoir.cpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2014-10-20 09:33:56 +0200
committerStanislaw Halik <sthalik@misaki.pl>2014-10-20 09:33:56 +0200
commitba0cd4a1fd743a7d0d025ca76c211c8f466e6879 (patch)
tree2bbd5f1939a7413e76cbe782e3da7b7c844cea8c /facetracknoir/facetracknoir.cpp
parent7f0d0d1b9ef7711a4f1835b0120f014799b71e90 (diff)
refactor 2/n
Diffstat (limited to 'facetracknoir/facetracknoir.cpp')
-rw-r--r--facetracknoir/facetracknoir.cpp19
1 files changed, 3 insertions, 16 deletions
diff --git a/facetracknoir/facetracknoir.cpp b/facetracknoir/facetracknoir.cpp
index c547f608..5170498c 100644
--- a/facetracknoir/facetracknoir.cpp
+++ b/facetracknoir/facetracknoir.cpp
@@ -199,7 +199,7 @@ void FaceTrackNoIR::updateButtonState(bool running, bool inertialp)
void FaceTrackNoIR::bindKeyboardShortcuts()
{
if (work)
- work->sc = std::make_shared<Shortcuts>();
+ work->sc = std::make_shared<Shortcuts>(winId());
}
void FaceTrackNoIR::startTracker( ) {
@@ -211,7 +211,7 @@ void FaceTrackNoIR::startTracker( ) {
work = nullptr;
libs = SelectedLibraries(ui.video_frame, current_tracker(), current_protocol(), current_filter());
- work = std::make_shared<Work>(s, pose, libs, this);
+ work = std::make_shared<Work>(s, pose, libs, this, winId());
{
double p[6] = {0,0,0, 0,0,0};
@@ -227,11 +227,6 @@ void FaceTrackNoIR::startTracker( ) {
return;
}
-#if defined(_WIN32)
- keybindingWorker = new KeybindingWorker(*this, keyCenter, keyToggle);
- keybindingWorker->start();
-#endif
-
ui.video_frame->show();
timUpdateHeadPose.start(50);
@@ -243,15 +238,7 @@ void FaceTrackNoIR::startTracker( ) {
void FaceTrackNoIR::stopTracker( ) {
ui.game_name->setText("Not connected");
-#if defined(_WIN32)
- if (keybindingWorker)
- {
- keybindingWorker->should_quit = true;
- keybindingWorker->wait();
- delete keybindingWorker;
- keybindingWorker = NULL;
- }
-#endif
+
timUpdateHeadPose.stop();
ui.pose_display->rotateBy(0, 0, 0);