diff options
author | Campbell Barton <ideasman42@gmail.com> | 2013-04-04 08:22:38 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2013-04-04 08:22:38 +0400 |
commit | 2804caff4ce6c9f6d5ebdd101e77c92b7ac65db4 (patch) | |
tree | b3f91af65a3d29c253cae82117bfb4477b834f69 /source/blender/blenkernel/intern/mball.c | |
parent | 966e86cd2dbe2c627e65766d0361cc79f63d7cc7 (diff) |
code cleanup: use bools, (float)sin/(float)cos -> sinf/cosf, more meaningful var names.
Diffstat (limited to 'source/blender/blenkernel/intern/mball.c')
-rw-r--r-- | source/blender/blenkernel/intern/mball.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/source/blender/blenkernel/intern/mball.c b/source/blender/blenkernel/intern/mball.c index 72284130869..b93d924ddf9 100644 --- a/source/blender/blenkernel/intern/mball.c +++ b/source/blender/blenkernel/intern/mball.c @@ -1426,7 +1426,8 @@ static void converge(const float p1[3], const float p2[3], float v1, float v2, while (1) { if (i++ == RES) return; p[0] = 0.5f * (pos[0] + neg[0]); - if ((function(p[0], p[1], p[2])) > 0.0f) pos[0] = p[0]; else neg[0] = p[0]; + if ((function(p[0], p[1], p[2])) > 0.0f) pos[0] = p[0]; + else neg[0] = p[0]; } } @@ -1436,7 +1437,8 @@ static void converge(const float p1[3], const float p2[3], float v1, float v2, while (1) { if (i++ == RES) return; p[1] = 0.5f * (pos[1] + neg[1]); - if ((function(p[0], p[1], p[2])) > 0.0f) pos[1] = p[1]; else neg[1] = p[1]; + if ((function(p[0], p[1], p[2])) > 0.0f) pos[1] = p[1]; + else neg[1] = p[1]; } } @@ -1446,7 +1448,8 @@ static void converge(const float p1[3], const float p2[3], float v1, float v2, while (1) { if (i++ == RES) return; p[2] = 0.5f * (pos[2] + neg[2]); - if ((function(p[0], p[1], p[2])) > 0.0f) pos[2] = p[2]; else neg[2] = p[2]; + if ((function(p[0], p[1], p[2])) > 0.0f) pos[2] = p[2]; + else neg[2] = p[2]; } } |