39 |
bj |
1 |
#ifndef __VERTEX_H__
|
|
|
2 |
#define __VERTEX_H__
|
|
|
3 |
|
|
|
4 |
#include "templates.h"
|
|
|
5 |
|
|
|
6 |
|
|
|
7 |
namespace HMesh
|
|
|
8 |
{
|
|
|
9 |
typedef Vertex_template<Iters> Vertex;
|
|
|
10 |
typedef Iters::VertexList VertexList;
|
|
|
11 |
typedef Iters::VertexIter VertexIter;
|
|
|
12 |
|
|
|
13 |
/** Null Element for vertex lists. This is used as the value of an iterator
|
|
|
14 |
that points to nothing. */
|
|
|
15 |
extern VertexIter NULL_VERTEX_ITER;
|
|
|
16 |
|
|
|
17 |
/// Compute valency, i.e. number of incident edges.
|
|
|
18 |
int valency(VertexIter v);
|
|
|
19 |
|
|
|
20 |
/** Compute the vertex normal. This function computes the angle
|
|
|
21 |
weighted sum of incident face normals. */
|
|
|
22 |
const CGLA::Vec3f normal(VertexIter v);
|
|
|
23 |
|
|
|
24 |
/** Returns true if the two argument vertices are in each other's
|
|
|
25 |
one-rings. */
|
|
|
26 |
bool is_connected(VertexIter v1, VertexIter v2);
|
|
|
27 |
|
62 |
jab |
28 |
/** Returns true if the vertex is a boundary vertex. */
|
|
|
29 |
bool is_boundary(VertexIter v);
|
39 |
bj |
30 |
|
62 |
jab |
31 |
/** Check and enforce boundary consistency. */
|
|
|
32 |
void check_boundary_consistency(VertexIter v);
|
|
|
33 |
|
|
|
34 |
|
|
|
35 |
|
39 |
bj |
36 |
}
|
|
|
37 |
#endif
|