diff options
author | Campbell Barton <ideasman42@gmail.com> | 2012-05-23 01:16:59 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2012-05-23 01:16:59 +0400 |
commit | d2a37d464a81959eb3409115f320c83af4398934 (patch) | |
tree | 20fea786bd6d1fc8113c3ea7c2c5dab437ff52ff /source/blender/blenkernel/intern | |
parent | 1a81499d413e748a26b5f51c5488f257b404e48e (diff) |
code cleanup: double promotion warnings
Diffstat (limited to 'source/blender/blenkernel/intern')
-rw-r--r-- | source/blender/blenkernel/intern/brush.c | 2 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/constraint.c | 2 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/pointcache.c | 6 |
3 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/blenkernel/intern/brush.c b/source/blender/blenkernel/intern/brush.c index f019287144d..741d4b729ae 100644 --- a/source/blender/blenkernel/intern/brush.c +++ b/source/blender/blenkernel/intern/brush.c @@ -1329,7 +1329,7 @@ struct ImBuf *BKE_brush_gen_radial_control_imbuf(Brush *br) for (i = 0; i < side; ++i) { for (j = 0; j < side; ++j) { - float magn = sqrt(pow(i - half, 2) + pow(j - half, 2)); + float magn = sqrtf(powf(i - half, 2) + powf(j - half, 2)); im->rect_float[i * side + j] = BKE_brush_curve_strength_clamp(br, magn, half); } } diff --git a/source/blender/blenkernel/intern/constraint.c b/source/blender/blenkernel/intern/constraint.c index a1f87762db7..da9350cc7b9 100644 --- a/source/blender/blenkernel/intern/constraint.c +++ b/source/blender/blenkernel/intern/constraint.c @@ -3155,7 +3155,7 @@ static void clampto_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *tar /* find bounding-box range where target is located */ if (ownLoc[clamp_axis] < curveMin[clamp_axis]) { /* bounding-box range is before */ - offset = curveMin[clamp_axis] - ceil((curveMin[clamp_axis] - ownLoc[clamp_axis]) / len) * len; + offset = curveMin[clamp_axis] - ceilf((curveMin[clamp_axis] - ownLoc[clamp_axis]) / len) * len; /* now, we calculate as per normal, except using offset instead of curveMin[clamp_axis] */ curvetime = (ownLoc[clamp_axis] - offset) / (len); diff --git a/source/blender/blenkernel/intern/pointcache.c b/source/blender/blenkernel/intern/pointcache.c index f483fd7dc8a..f676cfb2fb8 100644 --- a/source/blender/blenkernel/intern/pointcache.c +++ b/source/blender/blenkernel/intern/pointcache.c @@ -3292,9 +3292,9 @@ void BKE_ptcache_update_info(PTCacheID *pid) mb = (bytes > 1024.0f * 1024.0f); BLI_snprintf(mem_info, sizeof(mem_info), "%i frames in memory (%.1f %s)", - totframes, - bytes / (mb ? 1024.0f * 1024.0f : 1024.0f), - mb ? "Mb" : "kb"); + totframes, + bytes / (mb ? 1024.0f * 1024.0f : 1024.0f), + mb ? "Mb" : "kb"); } if (cache->flag & PTCACHE_OUTDATED) { |