[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [50333] trunk/blender/source/blender/ editors/mesh/editmesh_knife.c: style cleanup
Campbell Barton
ideasman42 at gmail.com
Mon Sep 3 07:36:48 CEST 2012
Revision: 50333
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=50333
Author: campbellbarton
Date: 2012-09-03 05:36:47 +0000 (Mon, 03 Sep 2012)
Log Message:
-----------
style cleanup
Modified Paths:
--------------
trunk/blender/source/blender/editors/mesh/editmesh_knife.c
Modified: trunk/blender/source/blender/editors/mesh/editmesh_knife.c
===================================================================
--- trunk/blender/source/blender/editors/mesh/editmesh_knife.c 2012-09-03 05:00:42 UTC (rev 50332)
+++ trunk/blender/source/blender/editors/mesh/editmesh_knife.c 2012-09-03 05:36:47 UTC (rev 50333)
@@ -1113,7 +1113,7 @@
KnifeEdge *kfe = ref->ref;
if (BLI_smallhash_haskey(ehash, (intptr_t)kfe)) {
- continue; // We already found a hit on this knife edge
+ continue; /* We already found a hit on this knife edge */
}
if (isect_line_tri_v3(kfe->v1->cageco, kfe->v2->cageco, v1, v2, v3, &lambda, NULL)) {
@@ -1145,10 +1145,11 @@
float p1[3], lambda1;
/* if face isn't planer, p may be behind the current tesselated tri,
- so move it onto that and then a little towards eye */
+ * so move it onto that and then a little towards eye */
if (isect_line_tri_v3(p, view, ls[0]->v->co, ls[1]->v->co, ls[2]->v->co, &lambda1, NULL)) {
interp_v3_v3v3(p1, p, view, lambda1);
- } else {
+ }
+ else {
copy_v3_v3(p1, p);
}
sub_v3_v3(view, p1);
@@ -1170,7 +1171,9 @@
if (len_squared_v3v3(p, kcd->curr.co) < depsilon_squared ||
len_squared_v3v3(p, kcd->prev.co) < depsilon_squared)
+ {
continue;
+ }
hit.kfe = kfe;
hit.v = NULL;
@@ -1190,15 +1193,18 @@
/* select the closest from the edge endpoints or the midpoint */
if (perc < 0.25f) {
perc = 0.0f;
- } else if (perc < 0.75f) {
+ }
+ else if (perc < 0.75f) {
perc = 0.5f;
- } else {
+ }
+ else {
perc = 1.0f;
}
interp_v3_v3v3(hit.hit, kfe->v1->co, kfe->v2->co, perc);
interp_v3_v3v3(hit.cagehit, kfe->v1->cageco, kfe->v2->cageco, perc);
- } else {
+ }
+ else {
copy_v3_v3(hit.hit, p);
}
knife_project_v3(kcd, hit.cagehit, hit.schit);
More information about the Bf-blender-cvs
mailing list