From 0f6b772991539b8b374d92996627554a0d608065 Mon Sep 17 00:00:00 2001
From: Olivier Stasse <ostasse@laas.fr>
Date: Wed, 30 Jan 2019 13:13:19 +0100
Subject: [PATCH] Remove useless code + fix wrong sizes.

---
 .../DynamicFilter.cpp                         | 24 +++++--------------
 src/privatepgtypes.cpp                        | 18 +++++++-------
 2 files changed, 15 insertions(+), 27 deletions(-)

diff --git a/src/ZMPRefTrajectoryGeneration/DynamicFilter.cpp b/src/ZMPRefTrajectoryGeneration/DynamicFilter.cpp
index 48ff46ec..c6c84ae0 100644
--- a/src/ZMPRefTrajectoryGeneration/DynamicFilter.cpp
+++ b/src/ZMPRefTrajectoryGeneration/DynamicFilter.cpp
@@ -368,19 +368,7 @@ int DynamicFilter::OnLinefilter(
       deltaZMP_deq_[i].py = 0.0 ;
     }
   }
-  /*
-  for (unsigned int i = 0 ; i < N1 ; ++i)
-    {
-      std::cout << i
-		<< " - Dx=" << deltaZMP_deq_[i].px
-		<< " Dy=" << deltaZMP_deq_[i].py
-		<< " " << inputZMPTraj_deq_[i].px
-		<< " " << zmpmb_i_[i][0]
-		<< " " << inputZMPTraj_deq_[i].py
-		<< " " << zmpmb_i_[i][1]
-		<< " useDynamicFilter: " << useDynamicFilter_
-		<< std::endl;
-		} */
+  
   OptimalControl(deltaZMP_deq_,outputDeltaCOMTraj_deq_) ;
 
   return 0 ;
@@ -525,11 +513,11 @@ int DynamicFilter::OptimalControl(
   double deltaZMPx = 0.0 ;
   double deltaZMPy = 0.0 ;
   // computation of the preview control along the "deltaZMP_deq_"
-//  for(unsigned i=0;i<3;++i)
-//  {
-//    deltax_(i,0)=0.0;
-//    deltay_(i,0)=0.0;
-//  }
+  //  for(unsigned i=0;i<3;++i)
+  //  {
+  //    deltax_(i,0)=0.0;
+  //    deltay_(i,0)=0.0;
+  //  }
   for (int i = 0 ; i < Nctrl ; ++i )
   {
     PC_->OneIterationOfPreview(deltax_,deltay_,
diff --git a/src/privatepgtypes.cpp b/src/privatepgtypes.cpp
index 48cdaeeb..4cb490eb 100644
--- a/src/privatepgtypes.cpp
+++ b/src/privatepgtypes.cpp
@@ -92,9 +92,9 @@ namespace PatternGeneratorJRL
   void com_t::reset()
   {
 
-    x.resize(3,false);
-    y.resize(3,false);
-    z.resize(3,false);
+    x.resize(3);
+    y.resize(3);
+    z.resize(3);
     x.setZero();
     y.setZero();
     z.setZero();
@@ -131,12 +131,12 @@ namespace PatternGeneratorJRL
   void trunk_t::reset()
   {
 
-    x.resize(3,false);
-    y.resize(3,false);
-    z.resize(3,false);
-    yaw.resize(3,false);
-    pitch.resize(3,false);
-    roll.resize(3,false);
+    x.resize(3);
+    y.resize(3);
+    z.resize(3);
+    yaw.resize(3);
+    pitch.resize(3);
+    roll.resize(3);
     x.setZero();
     y.setZero();
     z.setZero();
-- 
GitLab