Home | Tutorials | Wiki | Issues
Ask Your Question
0

Joint world pose for each step of simulation

asked 2018-08-13 23:09:43 -0600

jc gravatar image

updated 2018-08-13 23:10:23 -0600

How would I obtain joint world pose data for each step in a simulation? I have a model plugin that can get the joint position before the simulation is run, but how do I get the joint world pose for each simulation step?

Thanks!

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
2

answered 2018-08-14 04:04:54 -0600

Veztak gravatar image

If you have a function that gets the joint world pose before simulation i assume you are calling it in the Load() function of the plugin. You can then, in the same way, call your function in the OnUpdate() loop. By my understanding, that gets called every iteration.

You can find a more detailed description at: Sensor OnUpdate

edit flag offensive delete link more

Comments

Thanks for the help! Outside of the tutorials where is this documented?

jc gravatar imagejc ( 2018-08-14 11:02:31 -0600 )edit
0

answered 2018-08-14 11:07:41 -0600

jc gravatar image

If anyone is interested, this tutorial helped me.

Add this to the Load() function:

      this->updateConnection = event::Events::ConnectWorldUpdateBegin(
      std::bind(&ModelPush::OnUpdate, this));

And delcare this variable:

    private: event::ConnectionPtr updateConnection;

And finally add the OnUpdate() function:

    public: void OnUpdate()
    {
    }
edit flag offensive delete link more
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2018-08-13 23:09:43 -0600

Seen: 83 times

Last updated: Aug 14