Skip to content
This repository was archived by the owner on Feb 3, 2025. It is now read-only.

New event: BeforePhysicsUpdate #1851

Closed
osrf-migration opened this issue Feb 1, 2016 · 7 comments
Closed

New event: BeforePhysicsUpdate #1851

osrf-migration opened this issue Feb 1, 2016 · 7 comments
Labels

Comments

@osrf-migration
Copy link

Original report (archived issue) by Martin Pecka (Bitbucket: peci1).


I want to do some advanced usage of ODE in Gazebo, and there is almost a blocker for me.

In ODE, you set contact surface parameter after collision checking, but before physics update (and that completely makes sense and I hope the other engines also do it like this).

There is no way for me to call custom code in between the UpdateCollision() and UpdatePhysics() calls in the World::Update callback.

I only have a possible workaround - to disable the physics engine, make an update (which will do the collision checking and not the physics update), then call my custom code, and call UpdatePhysics() manually afterwards. This may however break a lot of things connected to the WolrdUpdateEnd event, since it'd be called before the actual physics update.

So I propose creating a new event, called e.g. BeforePhysicsUpdate, that'd be triggered after UpdateCollision and before UpdatePhysics.

@osrf-migration
Copy link
Author

Original comment by Nate Koenig (Bitbucket: Nathan Koenig).


That sounds like a reasonable idea. Feel free to make a pull request to the gazebo7 branch with this change.

@osrf-migration
Copy link
Author

Original comment by Martin Pecka (Bitbucket: peci1).


Okay. I'll prepare it.

Could you give me a clue how is it with the ABI compatibility? Can I add
a new event to Events.cc/Events.hh without breaking it? Or I don't have
to care about it in the gazebo7 branch?

Martin Pecka

@osrf-migration
Copy link
Author

Original comment by Nate Koenig (Bitbucket: Nathan Koenig).


New events shouldn't break ABI compatibility.

@osrf-migration
Copy link
Author

@osrf-migration
Copy link
Author

Original comment by Nate Koenig (Bitbucket: Nathan Koenig).


  • changed state from "new" to "resolved"

Resolved in pull request #2128

@osrf-migration
Copy link
Author

Original comment by Nate Koenig (Bitbucket: Nathan Koenig).


  • set version to "all"

@osrf-migration
Copy link
Author

Original comment by Nate Koenig (Bitbucket: Nathan Koenig).


  • changed state from "resolved" to "closed"

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

1 participant