[Bf-blender-cvs] [d2d8871] temp_custom_loop_normals: cleanup: style

Campbell Barton noreply at git.blender.org
Mon Feb 2 14:19:52 CET 2015


Commit: d2d887166d084d1172324460fdae64292730e1e4
Author: Campbell Barton
Date:   Tue Feb 3 00:19:00 2015 +1100
Branches: temp_custom_loop_normals
https://developer.blender.org/rBd2d887166d084d1172324460fdae64292730e1e4

cleanup: style

===================================================================

M	source/blender/blenkernel/intern/cdderivedmesh.c
M	source/blender/blenkernel/intern/data_transfer.c
M	source/blender/blenkernel/intern/editderivedmesh.c
M	source/blender/blenkernel/intern/mesh_evaluate.c
M	source/blender/modifiers/intern/MOD_setsplitnormal.c

===================================================================

diff --git a/source/blender/blenkernel/intern/cdderivedmesh.c b/source/blender/blenkernel/intern/cdderivedmesh.c
index 0bc7b47..f889f4f 100644
--- a/source/blender/blenkernel/intern/cdderivedmesh.c
+++ b/source/blender/blenkernel/intern/cdderivedmesh.c
@@ -2222,7 +2222,7 @@ void CDDM_calc_loop_normals_spaceset(
 				printf("\talpha: %f\n\tbeta: %f\n\tloops: %p\n", r_lnors_spaceset->lspaceset[i]->ref_alpha,
 				       r_lnors_spaceset->lspaceset[i]->ref_beta, r_lnors_spaceset->lspaceset[i]->loops);
 				printf("\t\t(shared with loops");
-				while(loops) {
+				while (loops) {
 					printf(" %d", GET_INT_FROM_POINTER(loops->link));
 					loops = loops->next;
 				}
diff --git a/source/blender/blenkernel/intern/data_transfer.c b/source/blender/blenkernel/intern/data_transfer.c
index bf4610f..5ac7b92 100644
--- a/source/blender/blenkernel/intern/data_transfer.c
+++ b/source/blender/blenkernel/intern/data_transfer.c
@@ -292,7 +292,7 @@ static void data_transfer_dtdata_type_preprocess(
 					CustomData_set_layer_flag(pdata_dst, CD_NORMAL, CD_FLAG_TEMPORARY);
 				}
 				BKE_mesh_calc_normals_poly(verts_dst, num_verts_dst, loops_dst, polys_dst,
-										   num_loops_dst, num_polys_dst, poly_nors_dst, true);
+				                           num_loops_dst, num_polys_dst, poly_nors_dst, true);
 			}
 			/* Cache loop nors into a temp CDLayer. */
 			loop_nors_dst = CustomData_get_layer(ldata_dst, CD_NORMAL);
@@ -302,9 +302,9 @@ static void data_transfer_dtdata_type_preprocess(
 					CustomData_set_layer_flag(ldata_dst, CD_NORMAL, CD_FLAG_TEMPORARY);
 				}
 				BKE_mesh_normals_loop_split(verts_dst, num_verts_dst, edges_dst, num_edges_dst,
-											loops_dst, loop_nors_dst, num_loops_dst,
-											polys_dst, (const float (*)[3])poly_nors_dst, num_polys_dst,
-											use_split_nors_dst, split_angle_dst, NULL, custom_nors_dst, NULL);
+				                            loops_dst, loop_nors_dst, num_loops_dst,
+				                            polys_dst, (const float (*)[3])poly_nors_dst, num_polys_dst,
+				                            use_split_nors_dst, split_angle_dst, NULL, custom_nors_dst, NULL);
 			}
 		}
 	}
diff --git a/source/blender/blenkernel/intern/editderivedmesh.c b/source/blender/blenkernel/intern/editderivedmesh.c
index 2258046..c44cf61 100644
--- a/source/blender/blenkernel/intern/editderivedmesh.c
+++ b/source/blender/blenkernel/intern/editderivedmesh.c
@@ -223,7 +223,7 @@ static void emDM_calcLoopNormalsSpaceset(
 				printf("\talpha: %f\n\tbeta: %f\n\tloops: %p\n", r_lnors_spaceset->lspaceset[i]->ref_alpha,
 				       r_lnors_spaceset->lspaceset[i]->ref_beta, r_lnors_spaceset->lspaceset[i]->loops);
 				printf("\t\t(shared with loops");
-				while(loops) {
+				while (loops) {
 					printf(" %d", GET_INT_FROM_POINTER(loops->link));
 					loops = loops->next;
 				}
diff --git a/source/blender/blenkernel/intern/mesh_evaluate.c b/source/blender/blenkernel/intern/mesh_evaluate.c
index b36ee70..6b042a8 100644
--- a/source/blender/blenkernel/intern/mesh_evaluate.c
+++ b/source/blender/blenkernel/intern/mesh_evaluate.c
@@ -812,7 +812,7 @@ static void split_loop_nor_fan_do(LoopSplitTaskDataCommon *common_data, LoopSpli
 		mlfan_next = &mloops[mlfan_curr_index];
 		mpfan_next = &mpolys[mpfan_curr_index];
 		if ((mlfan_curr->v == mlfan_next->v && mlfan_curr->v == mv_pivot_index) ||
-			(mlfan_curr->v != mlfan_next->v && mlfan_curr->v != mv_pivot_index))
+		    (mlfan_curr->v != mlfan_next->v && mlfan_curr->v != mv_pivot_index))
 		{
 			/* We need the previous loop, but current one is our vertex's loop. */
 			mlfan_vert_index = mlfan_curr_index;
@@ -1325,8 +1325,7 @@ static void mesh_normals_loop_custom_set(
 					if (!org_nor) {
 						org_nor = nor;
 					}
-					else if (dot_v3v3(org_nor, nor) < LNOR_SPACE_TRIGO_THRESHOLD)
-					{
+					else if (dot_v3v3(org_nor, nor) < LNOR_SPACE_TRIGO_THRESHOLD) {
 						/* Current normal differs too much from org one, we have to tag the edge between
 						 * previous loop's face and current's one as sharp.
 						 * We know those two loops do not point to the same edge, since we do not allow reversed winding
diff --git a/source/blender/modifiers/intern/MOD_setsplitnormal.c b/source/blender/modifiers/intern/MOD_setsplitnormal.c
index 4f24861..2be93b7 100644
--- a/source/blender/modifiers/intern/MOD_setsplitnormal.c
+++ b/source/blender/modifiers/intern/MOD_setsplitnormal.c
@@ -21,7 +21,7 @@
  *
  */
 
-/** \file blender/modifiers/intern/MOD_setsplitnor.c
+/** \file blender/modifiers/intern/MOD_setsplitnormal.c
  *  \ingroup modifiers
  */
 
@@ -455,7 +455,8 @@ static CustomDataMask requiredDataMask(Object *UNUSED(ob), ModifierData *md)
 	return dataMask;
 }
 
-static bool dependsOnNormals(ModifierData *UNUSED(md)) {
+static bool dependsOnNormals(ModifierData *UNUSED(md))
+{
 	return true;
 }




More information about the Bf-blender-cvs mailing list