jhasse / Poly2tri
Licence: bsd-3-clause
2D constrained Delaunay triangulation library
Stars: ✭ 214
Labels
Projects that are alternatives of or similar to Poly2tri
Locationwithoutprompt
A proof of concept to show how easy it is to get coarse location of the user without using Core Location
Stars: ✭ 123 (-42.52%)
Mutual labels: triangulation
Manifoldplus
ManifoldPlus: A Robust and Scalable Watertight Manifold Surface Generation Method for Triangle Soups
Stars: ✭ 175 (-18.22%)
Mutual labels: triangulation
Geometry2d
Unity3D: A set of helper classes for 2D geometric calculations.
Stars: ✭ 40 (-81.31%)
Mutual labels: triangulation
Delaunator Sharp
Fast Delaunay triangulation of 2D points implemented in C#.
Stars: ✭ 104 (-51.4%)
Mutual labels: triangulation
Hxgeomalgo
Small collection of computational geometry algorithms in Haxe.
Stars: ✭ 133 (-37.85%)
Mutual labels: triangulation
Tin Terrain
A command-line tool for converting heightmaps in GeoTIFF format into tiled optimized meshes.
Stars: ✭ 392 (+83.18%)
Mutual labels: triangulation
Piccante
The hottest High Dynamic Range (HDR) Library
Stars: ✭ 195 (-8.88%)
Mutual labels: triangulation
Delaunator
An incredibly fast JavaScript library for Delaunay triangulation of 2D points
Stars: ✭ 1,641 (+666.82%)
Mutual labels: triangulation
Openlidar
Open Hardware scanning triangulation laser rangefinder
Stars: ✭ 166 (-22.43%)
Mutual labels: triangulation
Korma
Mathematics library focused on geometry for Multiplatform Kotlin 1.3
Stars: ✭ 65 (-69.63%)
Mutual labels: triangulation
Earcut
The fastest and smallest JavaScript polygon triangulation library for your WebGL apps
Stars: ✭ 1,359 (+535.05%)
Mutual labels: triangulation
Sltk
An OpenCV-based structured light processing toolkit.
Stars: ✭ 151 (-29.44%)
Mutual labels: triangulation
Polytri
🔺 Fast and simple polygon triangulation library.
Stars: ✭ 37 (-82.71%)
Mutual labels: triangulation
Opensimplelidar
Open Source scanning laser rangefinder
Stars: ✭ 2,206 (+930.84%)
Mutual labels: triangulation
Earcut.hpp
Fast, header-only polygon triangulation
Stars: ✭ 447 (+108.88%)
Mutual labels: triangulation
Triangle
Convert images to computer generated art using delaunay triangulation.
Stars: ✭ 1,838 (+758.88%)
Mutual labels: triangulation
Unity.library.eppz.geometry
2D Geometry for Unity. Suited for everyday polygon hassle. Polygon clipping, polygon winding direction, polygon area, polygon centroid, centroid of multiple polygons, line intersection, point-line distance, segment intersection, polygon-point containment, polygon triangulation, polygon Voronoi diagram, polygon offset, polygon outline, polygon buffer, polygon union, polygon substraction, polygon boolean operations, and more. It is a polygon fest.
Stars: ✭ 198 (-7.48%)
Mutual labels: triangulation
Libtessdotnet
C# port of the famous GLU Tessellator - prebuilt binaries now available in "releases" tab
Stars: ✭ 191 (-10.75%)
Mutual labels: triangulation
Cdt
C++ library for constrained Delaunay triangulation (CDT)
Stars: ✭ 165 (-22.9%)
Mutual labels: triangulation
Since there are no Input validation of the data given for triangulation you need to think about this. Poly2Tri does not support repeat points within epsilon.
- If you have a cyclic function that generates random points make sure you don't add the same coordinate twice.
- If you are given input and aren't sure same point exist twice you need to check for this yourself.
- Only simple polygons are supported. You may add holes or interior Steiner points
- Interior holes must not touch other holes, nor touch the polyline boundary
- Use the library in this order:
- Initialize CDT with a simple polyline (this defines the constrained edges)
- Add holes if necessary (also simple polylines)
- Add Steiner points
- Triangulate
Make sure you understand the preceding notice before posting an issue. If you have an issue not covered by the above, include your data-set with the problem. The only easy day was yesterday; have a nice day.
TESTBED INSTALLATION GUIDE
Dependencies
Core poly2tri lib:
- Standard Template Library (STL)
Testbed:
- OpenGL
- GLFW
Build the library
mkdir build && cd build
cmake -GNinja
cmake --build .
Build and run the unit tests
mkdir build && cd build
cmake -GNinja -DP2T_BUILD_TESTS=ON
cmake --build .
ctest --output-on-failure
Build the testbed
mkdir build && cd build
cmake -GNinja -DP2T_BUILD_TESTBED=ON
cmake --build .
Running the Examples
Load data points from a file:
p2t <filename> <center_x> <center_y> <zoom>
Random distribution of points inside a constrained box:
p2t random <num_points> <box_radius> <zoom>
Examples:
./build/p2t testbed/data/dude.dat 300 500 2
./build/p2t testbed/data/nazca_monkey.dat 0 0 9
./build/p2t random 10 100 5.0
./build/p2t random 1000 20000 0.025
References
- Domiter V. and Zalik B. (2008) Sweep‐line algorithm for constrained Delaunay triangulation
- FlipScan by library author Thomas Åhlén
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].