Page MenuHome

Small change to speedup adding rigid bodies
ClosedPublic

Authored by Jagannadhan Ravi (easythrees) on Jul 18 2021, 2:33 AM.
Tags
None
Tokens
"Love" token, awarded by franMarz."Love" token, awarded by Schamph."Love" token, awarded by YAFU."100" token, awarded by jimman2003.

Details

Summary

Fix: When adding rigid bodies to multiple objects, do them all at once and not one by one in python.

On my (Intel) MacBook, step one of the workflow (in the attached scene), used to take 60 seconds and with this change it takes about 0.3 seconds.

(the workflow is mentioned when you open the scene file)

Diff Detail

Repository
rB Blender

Event Timeline

Jagannadhan Ravi (easythrees) requested review of this revision.Jul 18 2021, 2:33 AM
Jagannadhan Ravi (easythrees) created this revision.

this really isn't mine to review

This revision is now accepted and ready to land.Jul 20 2021, 4:24 PM
Sebastian Parborg (zeddb) requested changes to this revision.Jul 20 2021, 4:31 PM

Or hmm, I spoke too soon. I think that you should restore the selected status to the objects that you copy settings to.

Otherwise uses might get the wrong impression if objects object that has settings copied over got deselected after the operation.

This revision now requires changes to proceed.Jul 20 2021, 4:31 PM

Or hmm, I spoke too soon. I think that you should restore the selected status to the objects that you copy settings to.

Otherwise uses might get the wrong impression if objects object that has settings copied over got deselected after the operation.

I’ll check the workflow again but the selection never goes away after the copy, is this just to make sure the selection before the operation stays after the operation?

Ensuring objects' selection is retained.

Or hmm, I spoke too soon. I think that you should restore the selected status to the objects that you copy settings to.

Otherwise uses might get the wrong impression if objects object that has settings copied over got deselected after the operation.

I’ll check the workflow again but the selection never goes away after the copy, is this just to make sure the selection before the operation stays after the operation?

No, this it to make sure that the objects the operation is applied to is selected.

Basically if you had any non mesh objects they would be deselect to show that the operation did not apply to them.
Before you did your last change, it would deselect objects that already had a rigidbody associated with them.

So what I want to happen is to not preserve the initial select, but to only have the objects selected that had the operator applied to them, if this makes any sense:

In that example only the active object has a rigid body.

Based on clarification, ensuring the rigidbody objects we've de-selected get re-selected.

This revision is now accepted and ready to land.Jul 20 2021, 6:35 PM