From abc4dfe2a2ac2395033a3b409519f91bb5f1ff28 Mon Sep 17 00:00:00 2001 From: Mirko Waechter <mirko.waechter@kit.edu> Date: Tue, 21 Mar 2017 22:57:54 +0100 Subject: [PATCH] added explicit instantiations of templates --- source/RobotAPI/libraries/core/FramedPose.cpp | 8 ++++++++ source/RobotAPI/libraries/core/FramedPose.h | 8 ++++++++ source/RobotAPI/libraries/core/Pose.cpp | 20 ++++++++++++++++--- source/RobotAPI/libraries/core/Pose.h | 12 +++++++++++ 4 files changed, 45 insertions(+), 3 deletions(-) diff --git a/source/RobotAPI/libraries/core/FramedPose.cpp b/source/RobotAPI/libraries/core/FramedPose.cpp index 66dfd4906..f6fdfe61c 100644 --- a/source/RobotAPI/libraries/core/FramedPose.cpp +++ b/source/RobotAPI/libraries/core/FramedPose.cpp @@ -21,6 +21,8 @@ * @copyright http://www.gnu.org/licenses/gpl-2.0.txt * GNU General Public License */ + + #include <RobotAPI/libraries/core/FramedPose.h> #include <RobotAPI/libraries/core/remoterobot/RemoteRobot.h> @@ -32,6 +34,12 @@ using namespace Eigen; using namespace std; + +template class ::IceInternal::Handle<::armarx::FramedPose>; +template class ::IceInternal::Handle<::armarx::FramedPosition>; +template class ::IceInternal::Handle<::armarx::FramedDirection>; +template class ::IceInternal::Handle<::armarx::FramedOrientation>; + namespace armarx { diff --git a/source/RobotAPI/libraries/core/FramedPose.h b/source/RobotAPI/libraries/core/FramedPose.h index 257d8f95a..cce0aedfd 100644 --- a/source/RobotAPI/libraries/core/FramedPose.h +++ b/source/RobotAPI/libraries/core/FramedPose.h @@ -363,4 +363,12 @@ namespace armarx typedef IceInternal::Handle<FramedPose> FramedPosePtr; } + +extern template class ::IceInternal::Handle<::armarx::FramedPose>; +extern template class ::IceInternal::Handle<::armarx::FramedPosition>; +extern template class ::IceInternal::Handle<::armarx::FramedDirection>; +extern template class ::IceInternal::Handle<::armarx::FramedOrientation>; + + + #endif diff --git a/source/RobotAPI/libraries/core/Pose.cpp b/source/RobotAPI/libraries/core/Pose.cpp index a56c01fb0..f6e8963d3 100644 --- a/source/RobotAPI/libraries/core/Pose.cpp +++ b/source/RobotAPI/libraries/core/Pose.cpp @@ -15,12 +15,13 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see <http://www.gnu.org/licenses/>. * - * @package - * @author - * @date + * @package + * @author + * @date * @copyright http://www.gnu.org/licenses/gpl-2.0.txt * GNU General Public License */ +#define EIGEN_NO_STATIC_ASSERT #include "Pose.h" #include <VirtualRobot/Robot.h> @@ -31,6 +32,19 @@ using namespace Eigen; using namespace std; +template class ::IceInternal::Handle<::armarx::Pose>; +template class ::IceInternal::Handle<::armarx::Vector2>; +template class ::IceInternal::Handle<::armarx::Vector3>; +template class ::IceInternal::Handle<::armarx::Quaternion>; + +namespace Eigen +{ + template class Matrix<float, 3, 1>; + template class Matrix<float, 3, 3>; + template class Matrix<float, 4, 4>; +} + + namespace armarx { diff --git a/source/RobotAPI/libraries/core/Pose.h b/source/RobotAPI/libraries/core/Pose.h index d9cadc18b..424da5191 100644 --- a/source/RobotAPI/libraries/core/Pose.h +++ b/source/RobotAPI/libraries/core/Pose.h @@ -270,4 +270,16 @@ namespace armarx typedef IceInternal::Handle<Pose> PosePtr; } + +extern template class ::IceInternal::Handle<::armarx::Pose>; +extern template class ::IceInternal::Handle<::armarx::Vector2>; +extern template class ::IceInternal::Handle<::armarx::Vector3>; +extern template class ::IceInternal::Handle<::armarx::Quaternion>; + +namespace Eigen +{ + extern template class Matrix<float, 3, 1>; + extern template class Matrix<float, 3, 3>; + extern template class Matrix<float, 4, 4>; +} #endif -- GitLab