Hello,
I am not sure if this is intended or something that was overlooked but I noticed following about collision margins (version 2.76 R1971:
btBoxShape-btBoxShape: 0 cm
btCylinderShapeZ-btBoxShape: 0 cm
btSphereShape-btBoxShape: 0 cm
btConeShapeZ-btBoxShape: 4 cm
btCylinderShapeZ-btCylinderShapeZ: 0 cm
btSphereShape-btCylinderShapeZ: 0 cm
btConeShapeZ-btCylinderShapeZ: 4 cm
btSphereShape-btSphereShape: 0 cm
btSphereShape-btConeShapeZ: 4 cm
btConeShapeZ-btConeShapeZ: 8 cm
It seems to me that the btConeShapeZ might have a problem (or different default setting) compared to the other collision shapes. Trying to set the btConeShapeZ collision margin to 0 with setMargin(0.0f) doesn't do anything. It also seems to have no effect with the other collision shapes mentioned above.
Did I misunderstand something?
btConeShapeZ and collision margin
-
- Posts: 34
- Joined: Fri Sep 18, 2009 5:41 am
Re: btConeShapeZ and collision margin
Well, I just noticed why the setMargin didn't have an effect: I wrap all collision shapes in a compound shape in order to freely adjust the inertia position/orientation relative to the shape, and I was setting the margin of the compound shape.
Setting the margin of the btConeShapeZ to zero works fine (it removed the gap of 4 or 8 centimeters, see above), but my question remains: why this difference with the btConeShapeZ (compared with btBoxShape, btCylinderShapeZ or btSphereShape where the margin doesn't need any adjustment)?
Thanks
Setting the margin of the btConeShapeZ to zero works fine (it removed the gap of 4 or 8 centimeters, see above), but my question remains: why this difference with the btConeShapeZ (compared with btBoxShape, btCylinderShapeZ or btSphereShape where the margin doesn't need any adjustment)?
Thanks