summaryrefslogtreecommitdiff
path: root/experimental/tectonics/geometry.h
diff options
context:
space:
mode:
Diffstat (limited to 'experimental/tectonics/geometry.h')
-rw-r--r--experimental/tectonics/geometry.h34
1 files changed, 27 insertions, 7 deletions
diff --git a/experimental/tectonics/geometry.h b/experimental/tectonics/geometry.h
index de01042..fdad15a 100644
--- a/experimental/tectonics/geometry.h
+++ b/experimental/tectonics/geometry.h
@@ -9,6 +9,13 @@ struct point_t {
};
+/* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ *
+ * quadtree
+ *
+ * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ */
+
struct quad_region_t {
struct point_t center;
double half_dim;
@@ -25,13 +32,6 @@ struct quadtree_node_t {
};
-/* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- *
- * quadtree
- *
- * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- */
-
/* check if a region contains a point */
bool quad_contains_point(struct quad_region_t region,
struct point_t pt);
@@ -65,4 +65,24 @@ int quadtree_get_closest(struct quadtree_node_t *root,
*/
void quadtree_free(struct quadtree_node_t *root);
+
+/* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ *
+ * mesh
+ *
+ * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ */
+
+struct triangle_t {
+ struct point_t p1, p2, p3;
+};
+
+struct triangle_array_t {
+ int n_triangles;
+ struct triangle_t *triangles;
+};
+
+
+
+
#endif