[Jderobot-admin] jderobot-r1110 - trunk/src/stable/libs/parallelIce

frivas en jderobot.org frivas en jderobot.org
Mar Nov 19 22:50:14 CET 2013


Author: frivas
Date: 2013-11-19 22:50:13 +0100 (Tue, 19 Nov 2013)
New Revision: 1110

Modified:
   trunk/src/stable/libs/parallelIce/laserClient.cpp
   trunk/src/stable/libs/parallelIce/pointcloudClient.cpp
Log:
#110 included aux functions to parallelICe


Modified: trunk/src/stable/libs/parallelIce/laserClient.cpp
===================================================================
--- trunk/src/stable/libs/parallelIce/laserClient.cpp	2013-11-19 21:48:15 UTC (rev 1109)
+++ trunk/src/stable/libs/parallelIce/laserClient.cpp	2013-11-19 21:50:13 UTC (rev 1110)
@@ -1,10 +1,23 @@
 /*
- * laserClient.cpp
+ *  Copyright (C) 1997-2013 JDE Developers TeamkinectViewer.camRGB
  *
- *  Created on: 23/07/2013
- *      Author: frivas
+ *  This program is free software: you can redistribute it and/or modify
+ *  it under the terms of the GNU General Public License as published by
+ *  the Free Software Foundation, either version 3 of the License, or
+ *  (at your option) any later version.
+ *
+ *  This program is distributed in the hope that it will be useful,
+ *  but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *  GNU General Public License for more details.
+ *
+ *  You should have received a copy of the GNU General Public License
+ *  along with this program.  If not, see http://www.gnu.org/licenses/.
+ *
+ *  Author : Jose María Cañas <jmplaza en gsyc.es>
+			Francisco Miguel Rivas Montero <franciscomiguel.rivas en urjc.es>
+
  */
-
 #include "laserClient.h"
 
 namespace jderobot {

Modified: trunk/src/stable/libs/parallelIce/pointcloudClient.cpp
===================================================================
--- trunk/src/stable/libs/parallelIce/pointcloudClient.cpp	2013-11-19 21:48:15 UTC (rev 1109)
+++ trunk/src/stable/libs/parallelIce/pointcloudClient.cpp	2013-11-19 21:50:13 UTC (rev 1110)
@@ -74,8 +74,6 @@
 void pointcloudClient::run(){
 
 	IceUtil::Time last;
-	int iterIndex = 0;
-	int totalRefreshRate = 0;
 
 	last=IceUtil::Time::now();
 
@@ -99,15 +97,8 @@
 		else{
 			usleep(this->cycle - (IceUtil::Time::now().toMicroSeconds() - last.toMicroSeconds()));
 		}
-		iterIndex++;
-		int rate =(int)(1000000/(IceUtil::Time::now().toMicroSeconds() - last.toMicroSeconds()));
-		totalRefreshRate =  totalRefreshRate + rate;
-		this->refreshRate= totalRefreshRate / iterIndex;
+		this->refreshRate=(int)(1000000/(IceUtil::Time::now().toMicroSeconds() - last.toMicroSeconds()));
 		last=IceUtil::Time::now();
-
-		if (iterIndex == INT_MAX)
-			iterIndex = 0;
-
 	}
 }
 



More information about the Jderobot-admin mailing list