[Bf-blender-cvs] [6303cb7bd00] master: Fix 80909: Switching to profile bevel can explode Curve geometry

Hans Goudey noreply at git.blender.org
Fri Sep 18 16:32:17 CEST 2020


Commit: 6303cb7bd00701ddc66a55c1731cc70982005ae1
Author: Hans Goudey
Date:   Fri Sep 18 09:32:09 2020 -0500
Branches: master
https://developer.blender.org/rB6303cb7bd00701ddc66a55c1731cc70982005ae1

Fix 80909: Switching to profile bevel can explode Curve geometry

We need to make sure the CurveProfile is initialized with the proper
number of segments when switching to profile bevel mode.

===================================================================

M	source/blender/makesrna/intern/rna_curve.c

===================================================================

diff --git a/source/blender/makesrna/intern/rna_curve.c b/source/blender/makesrna/intern/rna_curve.c
index 854c8757d4d..d73eea52f4b 100644
--- a/source/blender/makesrna/intern/rna_curve.c
+++ b/source/blender/makesrna/intern/rna_curve.c
@@ -1614,7 +1614,9 @@ static void rna_def_curve(BlenderRNA *brna)
   RNA_def_property_ui_text(
       prop, "Bevel Mode", "Determine how to build the curve's bevel geometry");
   RNA_def_property_enum_funcs(prop, NULL, "rna_Curve_bevel_mode_set", NULL);
-  RNA_def_property_update(prop, 0, "rna_Curve_update_data");
+  /* Use this update function so the curve profile is properly initialized when
+   * switching back to "Profile" mode after changing the resolution. */
+  RNA_def_property_update(prop, 0, "rna_Curve_bevel_resolution_update");
 
   prop = RNA_def_property(srna, "bevel_profile", PROP_POINTER, PROP_NONE);
   RNA_def_property_struct_type(prop, "CurveProfile");



More information about the Bf-blender-cvs mailing list