diff options
author | Dalai Felinto <dfelinto@gmail.com> | 2017-02-15 17:30:07 +0300 |
---|---|---|
committer | Dalai Felinto <dfelinto@gmail.com> | 2017-02-15 17:52:28 +0300 |
commit | 226ba4477530b4059c9e2eb6701e698967d9bd03 (patch) | |
tree | d7d0ad7ca01b131b30a4f7b9a01d3181532a4957 /source/blender/editors/sculpt_paint/sculpt.c | |
parent | f9e4d8e93a0c2706c69f2656fa673daa74bdb165 (diff) |
Fix sculpt brush draw crash on Blender2.8
Temporary solution by Sergey Sharybin, it needs further investigation.
This should not be necessary, specially since this works fine in master.
Diffstat (limited to 'source/blender/editors/sculpt_paint/sculpt.c')
-rw-r--r-- | source/blender/editors/sculpt_paint/sculpt.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/source/blender/editors/sculpt_paint/sculpt.c b/source/blender/editors/sculpt_paint/sculpt.c index 84e98181dfb..3cdbe1e5c3c 100644 --- a/source/blender/editors/sculpt_paint/sculpt.c +++ b/source/blender/editors/sculpt_paint/sculpt.c @@ -2044,6 +2044,10 @@ static void do_draw_brush(Sculpt *sd, Object *ob, PBVHNode **nodes, int totnode) mul_v3_v3(offset, ss->cache->scale); mul_v3_fl(offset, bstrength); + /* XXX - this shouldn't be necessary, but sculpting crashes in blender2.8 otherwise + * initialize before threads so they can do curve mapping */ + curvemapping_initialize(brush->curve); + /* threaded loop over nodes */ SculptThreadedTaskData data = { .sd = sd, .ob = ob, .brush = brush, .nodes = nodes, |