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-03-06 22:40:15 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-03-06 22:40:15 +0400
commit31d2ee9bf77bb991ea4779c47379b2cee84b27ed (patch)
treefd6f021356fc78d6dfeff9f18f601ce645dd7ffe /source/blender/blenkernel/intern/shrinkwrap.c
parent7b7214c72233f72268f72d31fd8626a0f94e557e (diff)
style cleanup, brackets in else/if, some indentation.
Diffstat (limited to 'source/blender/blenkernel/intern/shrinkwrap.c')
-rw-r--r--source/blender/blenkernel/intern/shrinkwrap.c18
1 files changed, 6 insertions, 12 deletions
diff --git a/source/blender/blenkernel/intern/shrinkwrap.c b/source/blender/blenkernel/intern/shrinkwrap.c
index a98834c5e35..6800c210963 100644
--- a/source/blender/blenkernel/intern/shrinkwrap.c
+++ b/source/blender/blenkernel/intern/shrinkwrap.c
@@ -236,8 +236,7 @@ int normal_projection_project_vertex(char options, const float *vert, const floa
hit_tmp.dist *= mat4_to_scale( ((SpaceTransform*)transf)->local2target );
}
- else
- {
+ else {
co = vert;
no = dir;
}
@@ -303,8 +302,7 @@ static void shrinkwrap_calc_normal_projection(ShrinkwrapCalcData *calc)
{
if(calc->vert == NULL) return;
}
- else
- {
+ else {
//The code supports any axis that is a combination of X,Y,Z
//although currently UI only allows to set the 3 different axis
if(calc->smd->projAxis & MOD_SHRINKWRAP_PROJECT_OVER_X_AXIS) proj_axis[0] = 1.0f;
@@ -355,8 +353,7 @@ static void shrinkwrap_calc_normal_projection(ShrinkwrapCalcData *calc)
copy_v3_v3(tmp_no, proj_axis);
}
}
- else
- {
+ else {
copy_v3_v3(tmp_co, co);
copy_v3_v3(tmp_no, proj_axis);
}
@@ -439,12 +436,10 @@ static void shrinkwrap_calc_nearest_surface_point(ShrinkwrapCalcData *calc)
if(weight == 0.0f) continue;
//Convert the vertex to tree coordinates
- if(calc->vert)
- {
+ if(calc->vert) {
copy_v3_v3(tmp_co, calc->vert[i].co);
}
- else
- {
+ else {
copy_v3_v3(tmp_co, co);
}
space_transform_apply(&calc->local2target, tmp_co);
@@ -469,8 +464,7 @@ static void shrinkwrap_calc_nearest_surface_point(ShrinkwrapCalcData *calc)
//Make the vertex stay on the front side of the face
madd_v3_v3v3fl(tmp_co, nearest.co, nearest.no, calc->keepDist);
}
- else
- {
+ else {
//Adjusting the vertex weight, so that after interpolating it keeps a certain distance from the nearest position
float dist = sasqrt( nearest.dist );
if(dist > FLT_EPSILON)