Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2012-04-21 19:11:03 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-04-21 19:11:03 +0400
commitb56aabf815dd60827da81574501ea1d12ce3a38b (patch)
treec8e49d9265437377584cb28705a2dc466a7faa1e /source/blender/blenlib
parent8765dfccf725770007e3b4e6b24199fe8377df71 (diff)
style cleanup: multi-line if statements.
Diffstat (limited to 'source/blender/blenlib')
-rw-r--r--source/blender/blenlib/intern/BLI_kdopbvh.c10
-rw-r--r--source/blender/blenlib/intern/rand.c2
2 files changed, 7 insertions, 5 deletions
diff --git a/source/blender/blenlib/intern/BLI_kdopbvh.c b/source/blender/blenlib/intern/BLI_kdopbvh.c
index d43f8ae735b..2cc67b3f0aa 100644
--- a/source/blender/blenlib/intern/BLI_kdopbvh.c
+++ b/source/blender/blenlib/intern/BLI_kdopbvh.c
@@ -1328,8 +1328,8 @@ static void bfs_find_nearest(BVHNearestData *data, BVHNode *node)
else
{
//adjust heap size
- if (heap_size >= max_heap_size
- && ADJUST_MEMORY(default_heap, (void**)&heap, heap_size+1, &max_heap_size, sizeof(heap[0])) == FALSE)
+ if ((heap_size >= max_heap_size) &&
+ ADJUST_MEMORY(default_heap, (void**)&heap, heap_size+1, &max_heap_size, sizeof(heap[0])) == FALSE)
{
printf("WARNING: bvh_find_nearest got out of memory\n");
@@ -1429,9 +1429,11 @@ static float ray_nearest_hit(BVHRayCastData *data, float *bv)
if (data->ray_dot_axis[i] == 0.0f)
{
//axis aligned ray
- if (data->ray.origin[i] < bv[0] - data->ray.radius
- || data->ray.origin[i] > bv[1] + data->ray.radius)
+ if (data->ray.origin[i] < bv[0] - data->ray.radius ||
+ data->ray.origin[i] > bv[1] + data->ray.radius)
+ {
return FLT_MAX;
+ }
}
else
{
diff --git a/source/blender/blenlib/intern/rand.c b/source/blender/blenlib/intern/rand.c
index 2e722c2a135..b2e6cabec57 100644
--- a/source/blender/blenlib/intern/rand.c
+++ b/source/blender/blenlib/intern/rand.c
@@ -119,7 +119,7 @@ void rng_shuffleArray(RNG *rng, void *data, int elemSize, int numElems)
temp = malloc(elemSize);
- /* XXX Shouldn’t it rather be "while (i--) {" ?
+ /* XXX Shouldn't it rather be "while (i--) {" ?
* Else we have no guaranty first (0) element has a chance to be shuffled... --mont29 */
while (--i) {
int j = rng_getInt(rng)%numElems;