Commit 86ce603c authored by Jordan Lack's avatar Jordan Lack

Added copyright headers to source files.

parent d643387b
......@@ -30,8 +30,7 @@ is a derivative can be found in the file RBDL_LICENSE.
## Credits
First and foremost I would like to give due credit to Martin Felis, the creator of RBDL of which this work is a derivative. Additionally, RBDL is fantastic library, and should you find that
RBDLim doesn't meet your needs please give RBDL a try. It may better fit your needs/application.
First and foremost I would like to give due credit to Martin Felis, the creator of RBDL of which this work is a derivative. Additionally, RBDL is fantastic library, and should you find that RBDLim doesn't meet your needs you may consider giving RBDL a try. It may better fit your needs/application.
I would also like to acknowledge the folks at the [IHMC Robotics Lab](http://robots.ihmc.us/). Their dynamics libary(which is written in Java) provides runtime frame checks, and after
working with them and seeing first hand how it enables very quick development of control algorithms and helps prevent a lot of bugs I know the world of c++ needed something similar. If
......
/*
* RBDL - Rigid Body Dynamics Library
* Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
* Original Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
*
*
* RBDLim - Rigid Body Dynamics Library improved
* Modifications Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
......
/*
* RBDL - Rigid Body Dynamics Library
* Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
* Original Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
*
*
* RBDLim - Rigid Body Dynamics Library improved
* Modifications Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
......
/*
* RBDL - Rigid Body Dynamics Library
* Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
* Original Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
*
*
* RBDLim - Rigid Body Dynamics Library improved
* Modifications Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
......
/*
* RBDL - Rigid Body Dynamics Library
* Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
* Original Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
*
*
* RBDLim - Rigid Body Dynamics Library improved
* Modifications Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
......
/*
* RBDL - Rigid Body Dynamics Library
* Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
* Original Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
*
*
* RBDLim - Rigid Body Dynamics Library improved
* Modifications Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
......
/*
* RBDL - Rigid Body Dynamics Library
* Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
* Original Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
*
*
* RBDLim - Rigid Body Dynamics Library improved
* Modifications Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
......
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#ifndef __RBDLIM_MOMENTUM_HPP__
#define __RBDLIM_MOMENTUM_HPP__
......
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#ifndef __RBDLIM_SPATIAL_INERTIA_HPP__
#define __RBDLIM_SPATIAL_INERTIA_HPP__
......
/*
* RBDL - Rigid Body Dynamics Library
* Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
* Original Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
*
*
* RBDLim - Rigid Body Dynamics Library improved
* Modifications Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
......
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#ifndef __RBDLIM_TRANSFORMABLE_GEOMETRIC_OBJECT_HPP__
#define __RBDLIM_TRANSFORMABLE_GEOMETRIC_OBJECT_HPP__
......
......@@ -18,15 +18,26 @@
#ifdef __cplusplus
#define JOIN( X, Y ) JOIN2(X,Y)
#define JOIN2( X, Y ) X##Y
#define JOIN(X, Y) JOIN2(X,Y)
#define JOIN2(X, Y) X##Y
namespace custom_static_assert
{
template <bool> struct STATIC_ASSERT_FAILURE;
template <> struct STATIC_ASSERT_FAILURE<true> { enum { value = 1 }; };
template<int x> struct custom_static_assert_test{};
template<bool>
struct STATIC_ASSERT_FAILURE;
template<>
struct STATIC_ASSERT_FAILURE<true>
{
enum
{
value = 1
};
};
template<int x>
struct custom_static_assert_test
{
};
}
#define COMPILE_ASSERT(x) \
......@@ -40,7 +51,7 @@ JOIN(_custom_static_assert_typedef, __LINE__)
#endif // __cplusplus
#define VERIFY_EXPLICIT_CAST(from, to) COMPILE_ASSERT(sizeof(from) == sizeof(to))
#define VERIFY_EXPLICIT_CAST(from, to) COMPILE_ASSERT(sizeof(from) == sizeof(to))
// RBDL_COMPILE_ASSERT_H_
#endif
//
// Created by anonymous on 7/23/16.
//
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#ifndef __FRAME_EXCEPTIONS__
#define __FRAME_EXCEPTIONS__
#ifndef __RBDLIM_FRAME_EXCEPTIONS__
#define __RBDLIM_FRAME_EXCEPTIONS__
#include <stdexcept>
#include <exception>
......
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#ifndef __RBDLIM_FRAME_OBJECT_HPP__
#define __RBDLIM_FRAME_OBJECT_HPP__
......
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#ifndef __RBDLIM_FRAME_POINT_HPP__
#define __RBDLIM_FRAME_POINT_HPP__
/**
* This class and its implementation is an adaptation of FramePoint.java by Jerry Pratt and the IHMC Robotics Group.
* All credit goes to them.
* This class and its implementation are an adaptation of FramePoint.java by Jerry Pratt and the IHMC Robotics Group.
*/
#include "rbdl_dynamics/frames/FrameObject.hpp"
......
#ifndef __FRAME_VECTOR_HPP__
#define __FRAME_VECTOR_HPP__
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#ifndef __RBDLIM_FRAME_VECTOR_HPP__
#define __RBDLIM_FRAME_VECTOR_HPP__
/**
* This class and its implementation is an adaptation of FrameVector.java by Jerry Pratt and the IHMC Robotics Group.
* All credit goes to them.
* This class and its implementation are an adaptation of FrameVector.java by Jerry Pratt and the IHMC Robotics Group.
*/
#include "rbdl_dynamics/frames/FrameObject.hpp"
......
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#ifndef __RBDLIM_REFERENCE_FRAME_HPP__
#define __RBDLIM_REFERENCE_FRAME_HPP__
/** This class and its implementation are an adaptation
** of the ReferenceFrame.java by Jerry Pratt and the IHMC robotics group.
** All credit goes to them.
**/
#include <memory>
......
#ifndef __REFERENCE_FRAME_HOLDER_HPP__
#define __REFERENCE_FRAME_HOLDER_HPP__
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#ifndef __RBDLIM_REFERENCE_FRAME_HOLDER_HPP__
#define __RBDLIM_REFERENCE_FRAME_HOLDER_HPP__
#include "rbdl_dynamics/frames/ReferenceFrame.hpp"
/** This class and its implementation are an adaptation
** of the ReferenceFrameHolder.java by Jerry Pratt and the IHMC robotics group.
** All credit goes to them.
**/
namespace RigidBodyDynamics
......
//
// Created by anonymous on 10/10/16.
//
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#ifndef __RBDLIM_SPATIAL_ACCELERATION_HPP__
#define __RBDLIM_SPATIAL_ACCELERATION_HPP__
......
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#ifndef __RBDLIM_SPATIAL_FORCE_HPP__
#define __RBDLIM_SPATIAL_FORCE_HPP__
......
//
// Created by jordan on 9/28/16.
//
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#ifndef __RBDLIM_SPATIAL_MOMENTUM_HP__
#define __RBDLIM_SPATIAL_MOMENTUM_HP__
......
//
// Created by jordan on 9/22/16.
//
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#ifndef __RBDLIM_SPATIAL_MOTION_HPP__
#define __RBDLIM_SPATIAL_MOTION_HPP__
......
#ifndef __POINT_3_HPP__
#define __POINT_3_HPP__
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#ifndef __RBDLIM_POINT_3_HPP__
#define __RBDLIM_POINT_3_HPP__
#include <math.h>
#include <stdexcept>
......
/*
* RBDL - Rigid Body Dynamics Library
* Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
* Original Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
*
*
* RBDLim - Rigid Body Dynamics Library improved
* Modifications Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
......
/*
* RBDL - Rigid Body Dynamics Library
* Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
* Original Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
*
*
* RBDLim - Rigid Body Dynamics Library improved
* Modifications Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
......@@ -10,28 +13,6 @@
#include "rbdl_dynamics/rbdl_config.h"
#ifdef RBDL_USE_SIMPLE_MATH
#include "rbdl_dynamics/SimpleMath/SimpleMathFixed.h"
#include "rbdl_dynamics/SimpleMath/SimpleMathDynamic.h"
#include "rbdl_dynamics/SimpleMath/SimpleMathMixed.h"
#include "rbdl_dynamics/SimpleMath/SimpleMathQR.h"
#include "rbdl_dynamics/SimpleMath/SimpleMathCholesky.h"
#include "rbdl_dynamics/SimpleMath/SimpleMathCommaInitializer.h"
#include <vector>
typedef SimpleMath::Fixed::Matrix<double, 3, 1> Vector3_t;
typedef SimpleMath::Fixed::Matrix<double, 3, 3> Matrix3_t;
typedef SimpleMath::Fixed::Matrix<double, 4, 1> Vector4_t;
typedef SimpleMath::Fixed::Matrix<double, 6, 1> SpatialVector_t;
typedef SimpleMath::Fixed::Matrix<double, 6, 6> SpatialMatrix_t;
typedef SimpleMath::Fixed::Matrix<double, 6, 3> Matrix63_t;
typedef SimpleMath::Dynamic::Matrix<double> MatrixN_t;
typedef SimpleMath::Dynamic::Matrix<double> VectorN_t;
#else
#include <Eigen/Dense>
#include <Eigen/StdVector>
#include <Eigen/QR>
......@@ -43,7 +24,6 @@ typedef Eigen::Matrix<double, 6, 3> Matrix63_t;
typedef Eigen::VectorXd VectorN_t;
typedef Eigen::MatrixXd MatrixN_t;
#endif
namespace RigidBodyDynamics
{
......@@ -67,15 +47,11 @@ namespace RigidBodyDynamics
#include "rbdl_dynamics/Quaternion.h"
#include "rbdl_dynamics/SpatialAlgebraOperators.h"
// If we use Eigen3 we have to create specializations of the STL
// std::vector such that the alignment is done properly.
#ifndef RBDL_USE_SIMPLE_MATH
EIGEN_DEFINE_STL_VECTOR_SPECIALIZATION(RigidBodyDynamics::Math::SpatialVector)
EIGEN_DEFINE_STL_VECTOR_SPECIALIZATION(RigidBodyDynamics::Math::SpatialMatrix)
EIGEN_DEFINE_STL_VECTOR_SPECIALIZATION(RigidBodyDynamics::Math::Matrix63)
EIGEN_DEFINE_STL_VECTOR_SPECIALIZATION(RigidBodyDynamics::Math::SpatialTransform)
EIGEN_DEFINE_STL_VECTOR_SPECIALIZATION(RigidBodyDynamics::Math::SpatialRigidBodyInertia)
#endif
/* RBDL_MATH_H_H */
#endif
/*
* RBDL - Rigid Body Dynamics Library
* Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
* Original Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
*
*
* RBDLim - Rigid Body Dynamics Library improved
* Modifications Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
......
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#ifndef __RBDLIM_MATH_HPP__
#define __RBDLIM_MATH_HPP__
......
/*
* RBDL - Rigid Body Dynamics Library
* Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
* Original Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
*
*
* RBDLim - Rigid Body Dynamics Library improved
* Modifications Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
......
/*
* RBDL - Rigid Body Dynamics Library
* Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
* Original Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
*
*
* RBDLim - Rigid Body Dynamics Library improved
* Modifications Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
......
//
// Created by jordan on 10/14/16.
//
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#include "rbdl_dynamics/frames/FrameObject.hpp"
......
/*
* RBDL - Rigid Body Dynamics Library
* Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
* Original Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
*
*
* RBDLim - Rigid Body Dynamics Library improved
* Modifications Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
......
/*
* RBDL - Rigid Body Dynamics Library
* Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
* Original Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
*
*
* RBDLim - Rigid Body Dynamics Library improved
* Modifications Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
......
/*
* RBDL - Rigid Body Dynamics Library
* Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
* Original Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
*
*
* RBDLim - Rigid Body Dynamics Library improved
* Modifications Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
......
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#include "rbdl_dynamics/frames/ReferenceFrame.hpp"
......
//
// Created by jordan on 10/14/16.
//
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#include "rbdl_dynamics/RigidBodyInertia.hpp"
......
//
// Created by anonymous on 10/10/16.
//
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#include "rbdl_dynamics/frames/SpatialAcceleration.hpp"
......
//
// Created by anonymous on 10/10/16.
//
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#include "rbdl_dynamics/frames/SpatialMotion.hpp"
......
//
// Created by jordan on 10/13/16.
//
/*
* RBDLim - Rigid Body Dynamics Library improved
* Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
#include "rbdl_dynamics/TransformableGeometricObject.hpp"
......
/*
* RBDL - Rigid Body Dynamics Library
* Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
* Original Copyright (c) 2011-2016 Martin Felis <martin.felis@iwr.uni-heidelberg.de>
*
*
* RBDLim - Rigid Body Dynamics Library improved
* Modifications Copyright (c) 2017 Jordan Lack <jlack1987@gmail.com>
*
* Licensed under the zlib license. See LICENSE for more details.
*/
......
......@@ -12,80 +12,85 @@
#include <string>
#include <cstdlib>
RBDL_DLLAPI int rbdl_get_api_version() {
static int compile_version = RBDL_API_VERSION;
return compile_version;
RBDL_DLLAPI int rbdl_get_api_version()
{
static int compile_version = RBDL_API_VERSION;
return compile_version;
}
RBDL_DLLAPI void rbdl_check_api_version(int version) {
int compile_version = rbdl_get_api_version();
int compile_major = (compile_version & 0xff0000) >> 16;
int compile_minor = (compile_version & 0x00ff00) >> 8;
int compile_patch = (compile_version & 0x0000ff);
std::ostringstream compile_version_string("");
compile_version_string << compile_major << "." << compile_minor << "." << compile_patch;
int version_major = (version & 0xff0000) >> 16;
int version_minor = (version & 0x00ff00) >> 8;
int version_patch = (version & 0x0000ff);
std::ostringstream link_version_string ("");
link_version_string << version_major << "." << version_minor << "." << version_patch;
if (version_major != compile_major) {
std::cerr << "Error: trying to link against an incompatible RBDL library." << std::endl;
std::cerr << "The library version is: " << compile_version_string.str() << " but rbdl_config.h is version " << link_version_string.str() << std::endl;
abort();
} else if (version_minor != compile_minor) {
std::cout << "Warning: RBDL library is of version " << compile_version_string.str() << " but rbdl_config.h is from version " << link_version_string.str() << std::endl;
}
RBDL_DLLAPI void rbdl_check_api_version(int version)
{
int compile_version = rbdl_get_api_version();
int compile_major = (compile_version & 0xff0000) >> 16;
int compile_minor = (compile_version & 0x00ff00) >> 8;
int compile_patch = (compile_version & 0x0000ff);
std::ostringstream compile_version_string("");
compile_version_string << compile_major << "." << compile_minor << "." << compile_patch;
int version_major = (version & 0xff0000) >> 16;
int version_minor = (version & 0x00ff00) >> 8;
int version_patch = (version & 0x0000ff);
std::ostringstream link_version_string("");
link_version_string << version_major << "." << version_minor << "." << version_patch;
if(version_major != compile_major)
{
std::cerr << "Error: trying to link against an incompatible RBDL library." << std::endl;
std::cerr << "The library version is: " << compile_version_string.str() << " but rbdl_config.h is version " << link_version_string.str() << std::endl;
abort();
}
else if(version_minor != compile_minor)
{
std::cout << "Warning: RBDL library is of version " << compile_version_string.str() << " but rbdl_config.h is from version " << link_version_string.str() << std::endl;
}
}
RBDL_DLLAPI void rbdl_print_version() {
int compile_version = rbdl_get_api_version();
RBDL_DLLAPI void rbdl_print_version()
{
int compile_version = rbdl_get_api_version();
int compile_major = (compile_version & 0xff0000) >> 16;
int compile_minor = (compile_version & 0x00ff00) >> 8;
int compile_patch = (compile_version & 0x0000ff);
int compile_major = (compile_version & 0xff0000) >> 16;
int compile_minor = (compile_version & 0x00ff00) >> 8;
int compile_patch = (compile_version & 0x0000ff);
std::ostringstream compile_version_string("");
compile_version_string << compile_major << "." << compile_minor << "." << compile_patch;
std::ostringstream compile_version_string("");
compile_version_string << compile_major << "." << compile_minor << "." << compile_patch;
std::cout << "RBDL version:" << std::endl
<< " API version : " << compile_version_string.str() << std::endl;
std::cout << "RBDL version:" << std::endl << " API version : " << compile_version_string.str() << std::endl;
if (std::string("unknown") != RBDL_BUILD_REVISION) {
std::cout << " revision : " << RBDL_BUILD_REVISION
<< " (branch: " << RBDL_BUILD_BRANCH << ")" << std::endl
<< " build type : " << RBDL_BUILD_TYPE << std::endl;
}
if(std::string("unknown") != RBDL_BUILD_REVISION)
{
std::cout << " revision : " << RBDL_BUILD_REVISION << " (branch: " << RBDL_BUILD_BRANCH << ")" << std::endl << " build type : " << RBDL_BUILD_TYPE << std::endl;
}
#ifdef RBDL_ENABLE_LOGGING
std::cout << " logging : on (warning: reduces performance!)" << std::endl;
std::cout << " logging : on (warning: reduces performance!)" << std::endl;
#else
std::cout << " logging : off" << std::endl;
std::cout << " logging : off" << std::endl;
#endif
#ifdef RBDL_USE_SIMPLE_MATH
std::cout << " simplemath : on (warning: reduces performance!)" << std::endl;
std::cout << " simplemath : on (warning: reduces performance!)" << std::endl;
#else
std::cout << " simplemath : off" << std::endl;
std::cout << " simplemath : off" << std::endl;
#endif
#ifdef RBDL_BUILD_ADDON_LUAMODEL