5 #ifdef PINOCCHIO_WITH_SDFORMAT
11 #include <boost/python.hpp>
20 #ifdef PINOCCHIO_WITH_SDFORMAT
24 GeometryModel geometry_model;
25 const std::string & rootLinkName =
"";
26 const std::string & packageDir =
"";
28 model,
path(filename),
type, geometry_model, rootLinkName, packageDir);
29 return geometry_model;
32 GeometryModel buildGeomFromSdf(
34 const bp::object & filename,
36 const std::string & rootLinkName)
38 GeometryModel geometry_model;
39 const std::string & packageDir =
"";
41 model,
path(filename),
type, geometry_model, rootLinkName, packageDir);
42 return geometry_model;
45 GeometryModel & buildGeomFromSdf(
47 const bp::object & filename,
49 GeometryModel & geometry_model,
50 const std::string & rootLinkName)
53 return geometry_model;
56 GeometryModel buildGeomFromSdf(
58 const bp::object & filename,
60 const std::string & rootLinkName,
63 GeometryModel geometry_model;
75 return geometry_model;
78 GeometryModel & buildGeomFromSdf(
80 const bp::object & filename,
82 GeometryModel & geometry_model,
83 const std::string & rootLinkName,
84 const bp::object & package_dir)
86 if (PyList_Check(package_dir.ptr()))
96 return geometry_model;
99 GeometryModel buildGeomFromSdf(
101 const bp::object & filename,
103 const std::string & rootLinkName,
106 std::vector<std::string> hints;
107 GeometryModel geometry_model;
109 model,
path(filename),
type, geometry_model, rootLinkName, hints, meshLoader);
110 return geometry_model;
113 GeometryModel & buildGeomFromSdf(
115 const bp::object & filename,
117 GeometryModel & geometry_model,
118 const std::string & rootLinkName,
121 std::vector<std::string> hints;
123 model,
path(filename),
type, geometry_model, rootLinkName, hints, meshLoader);
124 return geometry_model;
127 GeometryModel buildGeomFromSdf(
129 const bp::object & filename,
131 const std::string & rootLinkName,
132 const bp::object & package_dir,
135 GeometryModel geometry_model;
136 if (PyList_Check(package_dir.ptr()))
145 model,
path(filename),
type, geometry_model, rootLinkName,
path(package_dir), meshLoader);
147 return geometry_model;
150 GeometryModel & buildGeomFromSdf(
152 const bp::object & filename,
154 GeometryModel & geometry_model,
155 const std::string & rootLinkName,
156 const bp::object & package_dir,
159 if (PyList_Check(package_dir.ptr()))
168 model,
path(filename),
type, geometry_model, rootLinkName,
path(package_dir), meshLoader);
170 return geometry_model;
173 #endif // #ifdef PINOCCHIO_WITH_SDFORMAT
177 #ifdef PINOCCHIO_WITH_SDFORMAT
182 pinocchio::python::buildGeomFromSdf),
183 bp::args(
"model",
"sdf_filename",
"geom_type"),
184 "Parse the SDF file given as input looking for the geometry of the given input model and\n"
185 "return a GeometryModel containing either the collision geometries "
186 "(GeometryType.COLLISION) or the visual geometries (GeometryType.VISUAL).\n"
188 "\tmodel: model of the robot\n"
189 "\tsdf_filename: path to the SDF file containing the model of the robot\n"
190 "\tgeom_type: type of geometry to extract from the SDF file (either the VISUAL for display "
191 "or the COLLISION for collision detection).\n");
197 const bp::object &)
>(pinocchio::python::buildGeomFromSdf),
198 bp::args(
"model",
"sdf_filename",
"geom_type",
"root_link_name",
"package_dir"),
199 "Parse the SDF file given as input looking for the geometry of the given input model and\n"
200 "return a GeometryModel containing either the collision geometries "
201 "(GeometryType.COLLISION) or the visual geometries (GeometryType.VISUAL).\n"
203 "\tmodel: model of the robot\n"
204 "\tsdf_filename: path to the SDF file containing the model of the robot\n"
205 "\tgeom_type: type of geometry to extract from the SDF file (either the VISUAL for display "
206 "or the COLLISION for collision detection).\n"
207 "\tpackage_dir: path or vector of path pointing to the folder containing the meshes of the "
214 pinocchio::python::buildGeomFromSdf),
215 bp::args(
"model",
"sdf_filename",
"geom_type",
"root_link_name"),
216 "Parse the SDF file given as input looking for the geometry of the given input model and\n"
217 "return a GeometryModel containing either the collision geometries "
218 "(GeometryType.COLLISION) or the visual geometries (GeometryType.VISUAL).\n"
220 "\tmodel: model of the robot\n"
221 "\tsdf_filename: path to the SDF file containing the model of the robot\n"
222 "\tgeom_type: type of geometry to extract from the SDF file (either the VISUAL for display "
223 "or the COLLISION for collision detection).\n"
225 "This function does not take any hint concerning the location of the meshes of the robot.");
231 pinocchio::python::buildGeomFromSdf),
232 bp::args(
"model",
"sdf_filename",
"geom_type",
"geom_model",
"root_link_name"),
233 "Parse the SDF file given as input looking for the geometry of the given input model and\n"
234 "and store either the collision geometries (GeometryType.COLLISION) or the visual "
235 "geometries (GeometryType.VISUAL) in the geom_model given as input.\n"
237 "\tmodel: model of the robot\n"
238 "\tsdf_filename: path to the SDF file containing the model of the robot\n"
239 "\tgeom_type: type of geometry to extract from the SDF file (either the VISUAL for display "
240 "or the COLLISION for collision detection).\n"
241 "\tgeom_model: reference where to store the parsed information\n"
243 "This function does not take any hint concerning the location of the meshes of the robot.",
244 bp::return_internal_reference<4>());
250 pinocchio::python::buildGeomFromSdf),
252 "model",
"sdf_filename",
"geom_type",
"geom_model",
"root_link_name",
"package_dir"),
253 "Parse the SDF file given as input looking for the geometry of the given input model and\n"
254 "and store either the collision geometries (GeometryType.COLLISION) or the visual "
255 "geometries (GeometryType.VISUAL) in the geom_model given as input.\n"
257 "\tmodel: model of the robot\n"
258 "\tsdf_filename: path to the SDF file containing the model of the robot\n"
259 "\tgeom_type: type of geometry to extract from the SDF file (either the VISUAL for display "
260 "or the COLLISION for collision detection).\n"
261 "\tgeom_model: reference where to store the parsed information\n"
262 "\tpackage_dir: path or vector of path pointing to the folder containing the meshes of the "
264 bp::return_internal_reference<4>());
271 pinocchio::python::buildGeomFromSdf),
273 "model",
"sdf_filename",
"geom_type",
"root_link_name",
"package_dir",
"mesh_loader"),
274 "Parse the SDF file given as input looking for the geometry of the given input model and\n"
275 "return a GeometryModel containing either the collision geometries "
276 "(GeometryType.COLLISION) or the visual geometries (GeometryType.VISUAL).\n"
278 "\tmodel: model of the robot\n"
279 "\tsdf_filename: path to the SDF file containing the model of the robot\n"
280 "\tgeom_type: type of geometry to extract from the SDF file (either the VISUAL for display "
281 "or the COLLISION for collision detection).\n"
282 "\tpackage_dir: path pointing to the folder containing the meshes of the robot\n"
283 "\tmesh_loader: an hpp-fcl mesh loader (to load only once the related geometries).");
290 pinocchio::python::buildGeomFromSdf),
292 "model",
"sdf_filename",
"geom_type",
"geom_model",
"root_link_name",
"package_dir",
294 "Parse the SDF file given as input looking for the geometry of the given input model and\n"
295 "and store either the collision geometries (GeometryType.COLLISION) or the visual "
296 "geometries (GeometryType.VISUAL) in the geom_model given as input.\n"
298 "\tmodel: model of the robot\n"
299 "\tsdf_filename: path to the SDF file containing the model of the robot\n"
300 "\tgeom_type: type of geometry to extract from the SDF file (either the VISUAL for display "
301 "or the COLLISION for collision detection).\n"
302 "\tgeom_model: reference where to store the parsed information\n"
303 "\tpackage_dir: path or vector of path pointing to the folder containing the meshes of the "
305 "\tmesh_loader: an hpp-fcl mesh loader (to load only once the related geometries).",
306 bp::return_internal_reference<4>());
313 bp::args(
"model",
"sdf_filename",
"geom_type",
"root_link_name",
"mesh_loader"),
314 "Parse the SDF file given as input looking for the geometry of the given input model and\n"
315 "return a GeometryModel containing either the collision geometries "
316 "(GeometryType.COLLISION) or the visual geometries (GeometryType.VISUAL).\n"
318 "\tmodel: model of the robot\n"
319 "\tsdf_filename: path to the SDF file containing the model of the robot\n"
320 "\tgeom_type: type of geometry to extract from the SDF file (either the VISUAL for display "
321 "or the COLLISION for collision detection).\n"
322 "\tmesh_loader: an hpp-fcl mesh loader (to load only once the related geometries).\n"
324 "This function does not take any hint concerning the location of the meshes of the robot.");
331 pinocchio::python::buildGeomFromSdf),
333 "model",
"sdf_filename",
"geom_type",
"geom_model",
"root_link_name",
"mesh_loader"),
334 "Parse the SDF file given as input looking for the geometry of the given input model and\n"
335 "and store either the collision geometries (GeometryType.COLLISION) or the visual "
336 "geometries (GeometryType.VISUAL) in the geom_model given as input.\n"
338 "\tmodel: model of the robot\n"
339 "\tsdf_filename: path to the SDF file containing the model of the robot\n"
340 "\tgeom_type: type of geometry to extract from the SDF file (either the VISUAL for display "
341 "or the COLLISION for collision detection).\n"
342 "\tgeom_model: reference where to store the parsed information\n"
343 "\tmesh_loader: an hpp-fcl mesh loader (to load only once the related geometries).\n"
345 "This function does not take any hint concerning the location of the meshes of the robot.",
346 bp::return_internal_reference<4>());