Commit 7183e188 authored by artificiel's avatar artificiel
Browse files

ClientConnector: desactivation du oscParameterSync

semble causer des problemes vs threading
parent 8cde156f
...@@ -46,10 +46,10 @@ void ClientConnector::threadedFunction() ...@@ -46,10 +46,10 @@ void ClientConnector::threadedFunction()
xyz_receiver_.receive(fresh_mesh); xyz_receiver_.receive(fresh_mesh);
if (fresh_mesh.getNumVertices()) { if (fresh_mesh.getNumVertices()) {
fresh_mesh.removeVertex(0); fresh_mesh.removeVertex(0);
TS_START("Client::send channel thread");
aggregated_.send(std::move(fresh_mesh));
TS_STOP("Client::send channel thread");
} }
TS_START("Client::send channel thread");
aggregated_.send(std::move(fresh_mesh));
TS_STOP("Client::send channel thread");
// std::cout << "NEW CLOUD IN THREAD " << client_name_ << "#" << cloud_counter_ << std::endl; // std::cout << "NEW CLOUD IN THREAD " << client_name_ << "#" << cloud_counter_ << std::endl;
} else { } else {
...@@ -164,7 +164,7 @@ void ClientConnector::handle_connection() ...@@ -164,7 +164,7 @@ void ClientConnector::handle_connection()
if (res) { if (res) {
if (sync_active_) osc_sync_.update(); //SYNC if (sync_active_) osc_sync_.update();
// xyz_receiver_.update(); // xyz_receiver_.update();
...@@ -185,7 +185,9 @@ void ClientConnector::handle_connection() ...@@ -185,7 +185,9 @@ void ClientConnector::handle_connection()
// std::cout << " tokens:" << t << std::endl; // std::cout << " tokens:" << t << std::endl;
} }
lock(); lock();
if (message.size() == 0) { if (message.size() == 0) {
std::cout << "TCP erreur: message vide" << std::endl; std::cout << "TCP erreur: message vide" << std::endl;
} else if (message[0] == "zero") { } else if (message[0] == "zero") {
...@@ -201,7 +203,7 @@ void ClientConnector::handle_connection() ...@@ -201,7 +203,7 @@ void ClientConnector::handle_connection()
} }
} else if (message[0] == "parameter") { } else if (message[0] == "parameter") {
osc_sync_.setup((ofParameterGroup &)gui_.getParameter(), 6666, client_name_, 6667); //SYNC osc_sync_.setup((ofParameterGroup &)gui_.getParameter(), 6666, client_name_, 6667);
// de l'extérieur?? // de l'extérieur??
...@@ -209,7 +211,7 @@ void ClientConnector::handle_connection() ...@@ -209,7 +211,7 @@ void ClientConnector::handle_connection()
cropper_parameters_.update_parameter_from_strings(message); cropper_parameters_.update_parameter_from_strings(message);
} }
osc_sync_.setup((ofParameterGroup &)gui_.getParameter(), 6666, client_name_, OSCCLIENT_SYNCPORT); //SYNC osc_sync_.setup((ofParameterGroup &)gui_.getParameter(), 6666, client_name_, OSCCLIENT_SYNCPORT);
} else if (message[0] == "sync_ready") { } else if (message[0] == "sync_ready") {
...@@ -259,8 +261,7 @@ void ClientConnector::handle_connection() ...@@ -259,8 +261,7 @@ void ClientConnector::handle_connection()
ofToString(depth_receiver_.getPort()); ofToString(depth_receiver_.getPort());
send("hello from server"); send("hello from server");
send(info); send(info);
osc_sync_.setup((ofParameterGroup &)gui_.getParameter(), 6666, //SYNC osc_sync_.setup((ofParameterGroup &)gui_.getParameter(), 6666, client_name_, OSCCLIENT_SYNCPORT);
client_name_, OSCCLIENT_SYNCPORT);
// osc_sync_.setup((ofParameterGroup&)gui_.getParameter(),osc_port_,client_name_,OSCCLIENT_SYNCPORT); // osc_sync_.setup((ofParameterGroup&)gui_.getParameter(),osc_port_,client_name_,OSCCLIENT_SYNCPORT);
send("sync : " + ofToString(osc_port_)); send("sync : " + ofToString(osc_port_));
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment