hpp-constraints  4.9.1
Definition of basic geometric constraints for motion planning
relative-pose.hh
Go to the documentation of this file.
1 // Copyright (c) 2015, LAAS-CNRS
2 // Authors: Florent Lamiraux
3 //
4 // This file is part of hpp-constraints.
5 // hpp-constraints is free software: you can redistribute it
6 // and/or modify it under the terms of the GNU Lesser General Public
7 // License as published by the Free Software Foundation, either version
8 // 3 of the License, or (at your option) any later version.
9 //
10 // hpp-constraints is distributed in the hope that it will be
11 // useful, but WITHOUT ANY WARRANTY; without even the implied warranty
12 // of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 // General Lesser Public License for more details. You should have
14 // received a copy of the GNU Lesser General Public License along with
15 // hpp-constraints. If not, see <http://www.gnu.org/licenses/>.
16 
17 #ifndef HPP_CONSTRAINTS_IMPLICIT_RELATIVE_POSE_HH
18 # define HPP_CONSTRAINTS_IMPLICIT_RELATIVE_POSE_HH
19 
21 
22 namespace hpp {
23  namespace constraints {
24  namespace implicit {
26  class HPP_CONSTRAINTS_DLLAPI RelativePose : public virtual Implicit
27  {
28  public:
30  virtual ImplicitPtr_t copy () const;
46  (const std::string& name, const DevicePtr_t& robot,
47  const JointConstPtr_t& joint1, const JointConstPtr_t& joint2,
48  const Transform3f& frame1, const Transform3f& frame2,
49  std::vector <bool> mask = std::vector<bool>(6,true),
50  ComparisonTypes_t comp = std::vector <ComparisonType> (),
51  vectorIn_t rhs = vector_t ());
52 
53  static RelativePosePtr_t createCopy (const RelativePosePtr_t& other);
54 
56  const JointConstPtr_t& joint1 () const
57  {
58  return joint1_;
59  }
60 
62  const JointConstPtr_t& joint2 () const
63  {
64  return joint2_;
65  }
66 
67  protected:
82  RelativePose (const std::string& name, const DevicePtr_t& robot,
83  const JointConstPtr_t& joint1,
84  const JointConstPtr_t& joint2,
85  const Transform3f& frame1, const Transform3f& frame2,
86  std::vector <bool> mask = std::vector<bool>(6,true),
87  ComparisonTypes_t comp = std::vector <ComparisonType> (),
88  vectorIn_t rhs = vector_t ());
89 
91  RelativePose (const RelativePose& other);
93  void init (RelativePoseWkPtr_t weak);
94  private:
95  JointConstPtr_t joint1_, joint2_;
96  RelativePoseWkPtr_t weak_;
97  }; // class RelativePose
98  } // namespace implicit
99  } // namespace constraints
100 } // namespace hpp
101 #endif //HPP_CONSTRAINTS_IMPLICIT_RELATIVE_POSE_HH
pinocchio::vector_t vector_t
Definition: fwd.hh:45
pinocchio::vectorIn_t vectorIn_t
Definition: fwd.hh:46
pinocchio::DevicePtr_t DevicePtr_t
Definition: fwd.hh:91
ObjectFactory * create(ObjectFactory *parent=NULL, const XMLElement *element=NULL)
std::vector< ComparisonType > ComparisonTypes_t
Definition: fwd.hh:170
pinocchio::JointConstPtr_t JointConstPtr_t
Definition: fwd.hh:38
boost::shared_ptr< RelativePose > RelativePosePtr_t
Definition: fwd.hh:184
Constraint of relative pose between two frames on a kinematic chain.
Definition: relative-pose.hh:26
const JointConstPtr_t & joint2() const
Get joint2.
Definition: relative-pose.hh:62
Definition: implicit.hh:96
boost::shared_ptr< Implicit > ImplicitPtr_t
Definition: fwd.hh:157
const JointConstPtr_t & joint1() const
Get joint1.
Definition: relative-pose.hh:56
pinocchio::Transform3f Transform3f
Definition: fwd.hh:50