Skip to content

Commit

Permalink
[bindings] Add precisions to documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
Megane Millan committed Jul 9, 2024
1 parent cc4583c commit dc5f902
Showing 1 changed file with 42 additions and 15 deletions.
57 changes: 42 additions & 15 deletions include/pinocchio/bindings/python/multibody/joint/joints-models.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,9 @@ namespace pinocchio
bp::class_<context::JointModelRX> &
expose_joint_model<context::JointModelRX>(bp::class_<context::JointModelRX> & cl)
{
return cl.def(bp::init<>(bp::args("self"), "Init JointModelRX with x as rotation axis"))
return cl
.def(bp::init<>(
bp::args("self"), "Init JointModelRX with the X axis ([1, 0, 0]) as rotation axis."))
.def(
"getMotionAxis", &context::JointModelRX::getMotionAxis,
"Rotation axis of the JointModelRX.");
Expand All @@ -41,7 +43,9 @@ namespace pinocchio
bp::class_<context::JointModelRY> &
expose_joint_model<context::JointModelRY>(bp::class_<context::JointModelRY> & cl)
{
return cl.def(bp::init<>(bp::args("self"), "Init JointModelRY with y as rotation axis"))
return cl
.def(bp::init<>(
bp::args("self"), "Init JointModelRY with the Y axis ([0, 1, 0]) as rotation axis."))
.def(
"getMotionAxis", &context::JointModelRY::getMotionAxis,
"Rotation axis of the JointModelRY.");
Expand All @@ -51,7 +55,9 @@ namespace pinocchio
bp::class_<context::JointModelRZ> &
expose_joint_model<context::JointModelRZ>(bp::class_<context::JointModelRZ> & cl)
{
return cl.def(bp::init<>(bp::args("self"), "Init JointModelRZ with z as rotation axis"))
return cl
.def(bp::init<>(
bp::args("self"), "Init JointModelRZ with the Z axis ([0, 0, 1]) as rotation axis"))
.def(
"getMotionAxis", &context::JointModelRZ::getMotionAxis,
"Rotation axis of the JointModelRZ.");
Expand Down Expand Up @@ -80,7 +86,9 @@ namespace pinocchio
bp::class_<context::JointModelRUBX> &
expose_joint_model<context::JointModelRUBX>(bp::class_<context::JointModelRUBX> & cl)
{
return cl.def(bp::init<>(bp::args("self"), "Init JointModelRUBX with x as rotation axis"))
return cl
.def(bp::init<>(
bp::args("self"), "Init JointModelRUBX with the X axis ([1, 0, 0]) as rotation axis"))
.def(
"getMotionAxis", &context::JointModelRUBX::getMotionAxis,
"Rotation axis of the JointModelRUBX.");
Expand All @@ -90,7 +98,9 @@ namespace pinocchio
bp::class_<context::JointModelRUBY> &
expose_joint_model<context::JointModelRUBY>(bp::class_<context::JointModelRUBY> & cl)
{
return cl.def(bp::init<>(bp::args("self"), "Init JointModelRUBY with y as rotation axis"))
return cl
.def(bp::init<>(
bp::args("self"), "Init JointModelRUBY with the Y axis ([0, 1, 0]) as rotation axis"))
.def(
"getMotionAxis", &context::JointModelRUBY::getMotionAxis,
"Rotation axis of the JointModelRUBY.");
Expand All @@ -100,7 +110,9 @@ namespace pinocchio
bp::class_<context::JointModelRUBZ> &
expose_joint_model<context::JointModelRUBZ>(bp::class_<context::JointModelRUBZ> & cl)
{
return cl.def(bp::init<>(bp::args("self"), "Init JointModelRUBZ with z as rotation axis"))
return cl
.def(bp::init<>(
bp::args("self"), "Init JointModelRUBZ with the Z axis ([0, 0, 1]) as rotation axis"))
.def(
"getMotionAxis", &context::JointModelRUBZ::getMotionAxis,
"Rotation axis of the JointModelRUBZ.");
Expand All @@ -111,7 +123,9 @@ namespace pinocchio
bp::class_<context::JointModelPX> &
expose_joint_model<context::JointModelPX>(bp::class_<context::JointModelPX> & cl)
{
return cl.def(bp::init<>(bp::args("self"), "Init JointModelPX with x as rotation axis"))
return cl
.def(bp::init<>(
bp::args("self"), "Init JointModelPX with the X axis ([1, 0, 0]) as rotation axis"))
.def(
"getMotionAxis", &context::JointModelPX::getMotionAxis,
"Rotation axis of the JointModelPX.");
Expand All @@ -121,7 +135,9 @@ namespace pinocchio
bp::class_<context::JointModelPY> &
expose_joint_model<context::JointModelPY>(bp::class_<context::JointModelPY> & cl)
{
return cl.def(bp::init<>(bp::args("self"), "Init JointModelPY with y as rotation axis"))
return cl
.def(bp::init<>(
bp::args("self"), "Init JointModelPY with the Y axis ([0, 1, 0]) as rotation axis"))
.def(
"getMotionAxis", &context::JointModelPY::getMotionAxis,
"Rotation axis of the JointModelPY.");
Expand All @@ -131,7 +147,9 @@ namespace pinocchio
bp::class_<context::JointModelPZ> &
expose_joint_model<context::JointModelPZ>(bp::class_<context::JointModelPZ> & cl)
{
return cl.def(bp::init<>(bp::args("self"), "Init JointModelPZ with z as rotation axis"))
return cl
.def(bp::init<>(
bp::args("self"), "Init JointModelPZ with the Z axis ([0, 0, 1]) as rotation axis"))
.def(
"getMotionAxis", &context::JointModelPZ::getMotionAxis,
"Rotation axis of the JointModelPZ.");
Expand Down Expand Up @@ -183,8 +201,11 @@ namespace pinocchio
{
return cl
.def(bp::init<context::Scalar>(
bp::args("self", "pitch"), "Init JointModelHX with pitch value"))
.def(bp::init<>(bp::args("self"), "Init JointModelHX with pitch 0.0"))
bp::args("self", "pitch"),
"Init JointModelHX with pitch value and the X axis ([1, 0, 0]) as a rotation axis."))
.def(bp::init<>(
bp::args("self"),
"Init JointModelHX with pitch 0.0 and the X axis ([1, 0, 0]) as a rotation axis."))
.def(
"getMotionAxis", &context::JointModelHX::getMotionAxis,
"Rotation axis of the JointModelHX.")
Expand All @@ -197,8 +218,11 @@ namespace pinocchio
{
return cl
.def(bp::init<context::Scalar>(
bp::args("self", "pitch"), "Init JointModelHY with pitch value."))
.def(bp::init<>(bp::args("self"), "Init JointModelHY with pitch 0.0"))
bp::args("self", "pitch"),
"Init JointModelHY with pitch value and the Y axis ([0, 1, 0]) as a rotation axis."))
.def(bp::init<>(
bp::args("self"),
"Init JointModelHY with pitch 0.0 and the Y axis ([0, 1, 0]) as a rotation axis."))
.def(
"getMotionAxis", &context::JointModelHY::getMotionAxis,
"Rotation axis of the JointModelHY.")
Expand All @@ -211,8 +235,11 @@ namespace pinocchio
{
return cl
.def(bp::init<context::Scalar>(
bp::args("self", "pitch"), "Init JointModelHZ with pitch value"))
.def(bp::init<>(bp::args("self"), "Init JointModelHZ with pitch 0.0"))
bp::args("self", "pitch"),
"Init JointModelHZ with pitch value and the Z axis ([0, 0, 1]) as a rotation axis."))
.def(bp::init<>(
bp::args("self"),
"Init JointModelHZ with pitch 0.0 and the Z axis ([0, 0, 1]) as a rotation axis."))
.def(
"getMotionAxis", &context::JointModelHZ::getMotionAxis,
"Rotation axis of the JointModelHZ.")
Expand Down

0 comments on commit dc5f902

Please sign in to comment.