parsers/sdf.hpp
Go to the documentation of this file.
1 //
2 // Copyright (c) 2020 CNRS
3 //
4 
5 #ifndef __pinocchio_parsers_sdf_hpp__
6 #define __pinocchio_parsers_sdf_hpp__
7 
12 
13 namespace pinocchio
14 {
15  namespace sdf
16  {
17 
43  template<typename Scalar, int Options, template<typename, int> class JointCollectionTpl>
46  const std::string & filename,
47  const GeometryType type,
48  GeometryModel & geomModel,
49  const std::string & rootLinkName = "",
50  const std::vector<std::string> & packageDirs = std::vector<std::string>(),
52 
76  template<typename Scalar, int Options, template<typename, int> class JointCollectionTpl>
80  const std::string & filename,
81  const GeometryType type,
82  GeometryModel & geomModel,
83  const std::string & packagePath,
85  {
86  const std::vector<std::string> dirs(1, packagePath);
87  return buildGeom(model, contact_models, filename, type, geomModel, dirs, meshLoader);
88  };
89 
114  template<typename Scalar, int Options, template<typename, int> class JointCollectionTpl>
117  const std::string & filename,
118  const GeometryType type,
119  GeometryModel & geomModel,
120  const std::string & rootLinkName,
121  const std::string & packagePath,
123  {
124  const std::vector<std::string> dirs(1, packagePath);
125  return buildGeom(model, filename, type, geomModel, rootLinkName, dirs, meshLoader);
126  };
127 
142  template<typename Scalar, int Options, template<typename, int> class JointCollectionTpl>
144  const std::string & xmlStream,
146  const std::string & rootJointName,
149  const std::string & rootLinkName = "",
150  const std::vector<std::string> & parentGuidance = {},
151  const bool verbose = false);
152 
166  template<typename Scalar, int Options, template<typename, int> class JointCollectionTpl>
167  ModelTpl<Scalar, Options, JointCollectionTpl> & buildModelFromXML(
168  const std::string & xmlStream,
170  ModelTpl<Scalar, Options, JointCollectionTpl> & model,
172  const std::string & rootLinkName = "",
173  const std::vector<std::string> & parentGuidance = {},
174  const bool verbose = false);
175 
190  template<typename Scalar, int Options, template<typename, int> class JointCollectionTpl>
191  ModelTpl<Scalar, Options, JointCollectionTpl> & buildModel(
192  const std::string & filename,
194  const std::string & rootJointName,
195  ModelTpl<Scalar, Options, JointCollectionTpl> & model,
197  const std::string & rootLinkName = "",
198  const std::vector<std::string> & parentGuidance = {},
199  const bool verbose = false);
200 
214  template<typename Scalar, int Options, template<typename, int> class JointCollectionTpl>
215  ModelTpl<Scalar, Options, JointCollectionTpl> & buildModel(
216  const std::string & filename,
218  ModelTpl<Scalar, Options, JointCollectionTpl> & model,
220  const std::string & rootLinkName = "",
221  const std::vector<std::string> & parentGuidance = {},
222  const bool verbose = false);
223 
232  template<typename Scalar, int Options, template<typename, int> class JointCollectionTpl>
233  ModelTpl<Scalar, Options, JointCollectionTpl> & buildModelFromXML(
234  const std::string & xmlStream,
235  ModelTpl<Scalar, Options, JointCollectionTpl> & model,
237  const std::string & rootLinkName = "",
238  const std::vector<std::string> & parentGuidance = {},
239  const bool verbose = false);
240 
249  template<typename Scalar, int Options, template<typename, int> class JointCollectionTpl>
250  ModelTpl<Scalar, Options, JointCollectionTpl> & buildModel(
251  const std::string & filename,
252  ModelTpl<Scalar, Options, JointCollectionTpl> & model,
254  const std::string & rootLinkName = "",
255  const std::vector<std::string> & parentGuidance = {},
256  const bool verbose = false);
257 
258  } // namespace sdf
259 } // namespace pinocchio
260 
261 #include "pinocchio/parsers/sdf/model.hxx"
262 #include "pinocchio/parsers/sdf/geometry.hxx"
263 
264 #endif // ifndef __pinocchio_parsers_sdf_hpp__
common_symbols.type
type
Definition: common_symbols.py:35
pinocchio::sdf::buildModelFromXML
ModelTpl< Scalar, Options, JointCollectionTpl > & buildModelFromXML(const std::string &xmlStream, const typename ModelTpl< Scalar, Options, JointCollectionTpl >::JointModel &rootJoint, const std::string &rootJointName, ModelTpl< Scalar, Options, JointCollectionTpl > &model, PINOCCHIO_STD_VECTOR_WITH_EIGEN_ALLOCATOR(RigidConstraintModel) &contact_models, const std::string &rootLinkName="", const std::vector< std::string > &parentGuidance={}, const bool verbose=false)
Build the model from an XML stream with a particular joint as root of the model tree inside the model...
model.hpp
pinocchio::sdf::buildGeom
GeometryModel & buildGeom(const ModelTpl< Scalar, Options, JointCollectionTpl > &model, const std::string &filename, const GeometryType type, GeometryModel &geomModel, const std::string &rootLinkName="", const std::vector< std::string > &packageDirs=std::vector< std::string >(), ::hpp::fcl::MeshLoaderPtr meshLoader=::hpp::fcl::MeshLoaderPtr())
Build The GeometryModel from a SDF file. Search for meshes in the directories specified by the user f...
pinocchio::sdf::buildModel
ModelTpl< Scalar, Options, JointCollectionTpl > & buildModel(const std::string &filename, const typename ModelTpl< Scalar, Options, JointCollectionTpl >::JointModel &rootJoint, const std::string &rootJointName, ModelTpl< Scalar, Options, JointCollectionTpl > &model, PINOCCHIO_STD_VECTOR_WITH_EIGEN_ALLOCATOR(RigidConstraintModel) &contact_models, const std::string &rootLinkName="", const std::vector< std::string > &parentGuidance={}, const bool verbose=false)
Build the model from a SDF file with a particular joint as root of the model tree inside the model gi...
hpp::fcl::MeshLoaderPtr
std::shared_ptr< MeshLoader > MeshLoaderPtr
Definition: meshloader-fwd.hpp:25
pinocchio::RigidConstraintModelTpl
Definition: algorithm/constraints/fwd.hpp:14
filename
filename
urdf.hpp
pinocchio::JointModelTpl
Definition: multibody/joint/fwd.hpp:155
geometry.hpp
PINOCCHIO_STD_VECTOR_WITH_EIGEN_ALLOCATOR
#define PINOCCHIO_STD_VECTOR_WITH_EIGEN_ALLOCATOR(T)
Definition: container/aligned-vector.hpp:13
pinocchio::GeometryType
GeometryType
Definition: multibody/geometry-object.hpp:24
pinocchio::RigidConstraintModel
RigidConstraintModelTpl< context::Scalar, context::Options > RigidConstraintModel
Definition: algorithm/fwd.hpp:24
pinocchio::GeometryModel
Definition: multibody/geometry.hpp:50
contact-cholesky.contact_models
list contact_models
Definition: contact-cholesky.py:22
contact-info.hpp
pinocchio::ModelTpl
Definition: context/generic.hpp:20
verbose
bool verbose
pinocchio::model
JointCollectionTpl & model
Definition: joint-configuration.hpp:1082
pinocchio
Main pinocchio namespace.
Definition: timings.cpp:27
pinocchio::ModelTpl::JointModel
JointModelTpl< Scalar, Options, JointCollectionTpl > JointModel
Definition: multibody/model.hpp:72


pinocchio
Author(s):
autogenerated on Thu Dec 19 2024 03:41:32