[Bf-committers] Proposal: Object creation
theeth at yahoo.com
Tue Oct 4 13:53:48 CEST 2011
The cleanest way to do that without having to hack anything in the operator system is having primitive modifiers.
Modifiers already have all the properties you need and more (being able to add more modifiers to the stack without losing your editable properties).
From: ""Martin Bürbaum"" <martin.buerbaum at gmx.at>
To: bf-blender developers <bf-committers at blender.org>
Sent: Tuesday, October 4, 2011 5:13:02 AM
Subject: [Bf-committers] Proposal: Object creation
Follow up of the "redo operator with last used settings (patch)" thread
I propose a new way of handling newly created objects in Blender.
I'm sure this may not have a high priority right now, but discussion and planning is never a bad thing IMHO.
I'll not go into detail how this should be implemented since Blenders internal architecture is still new to me. I'll add my basic ideas though.
C&C welcome (especially from the coding and framework perspective).
Everything created with an "Add" operator is initially locked from editing and can only be changed by tweaking its parameters (see below of editing).
My basic idea would be to store a unique identifier (operator name?) and the defining parameters (operator parameters?) in that object somehow.
Maybe making this its own object type (e.g. "Generated") would work?
The parameters of the object can then be tweaked (in object or edit-mode, see below) to ones linking.
I imagine this would be done by taking the the operator and parameters and "redo" them.
After creation you can enter edit mode, but you will not be able to change anything except the parameters.
When one wants to edit the data of the object directly (mesh/curve/etc.) it will be converted to an "editable" object.
That means that after that the object behaves no different than it does right now in Blender.
This can be done automatically (with a small prompt to the user) or explicitly by "unlocking" (i.e. converting) the object.
I'm not sure if dropping the operator & parameters it was created with is good or bad at this point.
If anybody is familiar with the way C4D handles newly added objects of certain types - this is pretty similar to that.
I implemented a very crude version of this behaviour when we started doing addon scripts, but the script could not enforce the lock (making this system kinda wonky).
Bf-committers mailing list
Bf-committers at blender.org
More information about the Bf-committers