This is a design proposal for the challenge of preserving instances while applying a modifier. This is particular relevant for the Dog Walk open game project.
Design workshop by:
Dalai Felinto
Simon Thomems
Visual Geometry to Editable
Design
A way to get the exact same result for the current frame as destructive data, while keeping instances.
Use Cases
Apply modifier to make manual changes (nudge, remove instances).
Sculpting after a cloth simulation for a bed sheet.
Export set dressed scene into a game engine preserving instances.
Edit cached data (e.g., Alembic imports).
Problem
There is no way to get the exact same result for the current frame:
For destructive edits.
I/O.
Make Instances Real does not retain sharing instance data. (e.g. set dressing).
Solution analysis:
The behaviour overlaps with:
Apply Modifier
Make Instances Real
Visual Geometry to Mesh
bpy.ops.object.convert(target='MESH')
ob.to_mesh()
ob.evaluated_get(depsgraph)
Solution
A new operator (Visual Geometry to Editable), that creates new objects (if needed), apply all modifications present on the current frame, and preserve instancing.
Operator on the object level.
Otherwise we canāt always support well applying the first modifier while keeping the same results.
Convert evaluated data into real data.
Create new objects for procedural geometries.
One object per component of each geometry set.
Objects should have no geometry nodes modifier.
Procedural geometries which are only instanced need to be hidden in the viewport.
Maybe put them in a collection and hide the collection.
Or even, put then in a collection excluded from the View Layers.
Create one Empty for each instanced object.
[Optional] Support Empty object instancing.
This would simplify things, but it is not required.
Otherwise we need to create new collections to instance the objects.
Naming
The newly created objects need a good name schema base.
Procedural geometries:
Named after the Geometry Set + component (if multiple components).
Fallback to the object name + component (e.g., Chair.Curve).
Empties:
Named after whatās been instanced.
Operator (redo) Options
Parent (same as Make Instances Real).
Keep Hierarchy (same as Make Instances Real).
For nested instances.
Keep Original (same as Convert).
Realize Instances.
[Future]: Instance Type (Point Cloud / Empties).
Future
Enhanced functionality that should not be blocking for this feature.
Point Cloud Instance
Implement object or collection instancing for individual points within a point cloud.
Needs basic edit mode for point cloud.
Selection / selection per-instance
Transform (location/rotation/scale).
Add/Copy/Delete.
Set Attribute.
Set Instance.
Operator to convert back/forth from Empties to Point Cloud instances
Convert To ā Empty.
Convert To ā Point Cloud.
(Enhanced) Apply Modifier
This could replace the existing Apply Modifier (on a modifier level). For this we need to support multiple components as original data for a single object.
Hi, thatās great news! This has been on my checklist for the last 2 years.
I create complete scenes with GN and have been struggling with exporting them to other engines while keeping the instance data.
I really like the proposal, but Iād like to suggest another option for the redo panel:
Instances as different objects with the same shared data- essentially turning each instance Geometry Set into a collection with multiple new objects (one for every domain), while keeping the object data shared between objects of the same domain.
This is similar to the ārealize instanceā option in that it creates many identical collections (discarding their āinstanceā trait), but it still keeps all the mesh/curve/point data shared.
On the other hand, it creates a simpler output without the need to create an excluded collection to hold the instanced objects.
The integration into the blender ecosystem is also easier as for example you can just enter into edit mode and change the underline mesh, or select a single object to make it unique.
I was also contemplating about chaining nested instances in the form of parent-child, but Iām not sure how that gonna work,it is an important aspect of instances and their holding Geometry Set that isnāt apparent in the other options of the operator, but Iām not sure which of blender current structure can do that.
If something isnāt clear I can make a simple mockup.
ah, it may be good idea to add mockups to the original proposal to demonstrate the differences between the different operators.
The moment something touch nested instance everything tend to become confusing, especially for comparing similar (counted 4) operators.
There is another issue related to the application of modifiers. During the development of Claypencil, we have seen that it is very interesting to be able to convert the mesh generated from Grease Pencil into a ārealā mesh in order to be able to make adjustments manually. The current problem is that when applying the modifier, you get nothing, since the generated geometry is Mesh and the apply tries to create GP data. It would be super interesting to be able to create these meshes (now it is possible with some trick) and be able to manipulate them, in addition this would be related to the animation of meshes using several datablocks for the same object, as we did in the experimental Claymation add-on that we have. All this is related to creating a new 3D animation workflow without the need to create rigs. It is not valid for all productions but it is something with immense potential.
Another note (I apologize for the clutter): you could include the GLTF export-import (you need to check: Data ā Scene Graph ā Geometry Nodes Instances (experimental)) as another method to āget instances from GN as editable data.ā This method is also the most accurate of them all and the most similar to the proposed intended outcome.
Iām not actively working on that. There are plans for this, but donāt expect them to happen this year. First the slotted Actions need to be released in 4.4 and gotten feedback + polish. Only once that has happened we can work on adding layered keyframe animation workflows. And then we have a basis for other animation data types, such as the āID chooserā (working title).
So you want to convert GP that has Claypencil to Mesh, but also keep whole animation (which might have different number of verts each frame, rights?)
Animating object data is possible with Keymesh, I have made baking operators for it. This is the use-case Iām interested in. Text me on chat with some examples and I can make it work.
The idea is to have different mesh data (with different number of points) and be able to animate. I did part of Keymesh add-on and then create the replacement of this add-on name āClaymationā. Iām working with Daniel M. Lara y Matias Mendiola in this project and we have seen the use of an add-on has limitations, so this is the reason why we want to move this logic to ācoreā Blender using datablock animation.
Yes, I know, itās not something that will be done in the near future, I just mention it to include it in the future vision of animation systems. Thank you for considering it as a medium-term project.
Forgive me if this seems a bit naive, but regarding the ākeep instancesā part, has it been considered making instances editable as an object type, like meshes and curves ? since instances can already exist inside a single object through geometry nodes, I figured this could overlap with the āsingle object typeā project, instances being yet another type added to the list. This way the operator could be made a little less destructive by not requiring the creation of a bunch of objects.
I donāt make games though, so this might be ill-advised anyway. Maybe you do want separate objects for export purposes.
This is exaclty what the āPoint Cloud Instanceā topic refers to. So yes, it has been considered, but we donāt want to make it blocking for us to get this feature in.