Updated voxel remesher defaults
Implements T97163 Newly created meshes have all voxel remesher checkboxes aside from Fix Poles enabled. Startup files updated with versioning. Reviewed By @JulianKaspar Differential Revision: https://developer.blender.org/D14608 Ref D14608
This commit is contained in:
parent
567aad9dcd
commit
d1418dd151
Notes:
blender-bot
2023-02-13 15:45:50 +01:00
Referenced by issue #97163, Updated voxel remesher defaults
|
@ -532,11 +532,12 @@ void BLO_update_defaults_startup_blend(Main *bmain, const char *app_template)
|
|||
for (Mesh *mesh = bmain->meshes.first; mesh; mesh = mesh->id.next) {
|
||||
/* Match default for new meshes. */
|
||||
mesh->smoothresh = DEG2RADF(30);
|
||||
/* Match voxel remesher options for all existing meshes in templates. */
|
||||
mesh->flag |= ME_REMESH_REPROJECT_VOLUME | ME_REMESH_REPROJECT_PAINT_MASK | ME_REMESH_REPROJECT_SCULPT_FACE_SETS | ME_REMESH_REPROJECT_VERTEX_COLORS;
|
||||
|
||||
/* For Sculpting template. */
|
||||
if (app_template && STREQ(app_template, "Sculpting")) {
|
||||
mesh->remesh_voxel_size = 0.035f;
|
||||
mesh->flag |= ME_REMESH_FIX_POLES | ME_REMESH_REPROJECT_VOLUME;
|
||||
BKE_mesh_smooth_flag_set(mesh, false);
|
||||
}
|
||||
else {
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
.remesh_voxel_adaptivity = 0.0f, \
|
||||
.face_sets_color_seed = 0, \
|
||||
.face_sets_color_default = 1, \
|
||||
.flag = ME_REMESH_FIX_POLES | ME_REMESH_REPROJECT_VOLUME, \
|
||||
.flag = ME_REMESH_REPROJECT_VOLUME | ME_REMESH_REPROJECT_PAINT_MASK | ME_REMESH_REPROJECT_SCULPT_FACE_SETS | ME_REMESH_REPROJECT_VERTEX_COLORS, \
|
||||
.editflag = ME_EDIT_MIRROR_VERTEX_GROUPS \
|
||||
}
|
||||
|
||||
|
|
|
@ -3451,20 +3451,17 @@ static void rna_def_mesh(BlenderRNA *brna)
|
|||
|
||||
prop = RNA_def_property(srna, "use_remesh_preserve_paint_mask", PROP_BOOLEAN, PROP_NONE);
|
||||
RNA_def_property_boolean_sdna(prop, NULL, "flag", ME_REMESH_REPROJECT_PAINT_MASK);
|
||||
RNA_def_property_boolean_default(prop, false);
|
||||
RNA_def_property_ui_text(prop, "Preserve Paint Mask", "Keep the current mask on the new mesh");
|
||||
RNA_def_property_update(prop, 0, "rna_Mesh_update_draw");
|
||||
|
||||
prop = RNA_def_property(srna, "use_remesh_preserve_sculpt_face_sets", PROP_BOOLEAN, PROP_NONE);
|
||||
RNA_def_property_boolean_sdna(prop, NULL, "flag", ME_REMESH_REPROJECT_SCULPT_FACE_SETS);
|
||||
RNA_def_property_boolean_default(prop, false);
|
||||
RNA_def_property_ui_text(
|
||||
prop, "Preserve Face Sets", "Keep the current Face Sets on the new mesh");
|
||||
RNA_def_property_update(prop, 0, "rna_Mesh_update_draw");
|
||||
|
||||
prop = RNA_def_property(srna, "use_remesh_preserve_vertex_colors", PROP_BOOLEAN, PROP_NONE);
|
||||
RNA_def_property_boolean_sdna(prop, NULL, "flag", ME_REMESH_REPROJECT_VERTEX_COLORS);
|
||||
RNA_def_property_boolean_default(prop, false);
|
||||
RNA_def_property_ui_text(
|
||||
prop, "Preserve Vertex Colors", "Keep the current vertex colors on the new mesh");
|
||||
RNA_def_property_update(prop, 0, "rna_Mesh_update_draw");
|
||||
|
|
Loading…
Reference in New Issue