Commit: 9c241eae487f29f6eb3e996fb2d39c82ceeb0b75
Author: Pablo Dobarro
Date:   Sun Aug 16 19:00:38 2020 +0200
Branches: master
https://developer.blender.org/rB9c241eae487f29f6eb3e996fb2d39c82ceeb0b75

Fix T79597: Crash with dyntopo after paint cursor refactor

The paint cursor now uses a single call to
SCULPT_cursor_geometry_info_update and the Sculpt API to update both the
radius and the SculptSession data, so random access needs to be
initialized for dyntopo before using API functions.

Reviewed By: sergey

Maniphest Tasks: T79597

Differential Revision: https://developer.blender.org/D8489

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

M       source/blender/editors/sculpt_paint/sculpt.c

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

diff --git a/source/blender/editors/sculpt_paint/sculpt.c 
b/source/blender/editors/sculpt_paint/sculpt.c
index d68b1226b40..2fdf04a8b46 100644
--- a/source/blender/editors/sculpt_paint/sculpt.c
+++ b/source/blender/editors/sculpt_paint/sculpt.c
@@ -7125,6 +7125,7 @@ bool SCULPT_cursor_geometry_info_update(bContext *C,
 
   /* Update the active vertex of the SculptSession. */
   ss->active_vertex_index = srd.active_vertex_index;
+  SCULPT_vertex_random_access_ensure(ss);
   copy_v3_v3(out->active_vertex_co, SCULPT_active_vertex_co_get(ss));
 
   switch (BKE_pbvh_type(ss->pbvh)) {

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
https://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to