diff options
author | Campbell Barton <ideasman42@gmail.com> | 2019-08-06 20:21:55 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2019-08-06 20:38:01 +0300 |
commit | 00cb31de6577f79adb26c08a3fdef7186e17e237 (patch) | |
tree | 29f44f5c8bc85215ea85f69df9e2866487f66ccc /source/blender/blenkernel/intern/particle_child.c | |
parent | e2630f388d6f8c1eb8663300cf81244600c9ad39 (diff) |
Cleanup: use BKE_ prefix for BKE_colortools.h
Diffstat (limited to 'source/blender/blenkernel/intern/particle_child.c')
-rw-r--r-- | source/blender/blenkernel/intern/particle_child.c | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/source/blender/blenkernel/intern/particle_child.c b/source/blender/blenkernel/intern/particle_child.c index b74fd3ff684..3b02e010e7f 100644 --- a/source/blender/blenkernel/intern/particle_child.c +++ b/source/blender/blenkernel/intern/particle_child.c @@ -597,7 +597,8 @@ static float do_clump_level(float result[3], float clump = 0.0f; if (clumpcurve) { - clump = pa_clump * (1.0f - clamp_f(curvemapping_evaluateF(clumpcurve, 0, time), 0.0f, 1.0f)); + clump = pa_clump * + (1.0f - clamp_f(BKE_curvemapping_evaluateF(clumpcurve, 0, time), 0.0f, 1.0f)); interp_v3_v3v3(result, co, par_co, clump); } @@ -714,7 +715,7 @@ static void do_rough_curve(const float loc[3], return; } - fac *= clamp_f(curvemapping_evaluateF(roughcurve, 0, time), 0.0f, 1.0f); + fac *= clamp_f(BKE_curvemapping_evaluateF(roughcurve, 0, time), 0.0f, 1.0f); copy_v3_v3(rco, loc); mul_v3_fl(rco, time); @@ -749,15 +750,15 @@ static void twist_get_axis(const ParticleChildModifierContext *modifier_ctx, } } -static float curvemapping_integrate_clamped(CurveMapping *curve, - float start, - float end, - float step) +static float BKE_curvemapping_integrate_clamped(CurveMapping *curve, + float start, + float end, + float step) { float integral = 0.0f; float x = start; while (x < end) { - float y = curvemapping_evaluateF(curve, 0, x); + float y = BKE_curvemapping_evaluateF(curve, 0, x); y = clamp_f(y, 0.0f, 1.0f); /* TODO(sergey): Clamp last step to end. */ integral += y * step; @@ -804,7 +805,7 @@ static void do_twist(const ParticleChildModifierContext *modifier_ctx, } if (twist_curve != NULL) { const int num_segments = twist_num_segments(modifier_ctx); - angle *= curvemapping_integrate_clamped(twist_curve, 0.0f, time, 1.0f / num_segments); + angle *= BKE_curvemapping_integrate_clamped(twist_curve, 0.0f, time, 1.0f / num_segments); } else { angle *= time; |