This implements the insert mesh tool. Brushes for that use the insert
mesh tool can have a reference to a mesh datablock. They insert that
mesh into the sculpt mesh, using the grab delta orientation and the
sculpt symmetry options.
The brush has 3 placement and 3 modes to initialize the Face Sets of
the new geometry:
Face Set creation modes:
This is a special case of brush that requires a PBVH rebuild during the
stroke and a SCULPT_UNDO_GEOMETRY push. If this is something we want to
support, I would like to have this functionality in place to take it
into account for upcoming refactors and optimizations.
As this is an example of tools that requires another datablock to be
referenced from a brush, it can be useful to have when designing the
brush management as well.
The tool is set to experimental for the following reasons:
- Without brush management, supporting this tool does not make any sense as you need to setup the brushes with the insert meshes each time you want to use it.
- This implementation won't work on high poly meshes. It requires a BMesh conversion per symmetry pass and a PBVH rebuild each time a stroke starts.
- It also leaves the PBVH in a highly deformed state when the stroke ends, it probably needs an additional rebuild.
- It does not work with dyntopo and multires (at least it should work with dyntopo when enabling all features after the optimization).
- It does not have icon.