diff options
author | pacien | 2017-12-24 15:35:54 +0100 |
---|---|---|
committer | pacien | 2017-12-24 15:35:54 +0100 |
commit | 2a9ca610acdd24ebf1a215f779bf2a5d9f80d9cf (patch) | |
tree | 458531b4f450307cc222856cf30155fa00d8d011 /include | |
parent | cdbae7a5e7515ba50ae21f15929a086fc40fcae3 (diff) | |
download | morpher-2a9ca610acdd24ebf1a215f779bf2a5d9f80d9cf.tar.gz |
Move Delaunay propagation function
Signed-off-by: pacien <pacien.trangirard@pacien.net>
Diffstat (limited to 'include')
-rw-r--r-- | include/morpher/quadrilateral.h | 11 | ||||
-rw-r--r-- | include/morpher/trianglemap.h | 10 |
2 files changed, 10 insertions, 11 deletions
diff --git a/include/morpher/quadrilateral.h b/include/morpher/quadrilateral.h index 8691263..c8cf3a1 100644 --- a/include/morpher/quadrilateral.h +++ b/include/morpher/quadrilateral.h | |||
@@ -36,15 +36,4 @@ void quadrilateral_flip_diagonal(TriangleMap *t1, TriangleMap *t2); | |||
36 | */ | 36 | */ |
37 | bool quadrilateral_is_delaunay(TriangleMap *t1, TriangleMap *t2); | 37 | bool quadrilateral_is_delaunay(TriangleMap *t1, TriangleMap *t2); |
38 | 38 | ||
39 | /** | ||
40 | * Function: quadrilateral_propagate_delaunay | ||
41 | * Ensures that the quadrilateral spawned by the given triangles fulfills the Delaunay criterion, | ||
42 | * flipping the diagonal if necessary and propagating the changes to the neighbouring triangles. | ||
43 | * | ||
44 | * Parameters: | ||
45 | * *start - the starting triangle | ||
46 | * *neighbor - a neighboring triangle | ||
47 | */ | ||
48 | void quadrilateral_propagate_delaunay(TriangleMap *start, TriangleMap *neighbor); | ||
49 | |||
50 | #endif | 39 | #endif |
diff --git a/include/morpher/trianglemap.h b/include/morpher/trianglemap.h index 0bb6a1d..f690a37 100644 --- a/include/morpher/trianglemap.h +++ b/include/morpher/trianglemap.h | |||
@@ -116,6 +116,16 @@ void trianglemap_replace_neighbor(TriangleMap *t, TriangleMap *old, TriangleMap | |||
116 | void trianglemap_foreach_neighbor(TriangleMap *t, void (*f)(TriangleMap *current, TriangleMap *neighbor)); | 116 | void trianglemap_foreach_neighbor(TriangleMap *t, void (*f)(TriangleMap *current, TriangleMap *neighbor)); |
117 | 117 | ||
118 | /** | 118 | /** |
119 | * Function: trianglemap_propagate_delaunay | ||
120 | * Ensures that the quadrilateral spawned by the given triangles and its neighbours fulfill the Delaunay criterion, | ||
121 | * flipping the diagonal if necessary and propagating the changes to the neighbouring triangles. | ||
122 | * | ||
123 | * Parameters: | ||
124 | * *t - the starting triangle | ||
125 | */ | ||
126 | void trianglemap_propagate_delaunay(TriangleMap *t); | ||
127 | |||
128 | /** | ||
119 | * Function: trianglemap_split | 129 | * Function: trianglemap_split |
120 | * Splits a triangle into three sub-triangles at the supplied center vertex, updating the surrounding triangles. | 130 | * Splits a triangle into three sub-triangles at the supplied center vertex, updating the surrounding triangles. |
121 | * The first triangle resulting from the split is returned, with the two others chained as linear neighbours. | 131 | * The first triangle resulting from the split is returned, with the two others chained as linear neighbours. |