mirror of
https://github.com/jhasse/poly2tri.git
synced 2024-11-26 15:26:12 +01:00
added kzer-za model; added # of triangles output
This commit is contained in:
parent
70bcf4b5d0
commit
c18dcd4eaa
208
testbed/data/kzer-za.dat
Normal file
208
testbed/data/kzer-za.dat
Normal file
@ -0,0 +1,208 @@
|
||||
101.25 1006.8145
|
||||
-0.0 869.6563
|
||||
0.0128 630.5782
|
||||
0.0256 391.5
|
||||
13.7628 385.7424
|
||||
20.536 382.9626
|
||||
26.8712 380.4928
|
||||
32.8641 378.3054
|
||||
38.6107 376.3728
|
||||
44.2066 374.6673
|
||||
49.7478 373.1613
|
||||
55.3299 371.8271
|
||||
61.0488 370.6372
|
||||
67.0003 369.564
|
||||
73.2803 368.5797
|
||||
77.5213 368.0746
|
||||
82.5785 367.6654
|
||||
88.2632 367.3539
|
||||
94.3869 367.1417
|
||||
100.7611 367.0308
|
||||
107.1972 367.0227
|
||||
113.5067 367.1193
|
||||
119.5009 367.3223
|
||||
124.9913 367.6334
|
||||
129.7894 368.0545
|
||||
136.7786 368.942
|
||||
143.9999 370.1039
|
||||
151.3793 371.5207
|
||||
158.8427 373.1727
|
||||
166.3159 375.0405
|
||||
173.725 377.1045
|
||||
180.9957 379.345
|
||||
188.0539 381.7425
|
||||
194.8257 384.2775
|
||||
201.2368 386.9303
|
||||
212.5 391.8398
|
||||
212.0876 550.4199
|
||||
211.6751 709.0
|
||||
274.002 709.0
|
||||
336.3288 709.0
|
||||
335.6652 636.25
|
||||
335.5574 623.9179
|
||||
335.4541 611.092
|
||||
335.3569 598.0163
|
||||
335.267 584.935
|
||||
335.186 572.0922
|
||||
335.1154 559.732
|
||||
335.0566 548.0986
|
||||
335.0111 537.436
|
||||
334.9804 527.9884
|
||||
334.9659 520.0
|
||||
334.9303 476.5
|
||||
264.0222 418.0
|
||||
193.114 359.5
|
||||
193.057 295.4984
|
||||
193.0 231.4968
|
||||
308.7516 115.7484
|
||||
424.5032 0.0
|
||||
430.7139 -0.0
|
||||
436.9246 -0.0
|
||||
458.9753 20.0
|
||||
481.0259 40.0
|
||||
558.3853 40.0
|
||||
635.7447 40.0
|
||||
660.5012 19.9588
|
||||
685.2578 -0.0824
|
||||
692.0471 0.2088
|
||||
698.8365 0.5
|
||||
809.4255 115.9161
|
||||
920.0146 231.3321
|
||||
919.7573 295.3526
|
||||
919.5 359.3731
|
||||
850.3179 416.4366
|
||||
781.1359 473.5
|
||||
781.0679 593.7577
|
||||
781.0 714.0154
|
||||
842.25 713.7577
|
||||
903.5 713.5
|
||||
903.5 552.5
|
||||
903.5 391.5
|
||||
915.5 386.2894
|
||||
925.0132 382.3439
|
||||
934.2958 378.8801
|
||||
943.4206 375.8827
|
||||
952.4605 373.3363
|
||||
961.4884 371.2257
|
||||
970.5772 369.5356
|
||||
979.7999 368.2507
|
||||
989.2293 367.3557
|
||||
998.9384 366.8354
|
||||
1009.0 366.6743
|
||||
1018.876 366.8794
|
||||
1028.7419 367.4649
|
||||
1038.5688 368.4253
|
||||
1048.3277 369.7549
|
||||
1057.9897 371.448
|
||||
1067.5259 373.499
|
||||
1076.9074 375.9022
|
||||
1086.1052 378.6521
|
||||
1095.0904 381.7429
|
||||
1103.834 385.169
|
||||
1105.4327 385.8354
|
||||
1107.0215 386.4969
|
||||
1108.5745 387.1429
|
||||
1110.0655 387.7624
|
||||
1111.4684 388.3447
|
||||
1112.7573 388.879
|
||||
1113.9059 389.3544
|
||||
1114.8883 389.7601
|
||||
1115.6784 390.0853
|
||||
1116.25 390.3193
|
||||
1119.0 391.4385
|
||||
1118.9578 633.4692
|
||||
1118.9155 875.5
|
||||
1016.0895 1009.5
|
||||
913.2634 1143.5
|
||||
908.6317 1143.8048
|
||||
904.0 1144.1096
|
||||
904.0 993.0548
|
||||
904.0 842.0
|
||||
842.5 842.0
|
||||
781.0 842.0
|
||||
781.0 918.5
|
||||
781.0 995.0
|
||||
758.5 995.0
|
||||
753.2091 995.0074
|
||||
748.7946 995.0327
|
||||
745.1813 995.0811
|
||||
742.294 995.1573
|
||||
740.0573 995.2664
|
||||
738.396 995.4133
|
||||
737.2349 995.6029
|
||||
736.4987 995.8401
|
||||
736.1121 996.13
|
||||
736.0 996.4774
|
||||
736.0975 996.8214
|
||||
736.4274 997.1133
|
||||
737.0461 997.3587
|
||||
738.0101 997.5629
|
||||
739.3756 997.7314
|
||||
741.1991 997.8696
|
||||
743.5368 997.9828
|
||||
746.4451 998.0766
|
||||
749.9804 998.1563
|
||||
754.1991 998.2274
|
||||
772.3983 998.5
|
||||
823.7285 1071.0
|
||||
875.0586 1143.5
|
||||
558.8642 1143.7516
|
||||
507.7462 1143.787
|
||||
459.1795 1143.8106
|
||||
413.8289 1143.8226
|
||||
372.3594 1143.8232
|
||||
335.4356 1143.813
|
||||
303.7226 1143.792
|
||||
277.885 1143.7606
|
||||
258.5879 1143.7192
|
||||
246.4959 1143.668
|
||||
242.2739 1143.6073
|
||||
244.9583 1139.4844
|
||||
252.4121 1128.4439
|
||||
263.46 1112.2019
|
||||
276.9266 1092.4741
|
||||
291.6365 1070.9766
|
||||
306.4143 1049.4252
|
||||
320.0847 1029.536
|
||||
331.4722 1013.0247
|
||||
339.4015 1001.6074
|
||||
342.6973 997.0
|
||||
342.9826 996.9147
|
||||
343.6619 996.8251
|
||||
344.7008 996.7328
|
||||
346.0645 996.6396
|
||||
347.7187 996.5473
|
||||
349.6288 996.4577
|
||||
351.7603 996.3725
|
||||
354.0786 996.2935
|
||||
356.5492 996.2225
|
||||
359.1377 996.1611
|
||||
363.0447 996.0717
|
||||
366.2623 995.9793
|
||||
368.8541 995.8758
|
||||
370.8832 995.7532
|
||||
372.4132 995.6032
|
||||
373.5073 995.4179
|
||||
374.229 995.1892
|
||||
374.6416 994.9088
|
||||
374.8086 994.5689
|
||||
374.7933 994.1611
|
||||
374.6362 993.7568
|
||||
374.2833 993.4194
|
||||
373.6581 993.1416
|
||||
372.6841 992.9157
|
||||
371.285 992.7342
|
||||
369.3843 992.5896
|
||||
366.9056 992.4743
|
||||
363.7725 992.3806
|
||||
359.9084 992.3012
|
||||
355.2371 992.2284
|
||||
336.0 991.9568
|
||||
336.0 914.9784
|
||||
336.0 838.0
|
||||
274.0 838.0
|
||||
212.0 838.0
|
||||
212.0 991.0
|
||||
212.0 1144.0
|
||||
207.25 1143.9864
|
||||
202.5 1143.9727
|
@ -131,6 +131,7 @@ int main(int argc, char* argv[])
|
||||
///
|
||||
|
||||
double init_time = glfwGetTime();
|
||||
|
||||
// Step 1 - Create CDT and add primary polyline
|
||||
CDT* cdt = new CDT(points);
|
||||
|
||||
@ -152,11 +153,13 @@ int main(int argc, char* argv[])
|
||||
cdt->Triangulate();
|
||||
|
||||
double dt = glfwGetTime() - init_time;
|
||||
cout << "Elapsed time (secs) = " << dt << endl;
|
||||
|
||||
triangles = cdt->GetTriangles();
|
||||
map = cdt->GetMap();
|
||||
|
||||
cout << "Number of triangles = " << triangles.size() << endl;
|
||||
cout << "Elapsed time (secs) = " << dt << endl;
|
||||
|
||||
MainLoop(atof(argv[4]));
|
||||
|
||||
ShutDown(0);
|
||||
|
Loading…
Reference in New Issue
Block a user