Commit b7ca3759 authored by Joseph Mirabel's avatar Joseph Mirabel
Browse files

Store Device::configSpaceRnxSOn_.

parent b467be95
......@@ -178,7 +178,7 @@ namespace hpp {
const LiegroupSpacePtr_t& configSpace () const { return configSpace_; }
/// See Joint::RnxSOnConfigurationSpace
LiegroupSpacePtr_t RnxSOnConfigSpace () const;
const LiegroupSpacePtr_t& RnxSOnConfigSpace () const { return configSpaceRnxSOn_; }
/// Get the neutral configuration
Configuration_t neutralConfiguration () const;
......@@ -330,7 +330,7 @@ namespace hpp {
std::string name_;
// Grippers
Grippers_t grippers_;
LiegroupSpacePtr_t configSpace_;
LiegroupSpacePtr_t configSpace_, configSpaceRnxSOn_;
// Extra configuration space
ExtraConfigSpace extraConfigSpace_;
// Joint linear constraints
......
......@@ -279,27 +279,21 @@ namespace hpp {
d_.jointJacobians_.resize ((std::size_t)model().njoints);
configSpace_ = LiegroupSpace::empty();
configSpaceRnxSOn_ = LiegroupSpace::empty();
const Model& m (model());
for (JointIndex i = 1; i < m.joints.size(); ++i)
*configSpace_ *= Joint(weakPtr_, i).configurationSpace();
if (extraConfigSpace_.dimension() > 0)
*configSpace_ *= LiegroupSpace::create (extraConfigSpace_.dimension());
for (JointIndex i = 1; i < m.joints.size(); ++i) {
*configSpace_ *= Joint(weakPtr_, i).configurationSpace();
*configSpaceRnxSOn_ *= Joint(weakPtr_, i).RnxSOnConfigurationSpace();
}
if (extraConfigSpace_.dimension() > 0) {
LiegroupSpacePtr_t extra = LiegroupSpace::create (extraConfigSpace_.dimension());
*configSpace_ *= extra;
*configSpaceRnxSOn_ *= extra;
}
numberDeviceData(numberDeviceData());
}
LiegroupSpacePtr_t Device::
RnxSOnConfigSpace () const
{
const Model& m (model());
LiegroupSpacePtr_t space (LiegroupSpace::empty());
for (JointIndex i = 1; i < m.joints.size(); ++i)
*space *= Joint(weakPtr_, i).RnxSOnConfigurationSpace();
if (extraConfigSpace_.dimension() > 0)
*space *= LiegroupSpace::create (extraConfigSpace_.dimension());
return space;
}
Configuration_t Device::
neutralConfiguration () const
{
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment