diff options
author | Campbell Barton <ideasman42@gmail.com> | 2019-03-15 00:53:22 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2019-03-15 01:54:30 +0300 |
commit | 35b78d9807c49ba37e038eda85c672c72dee0247 (patch) | |
tree | a081042c85b98d0ac9116c0c4ba99ded6ae5de84 /source/blender/blenkernel/intern | |
parent | 395a0acdb88338b9790ecefd142f4010df6b955d (diff) |
Cleanup: indentation, wrapping
Mostly functions wrapping args, not confirming to our style guide.
Diffstat (limited to 'source/blender/blenkernel/intern')
-rw-r--r-- | source/blender/blenkernel/intern/customdata.c | 4 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/dynamicpaint.c | 9 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/library_query.c | 6 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/softbody.c | 15 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/subdiv_converter_mesh.c | 4 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/tracking_auto.c | 2 |
6 files changed, 21 insertions, 19 deletions
diff --git a/source/blender/blenkernel/intern/customdata.c b/source/blender/blenkernel/intern/customdata.c index 56847aded8b..cdb905f9e35 100644 --- a/source/blender/blenkernel/intern/customdata.c +++ b/source/blender/blenkernel/intern/customdata.c @@ -2319,8 +2319,8 @@ static void CustomData_copy_data_layer( if (!count || !src_data || !dst_data) { if (count && !(src_data == NULL && dst_data == NULL)) { CLOG_WARN(&LOG, "null data for %s type (%p --> %p), skipping", - layerType_getName(source->layers[src_i].type), - (void *)src_data, (void *)dst_data); + layerType_getName(source->layers[src_i].type), + (void *)src_data, (void *)dst_data); } return; } diff --git a/source/blender/blenkernel/intern/dynamicpaint.c b/source/blender/blenkernel/intern/dynamicpaint.c index daadc2e1fad..eeaf0710a5f 100644 --- a/source/blender/blenkernel/intern/dynamicpaint.c +++ b/source/blender/blenkernel/intern/dynamicpaint.c @@ -2402,13 +2402,14 @@ static float dist_squared_to_looptri_uv_edges(const MLoopTri *mlooptri, const ML for (int i = 0; i < 3; i++) { const float dist_squared = dist_squared_to_line_segment_v2( - point, - mloopuv[mlooptri[tri_index].tri[(i + 0)]].uv, - mloopuv[mlooptri[tri_index].tri[(i + 1) % 3]].uv + point, + mloopuv[mlooptri[tri_index].tri[(i + 0)]].uv, + mloopuv[mlooptri[tri_index].tri[(i + 1) % 3]].uv ); - if (dist_squared < min_distance) + if (dist_squared < min_distance) { min_distance = dist_squared; + } } return min_distance; diff --git a/source/blender/blenkernel/intern/library_query.c b/source/blender/blenkernel/intern/library_query.c index 267699b67c1..72e9d747206 100644 --- a/source/blender/blenkernel/intern/library_query.c +++ b/source/blender/blenkernel/intern/library_query.c @@ -1204,9 +1204,9 @@ static int foreach_libblock_id_users_callback(void *user_data, ID *UNUSED(self_i if (*id_p == iter->id) { #if 0 printf("%s uses %s (refcounted: %d, userone: %d, used_one: %d, used_one_active: %d, indirect_usage: %d)\n", - iter->curr_id->name, iter->id->name, (cb_flag & IDWALK_USER) ? 1 : 0, (cb_flag & IDWALK_USER_ONE) ? 1 : 0, - (iter->id->tag & LIB_TAG_EXTRAUSER) ? 1 : 0, (iter->id->tag & LIB_TAG_EXTRAUSER_SET) ? 1 : 0, - (cb_flag & IDWALK_INDIRECT_USAGE) ? 1 : 0); + iter->curr_id->name, iter->id->name, (cb_flag & IDWALK_USER) ? 1 : 0, (cb_flag & IDWALK_USER_ONE) ? 1 : 0, + (iter->id->tag & LIB_TAG_EXTRAUSER) ? 1 : 0, (iter->id->tag & LIB_TAG_EXTRAUSER_SET) ? 1 : 0, + (cb_flag & IDWALK_INDIRECT_USAGE) ? 1 : 0); #endif if (cb_flag & IDWALK_CB_INDIRECT_USAGE) { iter->count_indirect++; diff --git a/source/blender/blenkernel/intern/softbody.c b/source/blender/blenkernel/intern/softbody.c index 481eb617cc0..d4a0ad71e1e 100644 --- a/source/blender/blenkernel/intern/softbody.c +++ b/source/blender/blenkernel/intern/softbody.c @@ -1443,13 +1443,14 @@ static void _scan_for_ext_spring_forces(Scene *scene, Object *ob, float timenow, if (bs->springtype == SB_EDGE) { /* +++ springs colliding */ if (ob->softflag & OB_SB_EDGECOLL) { - if ( sb_detect_edge_collisionCached (sb->bpoint[bs->v1].pos, sb->bpoint[bs->v2].pos, - &damp, feedback, ob, timenow)) { - add_v3_v3(bs->ext_force, feedback); - bs->flag |= BSF_INTERSECT; - //bs->cf=damp; - bs->cf=sb->choke*0.01f; - + if (sb_detect_edge_collisionCached( + sb->bpoint[bs->v1].pos, sb->bpoint[bs->v2].pos, + &damp, feedback, ob, timenow)) + { + add_v3_v3(bs->ext_force, feedback); + bs->flag |= BSF_INTERSECT; + //bs->cf=damp; + bs->cf=sb->choke*0.01f; } } /* ---- springs colliding */ diff --git a/source/blender/blenkernel/intern/subdiv_converter_mesh.c b/source/blender/blenkernel/intern/subdiv_converter_mesh.c index 8aac77c0bd8..00a2436098e 100644 --- a/source/blender/blenkernel/intern/subdiv_converter_mesh.c +++ b/source/blender/blenkernel/intern/subdiv_converter_mesh.c @@ -324,12 +324,12 @@ static void initialize_manifold_index_array(const BLI_bitmap *used_map, int *indices = NULL; if (indices_r != NULL) { indices = MEM_malloc_arrayN( - num_elements, sizeof(int), "manifold indices"); + num_elements, sizeof(int), "manifold indices"); } int *indices_reverse = NULL; if (indices_reverse_r != NULL) { indices_reverse = MEM_malloc_arrayN( - num_elements, sizeof(int), "manifold indices reverse"); + num_elements, sizeof(int), "manifold indices reverse"); } int offset = 0; for (int i = 0; i < num_elements; i++) { diff --git a/source/blender/blenkernel/intern/tracking_auto.c b/source/blender/blenkernel/intern/tracking_auto.c index 38124ddf97c..bddb5315781 100644 --- a/source/blender/blenkernel/intern/tracking_auto.c +++ b/source/blender/blenkernel/intern/tracking_auto.c @@ -538,7 +538,7 @@ void BKE_autotrack_context_sync(AutoTrackContext *context) for (track = 0; track < context->num_tracks; ++track) { AutoTrackOptions *options = &context->options[track]; int track_frame = BKE_movieclip_remap_scene_to_clip_frame( - context->clips[options->clip_index], frame); + context->clips[options->clip_index], frame); if (options->is_failed) { if (options->failed_frame == track_frame) { MovieTrackingMarker *prev_marker = |