Skip to content

Commit 75dacff

Browse files
committed
Mode-graph - use new function for joint spline
1 parent d2b6bae commit 75dacff

File tree

1 file changed

+1
-14
lines changed

1 file changed

+1
-14
lines changed

src/parsers/graph/model-graph-algo.cpp

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -381,20 +381,7 @@ namespace pinocchio
381381
PINOCCHIO_THROW_PRETTY(
382382
std::invalid_argument, "Graph - JointSpline cannot be reversed.");
383383

384-
if (boost::get<BodyFrame>(&source_vertex.frame) == nullptr)
385-
PINOCCHIO_THROW_PRETTY(
386-
std::invalid_argument, "Graph - Invalid joint between a body and a non body frame.");
387-
388-
const SE3 & joint_pose = edge.source_to_joint;
389-
const SE3 & body_pose = edge.joint_to_target;
390-
391-
const Frame previous_body = model.frames[model.getFrameId(source_vertex.name, BODY)];
392-
JointIndex j_id = model.addJoint(
393-
previous_body.parentJoint, cjm(joint), previous_body.placement * joint_pose, edge.name);
394-
395-
model.addJointFrame(j_id);
396-
model.appendBodyToJoint(j_id, b_f.inertia); // check this
397-
model.addBodyFrame(target_vertex.name, j_id, body_pose);
384+
addJointBetweenBodies(joint, b_f);
398385
}
399386

400387
void operator()(const JointFixed & joint, const BodyFrame & b_f)

0 commit comments

Comments
 (0)