mc_rtc  2.14.0
surface_utils.h
Go to the documentation of this file.
1 /*
2  * Copyright 2015-2019 CNRS-UM LIRMM, CNRS-AIST JRL
3  */
4 
5 #pragma once
6 #include <mc_rbdyn/api.h>
7 
8 #include <SpaceVecAlg/SpaceVecAlg>
9 #include <memory>
10 #include <string>
11 #include <tinyxml2.h>
12 #include <vector>
13 
14 namespace mc_rbdyn
15 {
16 
17 struct Surface;
18 
27 MC_RBDYN_DLLAPI tinyxml2::XMLElement * tfToOriginDom(tinyxml2::XMLDocument & doc,
28  const sva::PTransformd & X,
29  const std::string_view & tagName = "origin");
30 MC_RBDYN_DLLAPI sva::PTransformd tfFromOriginDom(const tinyxml2::XMLElement & dom);
31 
39 MC_RBDYN_DLLAPI void surfacesToXML(tinyxml2::XMLDocument & doc,
40  const std::string & robotName,
41  const std::vector<std::shared_ptr<Surface>> & surfaces);
42 
49 MC_RBDYN_DLLAPI std::vector<std::shared_ptr<Surface>> readRSDFFromDir(const std::string & dirname);
50 
51 } // namespace mc_rbdyn
#define MC_RBDYN_DLLAPI
Definition: api.h:50
Definition: generic_gripper.h:15
MC_RBDYN_DLLAPI std::vector< std::shared_ptr< Surface > > readRSDFFromDir(const std::string &dirname)
Read all RSDF files from a directory and parse them into Surface objects.
MC_RBDYN_DLLAPI void surfacesToXML(tinyxml2::XMLDocument &doc, const std::string &robotName, const std::vector< std::shared_ptr< Surface >> &surfaces)
Add a <robot> element and its surfaces to an XML document.
MC_RBDYN_DLLAPI sva::PTransformd tfFromOriginDom(const tinyxml2::XMLElement &dom)
MC_RBDYN_DLLAPI tinyxml2::XMLElement * tfToOriginDom(tinyxml2::XMLDocument &doc, const sva::PTransformd &X, const std::string_view &tagName="origin")
Create an <origin> XML element from a spatial transform.
impl::Abscissa< GetT > X(AxisConfiguration config, GetT get_fn)
Definition: Abscissa.h:75