Skip to content
Snippets Groups Projects
Commit ff23b0c5 authored by jcarpent's avatar jcarpent
Browse files

[Python] Expose default signature of existFrame

parent aafd6d81
Branches
Tags
No related merge requests found
......@@ -20,6 +20,7 @@
#define __se3_python_model_hpp__
#include <boost/python/suite/indexing/vector_indexing_suite.hpp>
#include <boost/python/overloads.hpp>
#include <eigenpy/memory.hpp>
#include "pinocchio/multibody/model.hpp"
......@@ -35,6 +36,8 @@ namespace se3
{
namespace bp = boost::python;
BOOST_PYTHON_MEMBER_FUNCTION_OVERLOADS(existFrame_overload,Model::existFrame,1,2)
struct ModelPythonVisitor
: public boost::python::def_visitor< ModelPythonVisitor >
{
......@@ -128,7 +131,9 @@ namespace se3
.def("getJointId",&Model::getJointId, bp::args("name"), "Return the index of a joint given by its name")
.def("existJointName", &Model::existJointName, bp::args("name"), "Check if a joint given by its name exists")
.def("getFrameId",&Model::getFrameId,bp::args("name"),"Returns the index of the frame given by its name. If the frame is not in the frames vector, it returns the current size of the frames vector.")
.def("existFrame",&Model::existFrame,bp::args("name"),"Returns true if the frame given by its name exists inside the Model.")
.def("existFrame",&Model::existFrame,existFrame_overload(bp::arg("name"),"Returns true if the frame given by its name exists inside the Model."))
.def("existFrame",&Model::existFrame,existFrame_overload(bp::args("name","type"),"Returns true if the frame given by its name exists inside the Model with the given type."))
.def("addFrame",(bool (Model::*)(const std::string &,const JointIndex, const FrameIndex, const SE3 &,const FrameType &)) &Model::addFrame,bp::args("name","parent_id","placement","type"),"Add a frame to the vector of frames. See also Frame for more details. Returns False if the frame already exists.")
.def("addFrame",(bool (Model::*)(const Frame &)) &Model::addFrame,bp::args("frame"),"Add a frame to the vector of frames.")
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment