Commit: 136f0910ff662a74b02c30ae9b79275bc74c8406
Author: Campbell Barton
Date:   Wed Mar 9 16:10:19 2022 +1100
Branches: master
https://developer.blender.org/rB136f0910ff662a74b02c30ae9b79275bc74c8406

Fix T96250: Invalid default for uv_relax_method

Correct the default & version existing files.

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

M       source/blender/blenloader/intern/versioning_300.c
M       source/blender/makesdna/DNA_scene_defaults.h

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

diff --git a/source/blender/blenloader/intern/versioning_300.c 
b/source/blender/blenloader/intern/versioning_300.c
index 2a840ea585a..32dcb977110 100644
--- a/source/blender/blenloader/intern/versioning_300.c
+++ b/source/blender/blenloader/intern/versioning_300.c
@@ -2578,5 +2578,12 @@ void blo_do_versions_300(FileData *fd, Library 
*UNUSED(lib), Main *bmain)
    */
   {
     /* Keep this block, even when empty. */
+
+    LISTBASE_FOREACH (Scene *, scene, &bmain->scenes) {
+      ToolSettings *ts = scene->toolsettings;
+      if (ts->uv_relax_method == 0) {
+        ts->uv_relax_method = UV_SCULPT_TOOL_RELAX_LAPLACIAN;
+      }
+    }
   }
 }
diff --git a/source/blender/makesdna/DNA_scene_defaults.h 
b/source/blender/makesdna/DNA_scene_defaults.h
index 82f788e0623..74db1d14bbc 100644
--- a/source/blender/makesdna/DNA_scene_defaults.h
+++ b/source/blender/makesdna/DNA_scene_defaults.h
@@ -360,6 +360,10 @@
     /* GP Stroke Placement */ \
     .gpencil_v3d_align = GP_PROJECT_VIEWSPACE, \
     .gpencil_v2d_align = GP_PROJECT_VIEWSPACE, \
+ \
+    /* UV painting */ \
+    .uv_sculpt_settings = 0, \
+    .uv_relax_method = UV_SCULPT_TOOL_RELAX_LAPLACIAN, \
   }
 
 /* clang-format off */

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
List details, subscription details or unsubscribe:
https://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to