Can I get the position of multiple objects at once

Post Reply
xyjbaal
Posts: 2
Joined: Mon Feb 07, 2022 6:01 am

Can I get the position of multiple objects at once

Post by xyjbaal »

I'm using pybullet to simulate some object stacking, there be about 1000 objects.
I need to constantly monitor the position of each object,
but getBasePositionAndOrientation() can only get the position of one object, and if I use a for() loop, it will be very slow.
It takes about 5 minutes each time to get the current position of all the objects.

I would like to ask if there is a good solution for this? :?:
User avatar
drleviathan
Posts: 849
Joined: Tue Sep 30, 2014 6:03 pm
Location: San Francisco

Re: Can I get the position of multiple objects at once

Post by drleviathan »

This forum is focused mostly on the C++ core Bullet libs. Try asking this question in the forum focused on the python API.

I don't know about your project requirements but... if you're simulating 5k objects and are concerned about speed you might consider running it on a C++ executable.
xyjbaal
Posts: 2
Joined: Mon Feb 07, 2022 6:01 am

Re: Can I get the position of multiple objects at once

Post by xyjbaal »

Sorry, I put the question in the wrong place.
Thanks for the suggestion, maybe I'll have to use c++
Post Reply