Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Do not destroy bodyTransform #46

Conversation

Elettrotecnica
Copy link

this is in fact the btTranform returned by .getCenterOfMassTransform, that is, protected member m_worldTransform of the btCollisionObject class and not an object instantiated locally

Deleting this object will eventually lead to an out of bound access error that will prevent any further constraint

See https://pybullet.org/Bullet/BulletFull/classbtRigidBody.html#a5eaee89e89e7498cfb39709e58fdc477

I also attach a toy example where I continuously toggle a constraint between an object and the camera and a screenshot of the error.

Error Screenshot
toy-example.zip

…ned by .getCenterOfMassTransform, that is, protected member m_worldTransform of the btCollisionObject class and not an object instantiated locally

Deleting this object will eventually lead to an out of bound access error that will prevent any further constraint

See https://pybullet.org/Bullet/BulletFull/classbtRigidBody.html#a5eaee89e89e7498cfb39709e58fdc477
@diarmidmackenzie
Copy link
Member

Yes, agreed. Thank you for the fix.

@diarmidmackenzie diarmidmackenzie merged commit b2b2e02 into c-frame:master Oct 11, 2023
4 of 6 checks passed
@Elettrotecnica Elettrotecnica deleted the don-t-destroy-constraint-body-transform branch December 28, 2023 11:34
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants