2015-04-22 23:35:27 +00:00
|
|
|
#ifndef MY_URDF_IMPORTER_H
|
|
|
|
#define MY_URDF_IMPORTER_H
|
|
|
|
|
|
|
|
#include "URDFImporterInterface.h"
|
|
|
|
|
|
|
|
|
|
|
|
class MyURDFImporter : public URDFImporterInterface
|
|
|
|
{
|
|
|
|
|
|
|
|
struct MyURDFInternalData* m_data;
|
|
|
|
|
|
|
|
|
|
|
|
public:
|
|
|
|
|
2015-04-23 22:41:17 +00:00
|
|
|
MyURDFImporter(struct GUIHelperInterface* guiHelper);
|
|
|
|
|
2015-04-22 23:35:27 +00:00
|
|
|
virtual ~MyURDFImporter();
|
2015-04-23 22:41:17 +00:00
|
|
|
|
|
|
|
virtual bool loadURDF(const char* fileName);
|
|
|
|
|
|
|
|
const char* getPathPrefix();
|
|
|
|
|
|
|
|
void printTree(); //for debugging
|
2015-04-22 23:35:27 +00:00
|
|
|
|
2015-04-23 22:41:17 +00:00
|
|
|
virtual int getRootLinkIndex() const;
|
2015-04-22 23:35:27 +00:00
|
|
|
|
|
|
|
virtual void getLinkChildIndices(int linkIndex, btAlignedObjectArray<int>& childLinkIndices) const;
|
|
|
|
|
|
|
|
virtual std::string getLinkName(int linkIndex) const;
|
|
|
|
|
|
|
|
virtual std::string getJointName(int linkIndex) const;
|
|
|
|
|
|
|
|
virtual void getMassAndInertia(int linkIndex, btScalar& mass,btVector3& localInertiaDiagonal, btTransform& inertialFrame) const;
|
|
|
|
|
|
|
|
virtual bool getJointInfo(int urdfLinkIndex, btTransform& parent2joint, btVector3& jointAxisInJointSpace, int& jointType, btScalar& jointLowerLimit, btScalar& jointUpperLimit) const;
|
|
|
|
|
2015-04-23 22:41:17 +00:00
|
|
|
virtual int convertLinkVisualShapes(int linkIndex, const char* pathPrefix, const btTransform& localInertiaFrame) const;
|
2015-04-22 23:35:27 +00:00
|
|
|
|
|
|
|
virtual class btCompoundShape* convertLinkCollisionShapes(int linkIndex, const char* pathPrefix, const btTransform& localInertiaFrame) const;
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
#endif //MY_URDF_IMPORTER_H
|