From 4e2590d671a28d2f375d4bf3772a251217d79e90 Mon Sep 17 00:00:00 2001 From: Joseph Mirabel <jmirabel@laas.fr> Date: Wed, 27 Aug 2014 19:31:00 +0200 Subject: [PATCH] Follow previous changes. --- src/graph-path-validation.cc | 3 ++- src/graph-steering-method.cc | 3 ++- src/manipulation-planner.cc | 5 +++-- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/src/graph-path-validation.cc b/src/graph-path-validation.cc index 464d4c6..84e42ea 100644 --- a/src/graph-path-validation.cc +++ b/src/graph-path-validation.cc @@ -92,7 +92,8 @@ namespace hpp { // We check for all of them if both nodes are on the same leaf. ConstraintSetPtr_t constraints; while (!possibleEdges.empty ()) { - constraints = constraintGraph_->pathConstraint (possibleEdges.back(), configAt (tmin)); + constraints = constraintGraph_->pathConstraint (possibleEdges.back()); + constraints->offsetFromConfig(configAt (tmin)); if (constraints->isSatisfied (configAt (tmax))) { validPart = path; return true; diff --git a/src/graph-steering-method.cc b/src/graph-steering-method.cc index d2691d2..41b2b07 100644 --- a/src/graph-steering-method.cc +++ b/src/graph-steering-method.cc @@ -36,7 +36,8 @@ namespace hpp { graph_->getEdge (graph_->getNode (q1), graph_->getNode (q2)); ConstraintSetPtr_t constraints; while (!possibleEdges.empty()) { - constraints = graph_->pathConstraint (possibleEdges.back(), q1); + constraints = graph_->pathConstraint (possibleEdges.back()); + constraints->offsetFromConfig(q1); if (constraints->isSatisfied (q2)) { path->constraints (constraints); break; diff --git a/src/manipulation-planner.cc b/src/manipulation-planner.cc index 9c29220..24c8dbb 100644 --- a/src/manipulation-planner.cc +++ b/src/manipulation-planner.cc @@ -102,7 +102,8 @@ namespace hpp { // Select next node in the constraint graph. graph::Nodes_t nodes = graph->getNode (*q_near); graph::Edges_t edges = graph->chooseEdge (nodes); - ConstraintPtr_t constraint = graph->configConstraint (edges, *q_near); + ConstraintPtr_t constraint = graph->configConstraint (edges); + constraint->offsetFromConfig (*q_near); qProj_ = *q_rand; if (!constraint->apply (qProj_)) { addFailure (PROJECTION, edges); @@ -114,7 +115,7 @@ namespace hpp { addFailure (STEERING_METHOD, edges); return false; } - path->constraints (graph->pathConstraint (edges, *q_near)); + path->constraints (graph->pathConstraint (edges)); core::PathValidationPtr_t pathValidation (problem ().pathValidation ()); pathValidation->validate (path, false, validPath); if (validPath->length () == 0) -- GitLab