From 7a3bfeec126f02fd8b16df4d4c46d2de257e57e9 Mon Sep 17 00:00:00 2001
From: Stefan Reither <stef.reither@web.de>
Date: Tue, 5 Sep 2017 15:29:08 +0200
Subject: [PATCH] add empty method setShapeWithObjectInstance() to handUnit and
 ice-interface

---
 source/RobotAPI/components/units/HandUnit.cpp         |  4 ++++
 source/RobotAPI/components/units/HandUnit.h           | 10 ++++++++++
 source/RobotAPI/interface/units/HandUnitInterface.ice |  2 +-
 3 files changed, 15 insertions(+), 1 deletion(-)

diff --git a/source/RobotAPI/components/units/HandUnit.cpp b/source/RobotAPI/components/units/HandUnit.cpp
index 6f4fbe5d4..12eeed5de 100644
--- a/source/RobotAPI/components/units/HandUnit.cpp
+++ b/source/RobotAPI/components/units/HandUnit.cpp
@@ -141,6 +141,10 @@ void HandUnit::setShape(const std::string& shapeName, const Ice::Current& c)
 {
 }
 
+void HandUnit::setShapeWithObjectInstance(const std::string& shapeName, const std::string& objectInstanceName, const Ice::Current& c)
+{
+}
+
 
 SingleTypeVariantListBasePtr HandUnit::getShapeNames(const Ice::Current& c)
 {
diff --git a/source/RobotAPI/components/units/HandUnit.h b/source/RobotAPI/components/units/HandUnit.h
index f9e1be598..4b7ec730b 100644
--- a/source/RobotAPI/components/units/HandUnit.h
+++ b/source/RobotAPI/components/units/HandUnit.h
@@ -121,6 +121,16 @@ namespace armarx
          */
         void setShape(const std::string& shapeName, const Ice::Current& c = ::Ice::Current());
 
+        /**
+         * @brief setShapeWithObjectInstance Send command to the hand to form a specific shape position.
+         * While trying to form the specified shape, collison checking with the named object instance is performed.
+         * The resulting joint angles of the hand might differ from the predefined joint angles for the given shape.
+         *
+         * @param shapeName Name of the well known shape that the hand should form
+         * @param graspedObjectInstanceName name of the object instance which is used to check for collisions while setting the shape
+         */
+        void setShapeWithObjectInstance(const std::string& shapeName, const std::string& objectInstanceName, const Ice::Current& c = ::Ice::Current());
+
         /**
          * \return a list of strings for shape positions which can be used together with HandUnit::shape().
          */
diff --git a/source/RobotAPI/interface/units/HandUnitInterface.ice b/source/RobotAPI/interface/units/HandUnitInterface.ice
index 2a38125ad..7fffaddfa 100644
--- a/source/RobotAPI/interface/units/HandUnitInterface.ice
+++ b/source/RobotAPI/interface/units/HandUnitInterface.ice
@@ -48,6 +48,7 @@ module armarx
          * @param shapeName Name of the hand shape.
          */
         void setShape(string shapeName);
+        void setShapeWithObjectInstance(string shapeName, string objectInstanceName);
         /**
          * getShapeNames returns a list of names of hand shapes known to the hand unit.
          * @return List of known hand shape names.
@@ -57,7 +58,6 @@ module armarx
         NameValueMap getCurrentJointValues();
         string getHandName();
 
-
         /**
          * setObjectGrasped informs the hand unit that an object has been successfully grasped.
          * @param objectName Name of the object
-- 
GitLab