Skip to content

Commit

Permalink
Perception: completely fix Eigen slerp function
Browse files Browse the repository at this point in the history
  • Loading branch information
jeroldchen authored and storypku committed Nov 4, 2020
1 parent 0db8cbc commit 5edbffe
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,10 @@ Eigen::Quaterniond Slerp(const Eigen::Quaterniond& source, const double& t,
}
if (d < 0) scale1 = -scale1;

return Eigen::Quaterniond(scale0 * source.coeffs() + scale1 * other.coeffs());
return Eigen::Quaterniond(scale0 * source.w() + scale1 * other.w(),
scale0 * source.x() + scale1 * other.x(),
scale0 * source.y() + scale1 * other.y(),
scale0 * source.z() + scale1 * other.z());
}

bool TransformCache::QueryTransform(double timestamp,
Expand Down

0 comments on commit 5edbffe

Please sign in to comment.