From b340f930ec5639f24e7e2d47fab221fb752b61dd Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Sat, 28 Apr 2012 06:31:57 +0000 Subject: style cleanup: changes to brace placement / newlines - for/while/if/switch --- source/blender/modifiers/intern/MOD_collision.c | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) (limited to 'source/blender/modifiers/intern/MOD_collision.c') diff --git a/source/blender/modifiers/intern/MOD_collision.c b/source/blender/modifiers/intern/MOD_collision.c index b3faf6c140a..4c5ce184c22 100644 --- a/source/blender/modifiers/intern/MOD_collision.c +++ b/source/blender/modifiers/intern/MOD_collision.c @@ -71,8 +71,7 @@ static void freeData(ModifierData *md) { CollisionModifierData *collmd = (CollisionModifierData*) md; - if (collmd) - { + if (collmd) { if (collmd->bvhtree) BLI_bvhtree_free(collmd->bvhtree); if (collmd->x) @@ -120,14 +119,12 @@ static void deformVerts(ModifierData *md, Object *ob, if (derivedData) dm = CDDM_copy(derivedData); else if (ob->type==OB_MESH) dm = CDDM_from_mesh(ob->data, ob); - if (!ob->pd) - { + if (!ob->pd) { printf("CollisionModifier deformVerts: Should not happen!\n"); return; } - if (dm) - { + if (dm) { float current_time = 0; unsigned int numverts = 0; @@ -141,20 +138,17 @@ static void deformVerts(ModifierData *md, Object *ob, numverts = dm->getNumVerts ( dm ); - if ((current_time > collmd->time_xnew)|| (BKE_ptcache_get_continue_physics())) - { + if ((current_time > collmd->time_xnew)|| (BKE_ptcache_get_continue_physics())) { unsigned int i; // check if mesh has changed if (collmd->x && (numverts != collmd->numverts)) freeData((ModifierData *)collmd); - if (collmd->time_xnew == -1000) // first time - { + if (collmd->time_xnew == -1000) { /* first time */ collmd->x = dm->dupVertArray(dm); // frame start position - for ( i = 0; i < numverts; i++ ) - { + for ( i = 0; i < numverts; i++ ) { // we save global positions mul_m4_v3( ob->obmat, collmd->x[i].co ); } -- cgit v1.2.3