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-04 00:19:11 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-03-04 00:19:11 +0400
commit95670e03a01d30cda5a0f685974f28790be6809d (patch)
treee6d5756cbe51edb083cda2fceff087bda35c361a /source/blender/bmesh
parenta2c182e9233333fc3b8ff40d352113ec95e7e30c (diff)
style cleanup / comment formatting for bli/bke/bmesh
Diffstat (limited to 'source/blender/bmesh')
-rw-r--r--source/blender/bmesh/intern/bmesh_core.c4
-rw-r--r--source/blender/bmesh/intern/bmesh_iterators.h2
-rw-r--r--source/blender/bmesh/intern/bmesh_polygon.c7
-rw-r--r--source/blender/bmesh/intern/bmesh_walkers.h30
-rw-r--r--source/blender/bmesh/operators/bmo_triangulate.c4
-rw-r--r--source/blender/bmesh/operators/bmo_utils.c64
6 files changed, 57 insertions, 54 deletions
diff --git a/source/blender/bmesh/intern/bmesh_core.c b/source/blender/bmesh/intern/bmesh_core.c
index eeffdc86a16..dd5edcae583 100644
--- a/source/blender/bmesh/intern/bmesh_core.c
+++ b/source/blender/bmesh/intern/bmesh_core.c
@@ -377,8 +377,8 @@ int bmesh_elem_check(BMesh *UNUSED(bm), void *element, const char htype)
if (l->f->len <= 0)
err |= (1 << 13);
- /* validate boundary loop--invalid for hole loops, of course,
- * but we won't be allowing those for a while ye */
+ /* validate boundary loop -- invalid for hole loops, of course,
+ * but we won't be allowing those for a while yet */
l2 = l;
i = 0;
do {
diff --git a/source/blender/bmesh/intern/bmesh_iterators.h b/source/blender/bmesh/intern/bmesh_iterators.h
index 24653fc0b73..7b13d2de723 100644
--- a/source/blender/bmesh/intern/bmesh_iterators.h
+++ b/source/blender/bmesh/intern/bmesh_iterators.h
@@ -37,7 +37,7 @@
* the iterators provided in this file instead
* of inspecting the structure directly.
*
-*/
+ */
#include "BLI_mempool.h"
diff --git a/source/blender/bmesh/intern/bmesh_polygon.c b/source/blender/bmesh/intern/bmesh_polygon.c
index 15a5a7d71b0..67bdec16a05 100644
--- a/source/blender/bmesh/intern/bmesh_polygon.c
+++ b/source/blender/bmesh/intern/bmesh_polygon.c
@@ -825,14 +825,17 @@ void BM_face_triangulate(BMesh *bm, BMFace *f, float (*projectverts)[3],
if (newfaces) newfaces[nf_i++] = f;
- /* l = f->loopbase;
+#if 0
+ l = f->loopbase;
do {
if (l->v == v) {
f->loopbase = l;
break;
}
l = l->next;
- } while (l != f->loopbase); */
+ } while (l != f->loopbase);
+#endif
+
}
}
diff --git a/source/blender/bmesh/intern/bmesh_walkers.h b/source/blender/bmesh/intern/bmesh_walkers.h
index 4c8830e61e3..9ea9e332c5f 100644
--- a/source/blender/bmesh/intern/bmesh_walkers.h
+++ b/source/blender/bmesh/intern/bmesh_walkers.h
@@ -30,8 +30,8 @@
#include "BLI_ghash.h"
/*
- NOTE: do NOT modify topology while walking a mesh!
-*/
+ * NOTE: do NOT modify topology while walking a mesh!
+ */
typedef enum {
BMW_DEPTH_FIRST,
@@ -85,19 +85,19 @@ void *BMW_walk(BMWalker *walker);
void BMW_reset(BMWalker *walker);
/*
-example of usage, walking over an island of tool flagged faces:
-
-BMWalker walker;
-BMFace *f;
-
-BMW_init(&walker, bm, BMW_ISLAND, SOME_OP_FLAG);
-f = BMW_begin(&walker, some_start_face);
-for (; f; f = BMW_step(&walker))
-{
- //do something with f
-}
-BMW_end(&walker);
-*/
+ * example of usage, walking over an island of tool flagged faces:
+ *
+ * BMWalker walker;
+ * BMFace *f;
+ *
+ * BMW_init(&walker, bm, BMW_ISLAND, SOME_OP_FLAG);
+ * f = BMW_begin(&walker, some_start_face);
+ * for (; f; f = BMW_step(&walker))
+ * {
+ * //do something with f
+ * }
+ * BMW_end(&walker);
+ */
enum {
/* walk over connected geometry. can restrict to a search flag,
diff --git a/source/blender/bmesh/operators/bmo_triangulate.c b/source/blender/bmesh/operators/bmo_triangulate.c
index 42251959c8f..527ffd9a080 100644
--- a/source/blender/bmesh/operators/bmo_triangulate.c
+++ b/source/blender/bmesh/operators/bmo_triangulate.c
@@ -118,8 +118,8 @@ void bmo_beautify_fill_exec(BMesh *bm, BMOperator *op)
if (is_quad_convex_v3(v1->co, v2->co, v3->co, v4->co)) {
float len1, len2, len3, len4, len5, len6, opp1, opp2, fac1, fac2;
/* testing rule:
- * the area divided by the total edge lengths
- */
+ * the area divided by the total edge lengths
+ */
len1 = len_v3v3(v1->co, v2->co);
len2 = len_v3v3(v2->co, v3->co);
len3 = len_v3v3(v3->co, v4->co);
diff --git a/source/blender/bmesh/operators/bmo_utils.c b/source/blender/bmesh/operators/bmo_utils.c
index 0486c21b847..8e75d7880ee 100644
--- a/source/blender/bmesh/operators/bmo_utils.c
+++ b/source/blender/bmesh/operators/bmo_utils.c
@@ -551,12 +551,12 @@ void bmo_similarfaces_exec(BMesh *bm, BMOperator *op)
num_total = BM_mesh_elem_count(bm, BM_FACE);
/*
- ** The first thing to do is to iterate through all the the selected items and mark them since
- ** they will be in the selection anyway.
- ** This will increase performance, (especially when the number of originaly selected faces is high)
- ** so the overall complexity will be less than $O(mn)$ where is the total number of selected faces,
- ** and n is the total number of faces
- */
+ * The first thing to do is to iterate through all the the selected items and mark them since
+ * they will be in the selection anyway.
+ * This will increase performance, (especially when the number of originaly selected faces is high)
+ * so the overall complexity will be less than $O(mn)$ where is the total number of selected faces,
+ * and n is the total number of faces
+ */
BMO_ITER(fs, &fs_iter, bm, op, "faces", BM_FACE) {
if (!BMO_elem_flag_test(bm, fs, FACE_MARK)) { /* is this really needed ? */
BMO_elem_flag_enable(bm, fs, FACE_MARK);
@@ -579,9 +579,9 @@ void bmo_similarfaces_exec(BMesh *bm, BMOperator *op)
}
/*
- ** Save us some computation burden: In case of perimeter/area/coplanar selection we compute
- ** only once.
- */
+ * Save us some computation burden: In case of perimeter/area/coplanar selection we compute
+ * only once.
+ */
if (type == SIMFACE_PERIMETER || type == SIMFACE_AREA || type == SIMFACE_COPLANAR || type == SIMFACE_IMAGE) {
for (i = 0; i < num_total; i++) {
switch (type) {
@@ -682,9 +682,9 @@ void bmo_similarfaces_exec(BMesh *bm, BMOperator *op)
BMO_slot_buffer_from_flag(bm, op, "faceout", FACE_MARK, BM_FACE);
}
-/******************************************************************************
-** Similar Edges
-**************************************************************************** */
+/**************************************************************************** *
+ * Similar Edges
+ **************************************************************************** */
#define EDGE_MARK 1
/*
@@ -879,9 +879,9 @@ void bmo_similaredges_exec(BMesh *bm, BMOperator *op)
BMO_slot_buffer_from_flag(bm, op, "edgeout", EDGE_MARK, BM_EDGE);
}
-/******************************************************************************
-** Similar Vertices
-**************************************************************************** */
+/**************************************************************************** *
+ * Similar Vertices
+ **************************************************************************** */
#define VERT_MARK 1
typedef struct SimSel_VertExt {
@@ -995,9 +995,9 @@ void bmo_similarverts_exec(BMesh *bm, BMOperator *op)
BMO_slot_buffer_from_flag(bm, op, "vertout", VERT_MARK, BM_VERT);
}
-/******************************************************************************
-** Cycle UVs for a face
-**************************************************************************** */
+/**************************************************************************** *
+ * Cycle UVs for a face
+ **************************************************************************** */
void bmo_face_rotateuvs_exec(BMesh *bm, BMOperator *op)
{
@@ -1062,9 +1062,9 @@ void bmo_face_rotateuvs_exec(BMesh *bm, BMOperator *op)
}
-/******************************************************************************
-** Reverse UVs for a face
-**************************************************************************** */
+/**************************************************************************** *
+ * Reverse UVs for a face
+ **************************************************************************** */
void bmo_face_reverseuvs_exec(BMesh *bm, BMOperator *op)
{
@@ -1105,9 +1105,9 @@ void bmo_face_reverseuvs_exec(BMesh *bm, BMOperator *op)
BLI_array_free(uvs);
}
-/******************************************************************************
-** Cycle colors for a face
-**************************************************************************** */
+/**************************************************************************** *
+ * Cycle colors for a face
+ **************************************************************************** */
void bmo_rotatecolors_exec(BMesh *bm, BMOperator *op)
{
@@ -1171,9 +1171,9 @@ void bmo_rotatecolors_exec(BMesh *bm, BMOperator *op)
}
}
-/******************************************************************************
-** Reverse colors for a face
-**************************************************************************** */
+/*************************************************************************** *
+ * Reverse colors for a face
+ *************************************************************************** */
void bmo_face_reversecolors_exec(BMesh *bm, BMOperator *op)
{
@@ -1213,9 +1213,9 @@ void bmo_face_reversecolors_exec(BMesh *bm, BMOperator *op)
}
-/******************************************************************************
-** shortest vertex path select
-**************************************************************************** */
+/*************************************************************************** *
+ * shortest vertex path select
+ *************************************************************************** */
typedef struct ElemNode {
BMVert *v; /* vertex */
@@ -1262,8 +1262,8 @@ void bmo_vertexshortestpath_exec(BMesh *bm, BMOperator *op)
bm->elem_index_dirty &= ~BM_VERT;
/*
- ** we now have everything we need, start Dijkstra path finding algorithm
- */
+ * we now have everything we need, start Dijkstra path finding algorithm
+ */
/* set the distance/weight of the start vertex to 0 */
vert_list[BM_elem_index_get(sv)].weight = 0.0f;