Partially revert changes from 2a184f3d2b

Ended up removing the need for eval_ctx,
but left it being initialized.
This commit is contained in:
Campbell Barton
2018-02-06 19:17:28 +11:00
parent 74f7fb084c
commit f9da89a38d
2 changed files with 3 additions and 13 deletions

View File

@@ -1472,11 +1472,8 @@ static void precompute_weight_values(
return;
/* threaded loop over vertices */
EvaluationContext eval_ctx;
CTX_data_eval_ctx(C, &eval_ctx);
SculptThreadedTaskData data = {
.C = C, .eval_ctx = &eval_ctx, .ob = ob, .wpd = wpd, .wpi = wpi, .me = me,
.C = C, .ob = ob, .wpd = wpd, .wpi = wpi, .me = me,
};
ParallelRangeSettings settings;
@@ -1848,11 +1845,8 @@ static void wpaint_paint_leaves(
const Brush *brush = ob->sculpt->cache->brush;
/* threaded loop over nodes */
EvaluationContext eval_ctx;
CTX_data_eval_ctx(C, &eval_ctx);
SculptThreadedTaskData data = {
.C = C, .eval_ctx = &eval_ctx, .sd = sd, .ob = ob, .brush = brush, .nodes = nodes,
.C = C, .sd = sd, .ob = ob, .brush = brush, .nodes = nodes,
.vp = vp, .wpd = wpd, .wpi = wpi, .me = me,
};
@@ -2891,11 +2885,8 @@ static void vpaint_paint_leaves(
{
const Brush *brush = ob->sculpt->cache->brush;
EvaluationContext eval_ctx;
CTX_data_eval_ctx(C, &eval_ctx);
SculptThreadedTaskData data = {
.C = C, .eval_ctx = &eval_ctx, .sd = sd, .ob = ob, .brush = brush, .nodes = nodes, .vp = vp, .vpd = vpd,
.C = C, .sd = sd, .ob = ob, .brush = brush, .nodes = nodes, .vp = vp, .vpd = vpd,
.lcol = (uint *)me->mloopcol, .me = me,
};
ParallelRangeSettings settings;

View File

@@ -130,7 +130,6 @@ struct SculptRakeData {
/* Single struct used by all BLI_task threaded callbacks, let's avoid adding 10's of those... */
typedef struct SculptThreadedTaskData {
struct bContext *C;
const struct EvaluationContext *eval_ctx;
struct Sculpt *sd;
struct Object *ob;
const struct Brush *brush;