Skip to content
Snippets Groups Projects
Commit caf9167d authored by Joan Solà Ortega's avatar Joan Solà Ortega
Browse files

Rename WolfConstants --> Constants

parent b0e63c5f
No related branches found
No related tags found
No related merge requests found
......@@ -31,7 +31,7 @@ bool LocalParametrizationHomogeneous::plus(const Eigen::Map<const Eigen::VectorX
using namespace Eigen;
double norm_delta = _delta.norm();
if (norm_delta > WolfConstants::EPS)
if (norm_delta > Constants::EPS)
{
// compute rotation axis -- this guarantees unity norm
Vector3s axis = _delta / norm_delta;
......
......@@ -21,12 +21,12 @@ bool LocalParametrizationQuaternion::plus(const Eigen::Map<const Eigen::VectorXs
assert(_delta_theta.size() == local_size_ && "Wrong size of input delta_theta.");
assert(_q_plus_delta_theta.size() == global_size_ && "Wrong size of output quaternion.");
assert(fabs(1.0 - _q.norm()) < WolfConstants::EPS && "Quaternion not normalized.");
assert(fabs(1.0 - _q.norm()) < Constants::EPS && "Quaternion not normalized.");
using namespace Eigen;
double angle = _delta_theta.norm();
if (angle > WolfConstants::EPS)
if (angle > Constants::EPS)
{
// compute rotation axis -- this guarantees unity norm
Vector3s axis = _delta_theta / angle;
......
......@@ -37,7 +37,7 @@ namespace wolf {
typedef double WolfScalar; // Use this for double, 64 bit precision
//typedef long double WolfScalar; // Use this for long double, 128 bit precision
namespace WolfConstants{
namespace Constants{
// Wolf standard tolerance
const double EPS = 1e-8;
......@@ -348,7 +348,7 @@ inline WolfScalar pi2pi(const WolfScalar& angle)
namespace Eigen{
inline void v2q(const Eigen::VectorXs& _v, Eigen::Quaternions& _q){
wolf::WolfScalar angle = _v.norm();
if (angle < wolf::WolfConstants::EPS)
if (angle < wolf::Constants::EPS)
_q = Eigen::Quaternions::Identity();
else
{
......@@ -358,7 +358,7 @@ inline void v2q(const Eigen::VectorXs& _v, Eigen::Quaternions& _q){
inline void v2q(const Eigen::VectorXs& _v, Eigen::Map<Eigen::Quaternions>& _q){
wolf::WolfScalar angle = _v.norm();
if (angle < wolf::WolfConstants::EPS)
if (angle < wolf::Constants::EPS)
_q = Eigen::Quaternions::Identity();
else
{
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment