[Bf-blender-cvs] [5a4fcbf2e28] soc-2019-bevel-profiles: Bevel Modifier / ProfileWidget:Working writing and reading of profile widget, and therefore bevel modifiers with custom profile enabled.

Hans Goudey noreply at git.blender.org
Mon Jun 24 06:43:42 CEST 2019


Commit: 5a4fcbf2e2835690f7eaf60880a282b80f709ba8
Author: Hans Goudey
Date:   Mon Jun 24 00:42:52 2019 -0400
Branches: soc-2019-bevel-profiles
https://developer.blender.org/rB5a4fcbf2e2835690f7eaf60880a282b80f709ba8

Bevel Modifier / ProfileWidget:Working writing and reading of profile widget,
 and therefore bevel modifiers with custom profile enabled.

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

M	source/blender/blenloader/intern/readfile.c
M	source/blender/blenloader/intern/writefile.c

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

diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c
index 3f48b4ea103..ea681b3b520 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -2704,7 +2704,6 @@ static void direct_link_curvemapping(FileData *fd, CurveMapping *cumap)
 /** \name Read ProfileWidget
  * \{ */
 
-/* HANS-TODO: Use this in bevel modifier load functions? */
 static void direct_link_profilewidget(FileData *fd, ProfileWidget *prwidget)
 {
   prwidget->profile->path = newdataadr(fd, prwidget->profile->path);
diff --git a/source/blender/blenloader/intern/writefile.c b/source/blender/blenloader/intern/writefile.c
index cb01a11c268..57b4ddde648 100644
--- a/source/blender/blenloader/intern/writefile.c
+++ b/source/blender/blenloader/intern/writefile.c
@@ -958,8 +958,10 @@ static void write_curvemapping(WriteData *wd, CurveMapping *cumap)
 
 static void write_profilewidget(WriteData *wd, ProfileWidget *prwdgt)
 {
+  /* HANS-QUESTION: Why do I have to write the ProfilePath struct when the curvemapping write
+   * function doesn't have to do the analagous write? */
   writestruct(wd, DATA, ProfileWidget, 1, prwdgt);
-
+  writestruct(wd, DATA, ProfilePath, 1, prwdgt->profile);
   writestruct(wd, DATA, ProfilePoint, prwdgt->profile->totpoint, prwdgt->profile->path);
 }



More information about the Bf-blender-cvs mailing list