From c372318165cd56e9c09eb5792714d9efd98ff265 Mon Sep 17 00:00:00 2001 From: Pablo Dobarro Date: Fri, 27 Sep 2019 17:41:05 +0200 Subject: Voxel remesh: Enable adaptivity This commit enables OpenVDB adaptivity in the voxel remesher. It can be useful to reduce the polygon count if you want to switch to dyntopo after using the voxel remesher workflow. Reviewed By: brecht Differential Revision: https://developer.blender.org/D5918 --- source/blender/makesrna/intern/rna_mesh.c | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'source/blender/makesrna/intern/rna_mesh.c') diff --git a/source/blender/makesrna/intern/rna_mesh.c b/source/blender/makesrna/intern/rna_mesh.c index ce2911cbb01..d5fc422a9f9 100644 --- a/source/blender/makesrna/intern/rna_mesh.c +++ b/source/blender/makesrna/intern/rna_mesh.c @@ -2995,6 +2995,17 @@ static void rna_def_mesh(BlenderRNA *brna) "values preserve finer details"); RNA_def_property_update(prop, 0, "rna_Mesh_update_draw"); + prop = RNA_def_property(srna, "remesh_voxel_adaptivity", PROP_FLOAT, PROP_DISTANCE); + RNA_def_property_float_sdna(prop, NULL, "remesh_voxel_adaptivity"); + RNA_def_property_range(prop, 0.0f, 1.0f); + RNA_def_property_ui_range(prop, 0.0f, 1.0f, 0.01, 4); + RNA_def_property_ui_text( + prop, + "Adaptivity", + "Reduces the final face count by simplifying geometry where detail is not needed, " + "generating triangles. A value greater than 0 disables Fix Poles"); + RNA_def_property_update(prop, 0, "rna_Mesh_update_draw"); + prop = RNA_def_property(srna, "remesh_smooth_normals", PROP_BOOLEAN, PROP_NONE); RNA_def_property_boolean_sdna(prop, NULL, "flag", ME_REMESH_SMOOTH_NORMALS); RNA_def_property_ui_text(prop, "Smooth Normals", "Smooth the normals of the remesher result"); -- cgit v1.2.3