bullet3 icon indicating copy to clipboard operation
bullet3 copied to clipboard

pybullet.getClosestPoints gives wrong distance with obj-models

Open hubernikus opened this issue 2 months ago • 0 comments

I have decomposes a complex gripper of a robot into multiple convex parts in order to have a more precise distance measurement in real-time. The decomposition was performed manually with blender (but should be the same as is obtained using pybullet.vhacd).

In order to look at the behavior, I simplified the problem into an urdf containing a single link, with an *.obj file of two cubes (2x2x2). I create two instance of this urdf file, which are 10 meters apart from each other.

When computing the distance measurement between these to instance using pybullet.getClosestPoints, the shortest distance is ~18 (=17.998), even though the closest cubes have a distance of 2. This indicates, that pybullet.getClosestPoints does not consider all the convex objects in the file, but only parts of it.

The visualization of the *obj files works without issues.

Files to replicate the issue two_cubes.zip

hubernikus avatar Apr 11 '24 06:04 hubernikus