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>2013-12-19 15:40:25 +0400
committerCampbell Barton <ideasman42@gmail.com>2013-12-19 15:41:18 +0400
commit70ef1f20043425d0b721cbb03eebaa26ec013af9 (patch)
tree238e040030aeec3ccad086b72816b1412e939eee /source/blender/bmesh/bmesh_class.h
parent0cb3f54fda56b5a0f17e03de4aec43f77b50b612 (diff)
Patch T19235: bmesh comments (with updates)
Diffstat (limited to 'source/blender/bmesh/bmesh_class.h')
-rw-r--r--source/blender/bmesh/bmesh_class.h24
1 files changed, 17 insertions, 7 deletions
diff --git a/source/blender/bmesh/bmesh_class.h b/source/blender/bmesh/bmesh_class.h
index c79e4ed9d41..01e4c911d19 100644
--- a/source/blender/bmesh/bmesh_class.h
+++ b/source/blender/bmesh/bmesh_class.h
@@ -91,8 +91,14 @@ typedef struct BMVert {
BMHeader head;
struct BMFlagLayer *oflags; /* keep after header, an array of flags, mostly used by the operator stack */
- float co[3];
- float no[3];
+ float co[3]; /* vertex coordinates */
+ float no[3]; /* vertex normal */
+
+ /* pointer to (any) edge using this vertex (for disk cycles)
+ *
+ * note: some higher level functions set this to different edges that use this vertex,
+ * which is a bit of an abuse of internal bmesh data but also works OK for now (use with care!).
+ */
struct BMEdge *e;
} BMVert;
@@ -105,10 +111,14 @@ typedef struct BMEdge {
BMHeader head;
struct BMFlagLayer *oflags; /* keep after header, an array of flags, mostly used by the operator stack */
- struct BMVert *v1, *v2;
+ struct BMVert *v1, *v2; /* vertices (unordered) */
+
+ /* the list of loops around the edge (use l->radial_prev/next)
+ * to access the other loops using the edge */
struct BMLoop *l;
- /* disk cycle pointers */
+ /* disk cycle pointers
+ * relative data: d1 indicates indicates the next/prev edge around vertex v1 and d2 does the same for v2 */
BMDiskLink v1_disk_link, v2_disk_link;
} BMEdge;
@@ -161,9 +171,9 @@ typedef struct BMFace {
#else
BMLoop *l_first;
#endif
- int len; /* includes all boundary loops */
- float no[3]; /* yes, we do store this here */
- short mat_nr;
+ int len; /* number of vertices in the face */
+ float no[3]; /* face normal */
+ short mat_nr; /* material index */
// short _pad[3];
} BMFace;