diff --git a/modules/touch/src/TuioEar.cpp b/modules/touch/src/TuioEar.cpp index 3eb92a4942..ee7c282d07 100644 --- a/modules/touch/src/TuioEar.cpp +++ b/modules/touch/src/TuioEar.cpp @@ -130,7 +130,7 @@ void TuioEar::clearInput() { return std::find_if( _removeList.begin(), _removeList.end(), - [&cursor](int id) {\ + [&cursor](int id) { return cursor.getSessionID() == id; } ) != _removeList.end(); diff --git a/modules/touch/touchmodule.cpp b/modules/touch/touchmodule.cpp index 99ddaabcd6..f3d73926ad 100644 --- a/modules/touch/touchmodule.cpp +++ b/modules/touch/touchmodule.cpp @@ -108,7 +108,7 @@ TouchModule::TouchModule() OsEng.registerModuleCallback( // maybe call ear->clearInput() here rather than postdraw OpenSpaceEngine::CallbackOption::PreSync, [&]() { - if (OsEng.isMaster() && gotNewInput()) { + if (gotNewInput()) { //std::this_thread::sleep_for(std::chrono::seconds(1)); Camera* cam = OsEng.interactionHandler().camera(); @@ -124,9 +124,6 @@ TouchModule::TouchModule() centroid.x = std::accumulate(list.begin(), list.end(), 0.0f, [](float x, const TuioCursor& c) { return x + c.getX(); }) / list.size(); centroid.y = std::accumulate(list.begin(), list.end(), 0.0f, [](float y, const TuioCursor& c) { return y + c.getY(); }) / list.size(); - - - // ------- testing, should use more than just one point later on distance = std::accumulate(list.begin(), list.end(), 0.0f, [¢roid](float d, const TuioCursor& c) { return d + sqrt(pow(c.getX() - centroid.x, 2) + pow(c.getY() - centroid.y, 2)); @@ -184,16 +181,6 @@ TouchModule::TouchModule() } } ); - - OsEng.registerModuleCallback( - OpenSpaceEngine::CallbackOption::PostDraw, - [&]() { - WindowWrapper& wrapper = OsEng.windowWrapper(); - if (OsEng.isMaster() && wrapper.isRegularRendering()) { - - } - } - ); }