Performance Comparison

Benchmark projects are:

All tests were run on a machine with the following specifications:
3 GHz 6-Core Intel Core i5, 40GB 2667 MHz DDR4

All results are presented in seconds.

Solvers:

  • iTriangle(Unchecked-Raw) v0.32.0 – only raw triangulation, no validation check
  • iTriangle(Unchecked-Delaunay) v0.32.0 – raw triangulation and refinement Delaunay
  • iTriangle(Raw) v0.32.0 – validation and raw triangulation
  • iTriangle(Delaunay) v0.32.0 – validation, raw triangulation and refinement Delaunay
  • earcutr(MapBox) v0.4.3 – Rust port– only raw triangulation, no validation check
  • earcut(MapBox) v2.2.4 – C++ official– only raw triangulation, no validation check
  • triangle v1.6 – C official– constraint Delaunay triangulation, no validation check

Simple Star Test

This test generates and triangulate 10,000 unique star-shaped polygons, one at a time. Each shape is defined by:

  • A unique radius scale (100 variations)
  • A unique rotation (100 steps across a full circle)
  • A given number of corners (count), each with 10 points

All shapes are clean (non-intersecting), and no mesh is reused — each one is processed independently.

CountUn-RawUn-DelaunayRawDelaunayEarcutr (Rust)Earcut (C++)Triangle (C)
40.0427240.1114330.0790230.1492860.0572680.025060.46007
80.0837040.2170580.1693210.3032730.1278770.066890.88458
160.1746080.4037470.3738430.6167590.2901490.219481.52763
320.3631150.7733190.8321051.2537390.6930530.494213.07119
640.7699551.4902602.0778392.8496031.6992061.28376.14373
1281.6887462.9116525.5334986.8830174.2535213.1552611.7701
2563.4650315.76177716.0545118.5740911.460828.5850123.1163
5127.06397911.4786945.2026349.5091240.6231732.905245.0489

Star with Hole Test

This test generates and triangulates 10,000 unique star-shaped polygons with a central hole, one at a time. Each shape is defined by:

  • A unique radius scale (100 variations)
  • A unique rotation (100 steps across a full circle)
  • A central hole generated as a smaller star
  • A given number of corners (count), each with 10 points

All shapes are clean (non-intersecting), and no mesh is reused — each one is processed independently.

CountUn-RawUn-DelaunayRawDelaunayEarcutr (Rust)Earcut (C++)Triangle (C)
40.0945180.2018210.2508950.3610060.1870540.1361610.80138
80.1873400.3801160.5336520.7434550.4921140.4546291.59074
160.3887250.7282241.2002381.5797341.5378971.526633.12989
320.7968571.4776423.0115623.6629016.1086765.161886.21763
641.6864552.7470377.8796409.07157929.4153225.120712.29
1283.6015135.47858022.3863724.40913201.3632161.92324.6715
2567.61587911.4113963.6654667.22043------50.5745

Rect with Star Holes Test

This test generates and triangulates 25 unique rectangles filled with many 5 corners star-shaped holes.

Each shape is defined by:

  • A large outer rectangle
  • A grid of count × count small stars as holes, each with:
  • A varying radius scale (5 variations)
  • A unique rotation (5 variations)
  • 5 corners per star, with 10 points per corner.

All shapes are clean (non-intersecting), and no mesh is reused — each one is processed independently.

CountUn-RawUn-DelaunayRawDelaunayEarcutr (Rust)Earcut (C++)Triangle (C)
40.0023390.0082750.0091390.0427050.0378970.0053110.02818
80.0089060.0249210.0369000.1043500.0764050.0431030.09457
160.0443720.1166870.1428270.3235540.6059790.5712620.32930
320.1868360.5104890.4602540.9369047.4967548.548361.34492
640.7861422.6177531.9851954.231544210.3838201.285.86257
1284.35139518.809029.71983024.87851------28.4693
25618.93581149.748437.08732179.9286------175.662