blob: 076f5914eac70d98e969defa7c13ccf12257426f [file] [log] [blame]
<html>
<head>
<div height="0" hidden="true">
Skia UnitTests: --match Simplify$ --resourcePath resources\ SK_DEBUG
<div id="fuzz763_4713_b">
seg=1 {{{41, 33}, {41, 36.3137093f}, {38.6568527f, 38.6568527f}}}
seg=2 {{{38.6568527f, 38.6568527f}, {36.3137093f, 41}, {33, 41}}}
seg=3 {{{33, 41}, {29.6862907f, 41}, {27.3431454f, 38.6568527f}}}
seg=4 {{{27.3431454f, 38.6568527f}, {25, 36.3137093f}, {25, 33}}}
seg=5 {{{25, 33}, {25, 29.6862907f}, {27.3431454f, 27.3431454f}}}
seg=6 {{{27.3431454f, 27.3431454f}, {29.6862907f, 25}, {33, 25}}}
seg=7 {{{33, 25}, {36.3137093f, 25}, {38.6568527f, 27.3431454f}}}
seg=8 {{{38.6568527f, 27.3431454f}, {41, 29.6862907f}, {41, 33}}}
seg=9 {{{33.2413864f, 24.6781349f}, {36.5549393f, 24.6459332f}, {38.920742f, 26.966198f}}}
seg=10 {{{38.920742f, 26.966198f}, {41.2865486f, 29.2864628f}, {41.3187523f, 32.6000175f}}}
seg=11 {{{41.3187523f, 32.6000175f}, {41.3509521f, 35.9135704f}, {39.0306854f, 38.2793732f}}}
seg=12 {{{39.0306854f, 38.2793732f}, {38.9995995f, 38.3110695f}, {38.9681816f, 38.3424988f}}}
seg=13 {{{38.9681816f, 38.3424988f}, {38.9374619f, 38.3742142f}, {38.9064751f, 38.4056053f}}}
seg=14 {{{38.9064751f, 38.4056053f}, {38.8441086f, 38.4687881f}, {38.7809143f, 38.5304031f}}}
seg=15 {{{38.7809143f, 38.5304031f}, {38.7196693f, 38.5940361f}, {38.6568527f, 38.6568527f}}}
seg=16 {{{38.6568527f, 38.6568527f}, {36.3137093f, 41}, {33, 41}}}
seg=17 {{{33, 41}, {29.6862907f, 41}, {27.3431454f, 38.6568527f}}}
seg=18 {{{27.3431454f, 38.6568527f}, {25, 36.3137093f}, {25, 33}}}
seg=19 {{{25, 33}, {25, 29.6862907f}, {27.3431454f, 27.3431454f}}}
seg=20 {{{27.3431454f, 27.3431454f}, {27.3875446f, 27.2987461f}, {27.4323025f, 27.2551785f}}}
seg=21 {{{27.4323025f, 27.2551785f}, {27.4755878f, 27.2101307f}, {27.5197105f, 27.165432f}}}
seg=22 {{{27.5197105f, 27.165432f}, {27.541851f, 27.1430035f}, {27.5638676f, 27.1209965f}}}
seg=23 {{{27.5638676f, 27.1209965f}, {27.5855064f, 27.0986347f}, {27.6075668f, 27.0761414f}}}
seg=24 {{{27.6075668f, 27.0761414f}, {29.9278316f, 24.7103367f}, {33.2413864f, 24.6781349f}}}
debugShowQuadIntersection wtTs[0]=1 {{{33.2413864,24.6781349}, {36.5549393,24.6459332}, {38.920742,26.966198}}} {{38.920742,26.966198}} wnTs[0]=0 {{{38.920742,26.966198}, {41.2865486,29.2864628}, {41.3187523,32.6000175}}}
debugShowQuadIntersection wtTs[0]=0 {{{33.2413864,24.6781349}, {36.5549393,24.6459332}, {38.920742,26.966198}}} {{33.2413864,24.6781349}} wnTs[0]=1 {{{27.6075668,27.0761414}, {29.9278316,24.7103367}, {33.2413864,24.6781349}}}
debugShowQuadIntersection wtTs[0]=1 {{{38.920742,26.966198}, {41.2865486,29.2864628}, {41.3187523,32.6000175}}} {{41.3187523,32.6000175}} wnTs[0]=0 {{{41.3187523,32.6000175}, {41.3509521,35.9135704}, {39.0306854,38.2793732}}}
debugShowQuadIntersection wtTs[0]=1 {{{41.3187523,32.6000175}, {41.3509521,35.9135704}, {39.0306854,38.2793732}}} {{39.0306854,38.2793732}} wnTs[0]=0 {{{39.0306854,38.2793732}, {38.9995995,38.3110695}, {38.9681816,38.3424988}}}
debugShowQuadIntersection wtTs[0]=1 {{{39.0306854,38.2793732}, {38.9995995,38.3110695}, {38.9681816,38.3424988}}} {{38.9681816,38.3424988}} wnTs[0]=0 {{{38.9681816,38.3424988}, {38.9374619,38.3742142}, {38.9064751,38.4056053}}}
debugShowQuadIntersection wtTs[0]=1 {{{38.9681816,38.3424988}, {38.9374619,38.3742142}, {38.9064751,38.4056053}}} {{38.9064751,38.4056053}} wnTs[0]=0 {{{38.9064751,38.4056053}, {38.8441086,38.4687881}, {38.7809143,38.5304031}}}
debugShowQuadIntersection wtTs[0]=1 {{{38.9064751,38.4056053}, {38.8441086,38.4687881}, {38.7809143,38.5304031}}} {{38.7809143,38.5304031}} wnTs[0]=0 {{{38.7809143,38.5304031}, {38.7196693,38.5940361}, {38.6568527,38.6568527}}}
debugShowQuadIntersection wtTs[0]=1 {{{38.7809143,38.5304031}, {38.7196693,38.5940361}, {38.6568527,38.6568527}}} {{38.6568527,38.6568527}} wnTs[0]=0 {{{38.6568527,38.6568527}, {36.3137093,41}, {33,41}}}
debugShowQuadIntersection wtTs[0]=1 {{{38.6568527,38.6568527}, {36.3137093,41}, {33,41}}} {{33,41}} wnTs[0]=0 {{{33,41}, {29.6862907,41}, {27.3431454,38.6568527}}}
debugShowQuadIntersection wtTs[0]=1 {{{33,41}, {29.6862907,41}, {27.3431454,38.6568527}}} {{27.3431454,38.6568527}} wnTs[0]=0 {{{27.3431454,38.6568527}, {25,36.3137093}, {25,33}}}
debugShowQuadIntersection wtTs[0]=1 {{{27.3431454,38.6568527}, {25,36.3137093}, {25,33}}} {{25,33}} wnTs[0]=0 {{{25,33}, {25,29.6862907}, {27.3431454,27.3431454}}}
debugShowQuadIntersection wtTs[0]=1 {{{25,33}, {25,29.6862907}, {27.3431454,27.3431454}}} {{27.3431454,27.3431454}} wnTs[0]=0 {{{27.3431454,27.3431454}, {27.3875446,27.2987461}, {27.4323025,27.2551785}}}
debugShowQuadIntersection wtTs[0]=1 {{{27.3431454,27.3431454}, {27.3875446,27.2987461}, {27.4323025,27.2551785}}} {{27.4323025,27.2551785}} wnTs[0]=0 {{{27.4323025,27.2551785}, {27.4755878,27.2101307}, {27.5197105,27.165432}}}
debugShowQuadIntersection wtTs[0]=1 {{{27.4323025,27.2551785}, {27.4755878,27.2101307}, {27.5197105,27.165432}}} {{27.5197105,27.165432}} wnTs[0]=0 {{{27.5197105,27.165432}, {27.541851,27.1430035}, {27.5638676,27.1209965}}}
debugShowQuadIntersection wtTs[0]=1 {{{27.5197105,27.165432}, {27.541851,27.1430035}, {27.5638676,27.1209965}}} {{27.5638676,27.1209965}} wnTs[0]=0 {{{27.5638676,27.1209965}, {27.5855064,27.0986347}, {27.6075668,27.0761414}}}
debugShowQuadIntersection wtTs[0]=1 {{{27.5638676,27.1209965}, {27.5855064,27.0986347}, {27.6075668,27.0761414}}} {{27.6075668,27.0761414}} wnTs[0]=0 {{{27.6075668,27.0761414}, {29.9278316,24.7103367}, {33.2413864,24.6781349}}}
id=1 1=(0,0.5) [2] 3=(0.5,1) [2] id=2 2=(0,1) [3,1]
id=1 1=(0,0.5) [2] 3=(0.5,1) [4] id=2 2=(0,0.5) [1] 4=(0.5,1) [3]
id=1 3=(0.5,1) [4] id=2 4=(0.5,1) [3]
id=1 (empty) id=2 (empty)
debugShowQuadIntersection no intersect {{{33.2413864,24.6781349}, {36.5549393,24.6459332}, {38.920742,26.966198}}} {{{33,25}, {36.3137093,25}, {38.6568527,27.3431454}}}
id=1 1=(0,1) [4,2] id=2 2=(0,0.5) [1] 4=(0.5,1) [1]
id=1 (empty) id=2 (empty)
debugShowQuadIntersection no intersect {{{38.920742,26.966198}, {41.2865486,29.2864628}, {41.3187523,32.6000175}}} {{{38.6568527,27.3431454}, {41,29.6862907}, {41,33}}}
id=1 1=(0,0.5) [2] 3=(0.5,1) [2] id=2 2=(0,1) [3,1]
id=1 1=(0,0.5) [2] 3=(0.5,1) [4,2] id=2 2=(0,0.5) [3,1] 4=(0.5,1) [3]
id=1 3=(0.5,1) [4,2] id=2 2=(0,0.5) [3] 4=(0.5,1) [3]
id=1 3=(0.5,1) [6,4] id=2 6=(0.25,0.5) [3] 4=(0.5,1) [3]
id=1 3=(0.5,0.75) [4] 7=(0.75,1) [4] id=2 4=(0.5,1) [7,3]
id=1 7=(0.75,1) [8,4] id=2 4=(0.5,0.75) [7] 8=(0.75,1) [7]
id=1 7=(0.75,1) [10,8] id=2 10=(0.625,0.75) [7] 8=(0.75,1) [7]
id=1 9=(0.875,1) [8] id=2 8=(0.75,1) [9]
id=1 (empty) id=2 (empty)
debugShowQuadIntersection no intersect {{{41.3187523,32.6000175}, {41.3509521,35.9135704}, {39.0306854,38.2793732}}} {{{41,33}, {41,36.3137093}, {38.6568527,38.6568527}}}
debugShowQuadIntersection no intersect {{{41.3187523,32.6000175}, {41.3509521,35.9135704}, {39.0306854,38.2793732}}} {{{38.6568527,27.3431454}, {41,29.6862907}, {41,33}}}
id=1 1=(0,1) [4] id=2 4=(0.5,1) [1]
id=1 1=(0,1) [6] id=2 6=(0.75,1) [1]
id=1 (empty) id=2 (empty)
debugShowQuadIntersection no intersect {{{39.0306854,38.2793732}, {38.9995995,38.3110695}, {38.9681816,38.3424988}}} {{{41,33}, {41,36.3137093}, {38.6568527,38.6568527}}}
id=1 1=(0,1) [4] id=2 4=(0.5,1) [1]
id=1 1=(0,1) [6] id=2 6=(0.75,1) [1]
id=1 1=(0,1) [8] id=2 8=(0.875,1) [1]
id=1 (empty) id=2 (empty)
debugShowQuadIntersection no intersect {{{38.9681816,38.3424988}, {38.9374619,38.3742142}, {38.9064751,38.4056053}}} {{{41,33}, {41,36.3137093}, {38.6568527,38.6568527}}}
id=1 1=(0,1) [4] id=2 4=(0.5,1) [1]
id=1 1=(0,1) [6] id=2 6=(0.75,1) [1]
id=1 1=(0,1) [8] id=2 8=(0.875,1) [1]
id=1 1=(0,1) [10] id=2 10=(0.9375,1) [1]
id=1 1=(0,1) [12,10] id=2 10=(0.9375,0.96875) [1] 12=(0.96875,1) [1]
id=1 1=(0,1) [14,12,10] id=2 10=(0.9375,0.953125) [1] 14=(0.953125,0.96875) [1] 12=(0.96875,1) [1]
id=1 1=(0,1) [14,12,10] id=2 10=(0.9375,0.953125) [1] 14=(0.953125,0.96875) [1] 12=(0.96875,0.984375) [1]
id=1 3=(0.5,1) [12] id=2 12=(0.96875,0.984375) [3]
id=1 3=(0.5,1) [12] id=2 12=(0.96875,0.976563) [3]
id=1 5=(0.75,1) [12] id=2 12=(0.96875,0.976563) [5]
id=1 5=(0.75,1) [20,12] id=2 12=(0.96875,0.972656) [5] 20=(0.972656,0.976563) [5]
id=1 7=(0.875,1) [20] id=2 20=(0.972656,0.976563) [7]
id=1 7=(0.875,1) [20] id=2 20=(0.972656,0.974609) [7]
id=1 (empty) id=2 (empty)
debugShowQuadIntersection no intersect {{{38.9064751,38.4056053}, {38.8441086,38.4687881}, {38.7809143,38.5304031}}} {{{41,33}, {41,36.3137093}, {38.6568527,38.6568527}}}
id=1 1=(0,1) [4] id=2 4=(0.5,1) [1]
id=1 1=(0,1) [6] id=2 6=(0.75,1) [1]
id=1 1=(0,1) [8] id=2 8=(0.875,1) [1]
id=1 1=(0,1) [10] id=2 10=(0.9375,1) [1]
id=1 1=(0,1) [12] id=2 12=(0.96875,1) [1]
id=1 1=(0,1) [14,12] id=2 12=(0.96875,0.984375) [1] 14=(0.984375,1) [1]
id=1 1=(0,0.5) [14,12] 3=(0.5,1) [14] id=2 12=(0.96875,0.984375) [1] 14=(0.984375,1) [3,1]
id=1 1=(0,0.5) [16,14,12] 3=(0.5,1) [14] id=2 12=(0.96875,0.976563) [1] 16=(0.976563,0.984375) [1] 14=(0.984375,1) [3,1]
id=1 1=(0,0.5) [16,14,12] 3=(0.5,1) [18,14] id=2 12=(0.96875,0.976563) [1] 16=(0.976563,0.984375) [1] 14=(0.984375,0.992188) [3,1] 18=(0.992188,1) [3]
id=1 1=(0,0.25) [16,12] 5=(0.25,0.5) [14,16] 3=(0.5,1) [18,14] id=2 12=(0.96875,0.976563) [1] 16=(0.976563,0.984375) [5,1] 14=(0.984375,0.992188) [5,3] 18=(0.992188,1) [3]
id=1 1=(0,0.25) [16,12] 5=(0.25,0.5) [14,16] 3=(0.5,0.75) [18,14] 7=(0.75,1) [18] id=2 12=(0.96875,0.976563) [1] 16=(0.976563,0.984375) [5,1] 14=(0.984375,0.992188) [5,3] 18=(0.992188,1) [7,3]
id=1 1=(0,0.25) [20,16] 5=(0.25,0.5) [14,16] 3=(0.5,0.75) [18,14] 7=(0.75,1) [18] id=2 20=(0.972656,0.976563) [1] 16=(0.976563,0.984375) [5,1] 14=(0.984375,0.992188) [5,3] 18=(0.992188,1) [7,3]
id=1 1=(0,0.25) [20,16] 5=(0.25,0.5) [22,14,16] 3=(0.5,0.75) [18,14] 7=(0.75,1) [18] id=2 20=(0.972656,0.976563) [1] 16=(0.976563,0.980469) [5,1] 22=(0.980469,0.984375) [5] 14=(0.984375,0.992188) [5,3] 18=(0.992188,1) [7,3]
id=1 1=(0,0.25) [20,16] 5=(0.25,0.5) [22,14,16] 3=(0.5,0.75) [24,18,14] 7=(0.75,1) [18] id=2 20=(0.972656,0.976563) [1] 16=(0.976563,0.980469) [5,1] 22=(0.980469,0.984375) [5] 14=(0.984375,0.988281) [5,3] 24=(0.988281,0.992188) [3] 18=(0.992188,1) [7,3]
id=1 1=(0,0.25) [20,16] 5=(0.25,0.5) [22,14,16] 3=(0.5,0.75) [24,18,14] 7=(0.75,1) [26,18] id=2 20=(0.972656,0.976563) [1] 16=(0.976563,0.980469) [5,1] 22=(0.980469,0.984375) [5] 14=(0.984375,0.988281) [5,3] 24=(0.988281,0.992188) [3] 18=(0.992188,0.996094) [7,3] 26=(0.996094,1) [7]
id=1 1=(0,0.125) [20] 9=(0.125,0.25) [16,20] 5=(0.25,0.5) [22,14,16] 3=(0.5,0.75) [24,18,14] 7=(0.75,1) [26,18] id=2 20=(0.972656,0.976563) [9,1] 16=(0.976563,0.980469) [9,5] 22=(0.980469,0.984375) [5] 14=(0.984375,0.988281) [5,3] 24=(0.988281,0.992188) [3] 18=(0.992188,0.996094) [7,3] 26=(0.996094,1) [7]
id=1 1=(0,0.125) [20] 9=(0.125,0.25) [16,20] 5=(0.25,0.375) [22,16] 11=(0.375,0.5) [14,22] 3=(0.5,0.75) [24,18,14] 7=(0.75,1) [26,18] id=2 20=(0.972656,0.976563) [9,1] 16=(0.976563,0.980469) [9,5] 22=(0.980469,0.984375) [11,5] 14=(0.984375,0.988281) [11,3] 24=(0.988281,0.992188) [3] 18=(0.992188,0.996094) [7,3] 26=(0.996094,1) [7]
id=1 1=(0,0.125) [20] 9=(0.125,0.25) [16,20] 5=(0.25,0.375) [22,16] 11=(0.375,0.5) [14,22] 3=(0.5,0.625) [24,14] 13=(0.625,0.75) [18,24] 7=(0.75,1) [26,18] id=2 20=(0.972656,0.976563) [9,1] 16=(0.976563,0.980469) [9,5] 22=(0.980469,0.984375) [11,5] 14=(0.984375,0.988281) [11,3] 24=(0.988281,0.992188) [13,3] 18=(0.992188,0.996094) [13,7] 26=(0.996094,1) [7]
id=1 1=(0,0.125) [20] 9=(0.125,0.25) [16,20] 5=(0.25,0.375) [22,16] 11=(0.375,0.5) [14,22] 3=(0.5,0.625) [24,14] 13=(0.625,0.75) [18,24] 7=(0.75,0.875) [26,18] 15=(0.875,1) [26] id=2 20=(0.972656,0.976563) [9,1] 16=(0.976563,0.980469) [9,5] 22=(0.980469,0.984375) [11,5] 14=(0.984375,0.988281) [11,3] 24=(0.988281,0.992188) [13,3] 18=(0.992188,0.996094) [13,7] 26=(0.996094,1) [15,7]
id=1 1=(0,0.125) [28,20] 9=(0.125,0.25) [28,16] 5=(0.25,0.375) [22,16] 11=(0.375,0.5) [14,22] 3=(0.5,0.625) [24,14] 13=(0.625,0.75) [18,24] 7=(0.75,0.875) [26,18] 15=(0.875,1) [26] id=2 20=(0.972656,0.974609) [1] 28=(0.974609,0.976563) [1,9] 16=(0.976563,0.980469) [9,5] 22=(0.980469,0.984375) [11,5] 14=(0.984375,0.988281) [11,3] 24=(0.988281,0.992188) [13,3] 18=(0.992188,0.996094) [13,7] 26=(0.996094,1) [15,7]
id=1 1=(0,0.125) [28,20] 9=(0.125,0.25) [30,28,16] 5=(0.25,0.375) [30,22] 11=(0.375,0.5) [14,22] 3=(0.5,0.625) [24,14] 13=(0.625,0.75) [18,24] 7=(0.75,0.875) [26,18] 15=(0.875,1) [26] id=2 20=(0.972656,0.974609) [1] 28=(0.974609,0.976563) [1,9] 16=(0.976563,0.978516) [9] 30=(0.978516,0.980469) [5,9] 22=(0.980469,0.984375) [11,5] 14=(0.984375,0.988281) [11,3] 24=(0.988281,0.992188) [13,3] 18=(0.992188,0.996094) [13,7] 26=(0.996094,1) [15,7]
id=1 1=(0,0.125) [28,20] 9=(0.125,0.25) [30,28,16] 5=(0.25,0.375) [32,30,22] 11=(0.375,0.5) [32,14] 3=(0.5,0.625) [24,14] 13=(0.625,0.75) [18,24] 7=(0.75,0.875) [26,18] 15=(0.875,1) [26] id=2 20=(0.972656,0.974609) [1] 28=(0.974609,0.976563) [1,9] 16=(0.976563,0.978516) [9] 30=(0.978516,0.980469) [5,9] 22=(0.980469,0.982422) [5] 32=(0.982422,0.984375) [5,11] 14=(0.984375,0.988281) [11,3] 24=(0.988281,0.992188) [13,3] 18=(0.992188,0.996094) [13,7] 26=(0.996094,1) [15,7]
id=1 1=(0,0.125) [28,20] 9=(0.125,0.25) [30,28,16] 5=(0.25,0.375) [32,30,22] 11=(0.375,0.5) [34,32,14] 3=(0.5,0.625) [34,24] 13=(0.625,0.75) [18,24] 7=(0.75,0.875) [26,18] 15=(0.875,1) [26] id=2 20=(0.972656,0.974609) [1] 28=(0.974609,0.976563) [1,9] 16=(0.976563,0.978516) [9] 30=(0.978516,0.980469) [5,9] 22=(0.980469,0.982422) [5] 32=(0.982422,0.984375) [5,11] 14=(0.984375,0.986328) [11] 34=(0.986328,0.988281) [3,11] 24=(0.988281,0.992188) [13,3] 18=(0.992188,0.996094) [13,7] 26=(0.996094,1) [15,7]
id=1 1=(0,0.125) [28,20] 9=(0.125,0.25) [30,28,16] 5=(0.25,0.375) [32,30,22] 11=(0.375,0.5) [34,32,14] 3=(0.5,0.625) [34,24] 13=(0.625,0.75) [36,18,24] 7=(0.75,0.875) [26,18] 15=(0.875,1) [26] id=2 20=(0.972656,0.974609) [1] 28=(0.974609,0.976563) [1,9] 16=(0.976563,0.978516) [9] 30=(0.978516,0.980469) [5,9] 22=(0.980469,0.982422) [5] 32=(0.982422,0.984375) [5,11] 14=(0.984375,0.986328) [11] 34=(0.986328,0.988281) [3,11] 24=(0.988281,0.990234) [13,3] 36=(0.990234,0.992188) [13] 18=(0.992188,0.996094) [13,7] 26=(0.996094,1) [15,7]
id=1 1=(0,0.125) [28,20] 9=(0.125,0.25) [30,28,16] 5=(0.25,0.375) [32,30,22] 11=(0.375,0.5) [34,32,14] 3=(0.5,0.625) [34,24] 13=(0.625,0.75) [36,18,24] 7=(0.75,0.875) [38,26,18] 15=(0.875,1) [26] id=2 20=(0.972656,0.974609) [1] 28=(0.974609,0.976563) [1,9] 16=(0.976563,0.978516) [9] 30=(0.978516,0.980469) [5,9] 22=(0.980469,0.982422) [5] 32=(0.982422,0.984375) [5,11] 14=(0.984375,0.986328) [11] 34=(0.986328,0.988281) [3,11] 24=(0.988281,0.990234) [13,3] 36=(0.990234,0.992188) [13] 18=(0.992188,0.994141) [13,7] 38=(0.994141,0.996094) [7] 26=(0.996094,1) [15,7]
id=1 1=(0,0.125) [28,20] 9=(0.125,0.25) [30,28,16] 5=(0.25,0.375) [32,30,22] 11=(0.375,0.5) [34,32,14] 3=(0.5,0.625) [34,24] 13=(0.625,0.75) [36,18,24] 7=(0.75,0.875) [38,26,18] 15=(0.875,1) [40,26] id=2 20=(0.972656,0.974609) [1] 28=(0.974609,0.976563) [1,9] 16=(0.976563,0.978516) [9] 30=(0.978516,0.980469) [5,9] 22=(0.980469,0.982422) [5] 32=(0.982422,0.984375) [5,11] 14=(0.984375,0.986328) [11] 34=(0.986328,0.988281) [3,11] 24=(0.988281,0.990234) [13,3] 36=(0.990234,0.992188) [13] 18=(0.992188,0.994141) [13,7] 38=(0.994141,0.996094) [7] 26=(0.996094,0.998047) [15,7] 40=(0.998047,1) [15]
setPerp t=0.974609375 cPt=(38.7743301,38.5372393) == oppT=0.0537252999 fPerpPt=(38.774329,38.5372382)
setPerp t=0.9765625 cPt=(38.7654006,38.5464847) == oppT=0.126456412 fPerpPt=(38.7653995,38.5464837)
setPerp t=0.0625 cPt=(38.7732525,38.5383541) == oppT=0.974845025 fPerpPt=(38.7732537,38.5383551)
setPerp t=0.974609375 cPt=(38.7743301,38.5372393) == oppT=0.0537252999 fPerpPt=(38.774329,38.5372382)
setPerp t=0 cPt=(38.7809143,38.5304031) == oppT=0.973166462 fPerpPt=(38.7809154,38.5304042)
setPerp t=0.974609375 cPt=(38.7743301,38.5372393) == oppT=0.0537252999 fPerpPt=(38.774329,38.5372382)
setPerp t=0.9765625 cPt=(38.7654006,38.5464847) == oppT=0.126456412 fPerpPt=(38.7653995,38.5464837)
setPerp t=0.0625 cPt=(38.7732525,38.5383541) == oppT=0.974845025 fPerpPt=(38.7732537,38.5383551)
setPerp t=0.125 cPt=(38.7655785,38.5462986) == oppT=0.976523392 fPerpPt=(38.7655796,38.5462997)
id=1 9=(0.125,0.25) [30,28,16] 5=(0.25,0.375) [32,30,22] 11=(0.375,0.5) [34,32,14] 3=(0.5,0.625) [34,24] 13=(0.625,0.75) [36,18,24] 7=(0.75,0.875) [38,26,18] 15=(0.875,1) [40,26] id=2 28=(0.974609,0.976563) [9] 16=(0.976563,0.978516) [9] 30=(0.978516,0.980469) [5,9] 22=(0.980469,0.982422) [5] 32=(0.982422,0.984375) [5,11] 14=(0.984375,0.986328) [11] 34=(0.986328,0.988281) [3,11] 24=(0.988281,0.990234) [13,3] 36=(0.990234,0.992188) [13] 18=(0.992188,0.994141) [13,7] 38=(0.994141,0.996094) [7] 26=(0.996094,0.998047) [15,7] 40=(0.998047,1) [15]
setPerp t=0.974609375 cPt=(38.7743301,38.5372393) == oppT=0.0537252999 fPerpPt=(38.774329,38.5372382)
setPerp t=0.9765625 cPt=(38.7654006,38.5464847) == oppT=0.126456412 fPerpPt=(38.7653995,38.5464837)
setPerp t=0.125 cPt=(38.7655785,38.5462986) == oppT=0.976523392 fPerpPt=(38.7655796,38.5462997)
setPerp t=0.9765625 cPt=(38.7654006,38.5464847) == oppT=0.126456412 fPerpPt=(38.7653995,38.5464837)
setPerp t=0.978515625 cPt=(38.7564533,38.5557228) == oppT=0.199197443 fPerpPt=(38.7564523,38.5557218)
setPerp t=0.1875 cPt=(38.7578922,38.5542368) == oppT=0.978201562 fPerpPt=(38.7578932,38.5542378)
setPerp t=0.9765625 cPt=(38.7654006,38.5464847) == oppT=0.126456412 fPerpPt=(38.7653995,38.5464837)
setPerp t=0.978515625 cPt=(38.7564533,38.5557228) == oppT=0.199197443 fPerpPt=(38.7564523,38.5557218)
setPerp t=0.1875 cPt=(38.7578922,38.5542368) == oppT=0.978201562 fPerpPt=(38.7578932,38.5542378)
setPerp t=0.978515625 cPt=(38.7564533,38.5557228) == oppT=0.199197443 fPerpPt=(38.7564523,38.5557218)
setPerp t=0.98046875 cPt=(38.7474881,38.5649534) == oppT=0.271948381 fPerpPt=(38.7474871,38.5649525)
setPerp t=0.25 cPt=(38.7501936,38.5621686) == oppT=0.979879536 fPerpPt=(38.7501946,38.5621695)
id=1 5=(0.25,0.375) [32,30,22] 11=(0.375,0.5) [34,32,14] 3=(0.5,0.625) [34,24] 13=(0.625,0.75) [36,18,24] 7=(0.75,0.875) [38,26,18] 15=(0.875,1) [40,26] id=2 30=(0.978516,0.980469) [5] 22=(0.980469,0.982422) [5] 32=(0.982422,0.984375) [5,11] 14=(0.984375,0.986328) [11] 34=(0.986328,0.988281) [3,11] 24=(0.988281,0.990234) [13,3] 36=(0.990234,0.992188) [13] 18=(0.992188,0.994141) [13,7] 38=(0.994141,0.996094) [7] 26=(0.996094,0.998047) [15,7] 40=(0.998047,1) [15]
setPerp t=0.978515625 cPt=(38.7564533,38.5557228) == oppT=0.199197443 fPerpPt=(38.7564523,38.5557218)
setPerp t=0.98046875 cPt=(38.7474881,38.5649534) == oppT=0.271948381 fPerpPt=(38.7474871,38.5649525)
setPerp t=0.25 cPt=(38.7501936,38.5621686) == oppT=0.979879536 fPerpPt=(38.7501946,38.5621695)
setPerp t=0.98046875 cPt=(38.7474881,38.5649534) == oppT=0.271948381 fPerpPt=(38.7474871,38.5649525)
setPerp t=0.982421875 cPt=(38.738505,38.5741767) == oppT=0.344709216 fPerpPt=(38.7385041,38.5741759)
setPerp t=0.3125 cPt=(38.7424827,38.570094) == oppT=0.981557313 fPerpPt=(38.7424836,38.5700949)
setPerp t=0.98046875 cPt=(38.7474881,38.5649534) == oppT=0.271948381 fPerpPt=(38.7474871,38.5649525)
setPerp t=0.982421875 cPt=(38.738505,38.5741767) == oppT=0.344709216 fPerpPt=(38.7385041,38.5741759)
setPerp t=0.3125 cPt=(38.7424827,38.570094) == oppT=0.981557313 fPerpPt=(38.7424836,38.5700949)
setPerp t=0.982421875 cPt=(38.738505,38.5741767) == oppT=0.344709216 fPerpPt=(38.7385041,38.5741759)
setPerp t=0.984375 cPt=(38.729504,38.5833925) == oppT=0.417479935 fPerpPt=(38.7295033,38.5833918)
setPerp t=0.375 cPt=(38.7347596,38.5780131) == oppT=0.983234895 fPerpPt=(38.7347604,38.5780138)
id=1 11=(0.375,0.5) [34,32,14] 3=(0.5,0.625) [34,24] 13=(0.625,0.75) [36,18,24] 7=(0.75,0.875) [38,26,18] 15=(0.875,1) [40,26] id=2 32=(0.982422,0.984375) [11] 14=(0.984375,0.986328) [11] 34=(0.986328,0.988281) [3,11] 24=(0.988281,0.990234) [13,3] 36=(0.990234,0.992188) [13] 18=(0.992188,0.994141) [13,7] 38=(0.994141,0.996094) [7] 26=(0.996094,0.998047) [15,7] 40=(0.998047,1) [15]
setPerp t=0.982421875 cPt=(38.738505,38.5741767) == oppT=0.344709216 fPerpPt=(38.7385041,38.5741759)
setPerp t=0.984375 cPt=(38.729504,38.5833925) == oppT=0.417479935 fPerpPt=(38.7295033,38.5833918)
setPerp t=0.375 cPt=(38.7347596,38.5780131) == oppT=0.983234895 fPerpPt=(38.7347604,38.5780138)
setPerp t=0.984375 cPt=(38.729504,38.5833925) == oppT=0.417479935 fPerpPt=(38.7295033,38.5833918)
setPerp t=0.986328125 cPt=(38.7204852,38.592601) == oppT=0.490260525 fPerpPt=(38.7204846,38.5926004)
setPerp t=0.4375 cPt=(38.7270241,38.5859257) == oppT=0.984912281 fPerpPt=(38.7270248,38.5859264)
setPerp t=0.984375 cPt=(38.729504,38.5833925) == oppT=0.417479935 fPerpPt=(38.7295033,38.5833918)
setPerp t=0.986328125 cPt=(38.7204852,38.592601) == oppT=0.490260525 fPerpPt=(38.7204846,38.5926004)
setPerp t=0.4375 cPt=(38.7270241,38.5859257) == oppT=0.984912281 fPerpPt=(38.7270248,38.5859264)
setPerp t=0.986328125 cPt=(38.7204852,38.592601) == oppT=0.490260525 fPerpPt=(38.7204846,38.5926004)
setPerp t=0.98828125 cPt=(38.7114485,38.601802) == oppT=0.563050975 fPerpPt=(38.711448,38.6018015)
setPerp t=0.5 cPt=(38.7192764,38.593832) == oppT=0.986589471 fPerpPt=(38.719277,38.5938326)
id=1 3=(0.5,0.625) [34,24] 13=(0.625,0.75) [36,18,24] 7=(0.75,0.875) [38,26,18] 15=(0.875,1) [40,26] id=2 34=(0.986328,0.988281) [3] 24=(0.988281,0.990234) [13,3] 36=(0.990234,0.992188) [13] 18=(0.992188,0.994141) [13,7] 38=(0.994141,0.996094) [7] 26=(0.996094,0.998047) [15,7] 40=(0.998047,1) [15]
setPerp t=0.986328125 cPt=(38.7204852,38.592601) == oppT=0.490260525 fPerpPt=(38.7204846,38.5926004)
setPerp t=0.98828125 cPt=(38.7114485,38.601802) == oppT=0.563050975 fPerpPt=(38.711448,38.6018015)
setPerp t=0.5 cPt=(38.7192764,38.593832) == oppT=0.986589471 fPerpPt=(38.719277,38.5938326)
setPerp t=0.5625 cPt=(38.7115164,38.6017319) == oppT=0.988266467 fPerpPt=(38.7115169,38.6017324)
setPerp t=0.98828125 cPt=(38.7114485,38.601802) == oppT=0.563050975 fPerpPt=(38.711448,38.6018015)
setPerp t=0.990234375 cPt=(38.7023939,38.6109956) == oppT=0.635851272 fPerpPt=(38.7023935,38.6109953)
setPerp t=0.625 cPt=(38.7037442,38.6096255) == oppT=0.989943268 fPerpPt=(38.7037445,38.6096258)
setPerp t=0.986328125 cPt=(38.7204852,38.592601) == oppT=0.490260525 fPerpPt=(38.7204846,38.5926004)
setPerp t=0.98828125 cPt=(38.7114485,38.601802) == oppT=0.563050975 fPerpPt=(38.711448,38.6018015)
setPerp t=0.5625 cPt=(38.7115164,38.6017319) == oppT=0.988266467 fPerpPt=(38.7115169,38.6017324)
id=1 13=(0.625,0.75) [36,18,24] 7=(0.75,0.875) [38,26,18] 15=(0.875,1) [40,26] id=2 24=(0.988281,0.990234) [13] 36=(0.990234,0.992188) [13] 18=(0.992188,0.994141) [13,7] 38=(0.994141,0.996094) [7] 26=(0.996094,0.998047) [15,7] 40=(0.998047,1) [15]
setPerp t=0.990234375 cPt=(38.7023939,38.6109956) == oppT=0.635851272 fPerpPt=(38.7023935,38.6109953)
setPerp t=0.9921875 cPt=(38.6933214,38.6201819) == oppT=0.708661403 fPerpPt=(38.6933211,38.6201816)
setPerp t=0.6875 cPt=(38.6959596,38.6175126) == oppT=0.991619875 fPerpPt=(38.6959599,38.6175129)
setPerp t=0.98828125 cPt=(38.7114485,38.601802) == oppT=0.563050975 fPerpPt=(38.711448,38.6018015)
setPerp t=0.990234375 cPt=(38.7023939,38.6109956) == oppT=0.635851272 fPerpPt=(38.7023935,38.6109953)
setPerp t=0.625 cPt=(38.7037442,38.6096255) == oppT=0.989943268 fPerpPt=(38.7037445,38.6096258)
setPerp t=0.9921875 cPt=(38.6933214,38.6201819) == oppT=0.708661403 fPerpPt=(38.6933211,38.6201816)
setPerp t=0.994140625 cPt=(38.684231,38.6293607) == oppT=0.781481354 fPerpPt=(38.6842309,38.6293605)
setPerp t=0.75 cPt=(38.6881628,38.6253934) == oppT=0.993296287 fPerpPt=(38.688163,38.6253936)
setPerp t=0.990234375 cPt=(38.7023939,38.6109956) == oppT=0.635851272 fPerpPt=(38.7023935,38.6109953)
setPerp t=0.9921875 cPt=(38.6933214,38.6201819) == oppT=0.708661403 fPerpPt=(38.6933211,38.6201816)
setPerp t=0.6875 cPt=(38.6959596,38.6175126) == oppT=0.991619875 fPerpPt=(38.6959599,38.6175129)
id=1 7=(0.75,0.875) [38,26,18] 15=(0.875,1) [40,26] id=2 18=(0.992188,0.994141) [7] 38=(0.994141,0.996094) [7] 26=(0.996094,0.998047) [15,7] 40=(0.998047,1) [15]
setPerp t=0.994140625 cPt=(38.684231,38.6293607) == oppT=0.781481354 fPerpPt=(38.6842309,38.6293605)
setPerp t=0.99609375 cPt=(38.6751228,38.6385321) == oppT=0.854311113 fPerpPt=(38.6751227,38.638532)
setPerp t=0.8125 cPt=(38.6803537,38.6332678) == oppT=0.994972505 fPerpPt=(38.6803538,38.6332679)
setPerp t=0.9921875 cPt=(38.6933214,38.6201819) == oppT=0.708661403 fPerpPt=(38.6933211,38.6201816)
setPerp t=0.994140625 cPt=(38.684231,38.6293607) == oppT=0.781481354 fPerpPt=(38.6842309,38.6293605)
setPerp t=0.75 cPt=(38.6881628,38.6253934) == oppT=0.993296287 fPerpPt=(38.688163,38.6253936)
setPerp t=0.99609375 cPt=(38.6751228,38.6385321) == oppT=0.854311113 fPerpPt=(38.6751227,38.638532)
setPerp t=0.998046875 cPt=(38.6659967,38.6476961) == oppT=0.927150666 fPerpPt=(38.6659967,38.6476961)
setPerp t=0.875 cPt=(38.6725323,38.6411358) == oppT=0.99664853 fPerpPt=(38.6725324,38.6411359)
setPerp t=0.994140625 cPt=(38.684231,38.6293607) == oppT=0.781481354 fPerpPt=(38.6842309,38.6293605)
setPerp t=0.99609375 cPt=(38.6751228,38.6385321) == oppT=0.854311113 fPerpPt=(38.6751227,38.638532)
setPerp t=0.8125 cPt=(38.6803537,38.6332678) == oppT=0.994972505 fPerpPt=(38.6803538,38.6332679)
id=1 15=(0.875,1) [40,26] id=2 26=(0.996094,0.998047) [15] 40=(0.998047,1) [15]
setPerp t=0.998046875 cPt=(38.6659967,38.6476961) == oppT=0.927150666 fPerpPt=(38.6659967,38.6476961)
setPerp t=1 cPt=(38.6568527,38.6568527) == oppT=1 fPerpPt=(38.6568527,38.6568527)
setPerp t=0.9375 cPt=(38.6646987,38.6489975) == oppT=0.998324361 fPerpPt=(38.6646987,38.6489975)
setPerp t=0.99609375 cPt=(38.6751228,38.6385321) == oppT=0.854311113 fPerpPt=(38.6751227,38.638532)
setPerp t=0.998046875 cPt=(38.6659967,38.6476961) == oppT=0.927150666 fPerpPt=(38.6659967,38.6476961)
setPerp t=0.875 cPt=(38.6725323,38.6411358) == oppT=0.99664853 fPerpPt=(38.6725324,38.6411359)
id=1 31=(0.9375,1) [40] id=2 40=(0.998047,1) [31]
setPerp t=0.9375 cPt=(38.6646987,38.6489975) == oppT=0.998324361 fPerpPt=(38.6646987,38.6489975)
setPerp t=1 cPt=(38.6568527,38.6568527) == oppT=1 fPerpPt=(38.6568527,38.6568527)
setPerp t=0.999023438 cPt=(38.6614269,38.6522753) == oppT=0.963574111 fPerpPt=(38.6614269,38.6522753)
id=1 31=(1,1) [42] id=2 42=(1,1) [31]
debugShowQuadIntersection wtTs[0]=1 {{{38.7809143,38.5304031}, {38.7196693,38.5940361}, {38.6568527,38.6568527}}} {{38.6568527,38.6568527}} wnTs[0]=1 {{{41,33}, {41,36.3137093}, {38.6568527,38.6568527}}}
debugShowQuadIntersection wtTs[0]=1 {{{38.7809143,38.5304031}, {38.7196693,38.5940361}, {38.6568527,38.6568527}}} {{38.6568527,38.6568527}} wnTs[0]=0 {{{38.6568527,38.6568527}, {36.3137093,41}, {33,41}}}
debugShowQuadIntersection wtTs[0]=0 {{{38.6568527,38.6568527}, {36.3137093,41}, {33,41}}} {{38.6568527,38.6568527}} wnTs[0]=1 {{{41,33}, {41,36.3137093}, {38.6568527,38.6568527}}}
id=1 1=(0,1) [4,2] id=2 2=(0,0.5) [1] 4=(0.5,1) [1]
id=1 1=(0,0.5) [4,2] 3=(0.5,1) [2,4] id=2 2=(0,0.5) [3,1] 4=(0.5,1) [3,1]
id=1 1=(0,0.5) [4,2] 3=(0.5,1) [6,2,4] id=2 2=(0,0.5) [3,1] 4=(0.5,0.75) [3,1] 6=(0.75,1) [3]
id=1 1=(0,0.5) [4,2] 3=(0.5,0.75) [6,2,4] 5=(0.75,1) [4,6] id=2 2=(0,0.5) [3,1] 4=(0.5,0.75) [5,3,1] 6=(0.75,1) [5,3]
id=1 1=(0,0.5) [8,4,2] 3=(0.5,0.75) [8,6,4] 5=(0.75,1) [4,6] id=2 2=(0,0.25) [1] 8=(0.25,0.5) [1,3] 4=(0.5,0.75) [5,3,1] 6=(0.75,1) [5,3]
id=1 1=(0,0.25) [8,2] 7=(0.25,0.5) [2,4,8] 3=(0.5,0.75) [8,6,4] 5=(0.75,1) [4,6] id=2 2=(0,0.25) [7,1] 8=(0.25,0.5) [7,1,3] 4=(0.5,0.75) [7,5,3] 6=(0.75,1) [5,3]
id=1 1=(0,0.25) [8,2] 7=(0.25,0.5) [2,4,8] 3=(0.5,0.75) [8,6,4] 5=(0.75,1) [10,4,6] id=2 2=(0,0.25) [7,1] 8=(0.25,0.5) [7,1,3] 4=(0.5,0.75) [7,5,3] 6=(0.75,0.875) [5,3] 10=(0.875,1) [5]
id=1 1=(0,0.25) [8,2] 7=(0.25,0.5) [2,4,8] 3=(0.5,0.75) [8,6,4] 5=(0.75,0.875) [10,4,6] 9=(0.875,1) [6,10] id=2 2=(0,0.25) [7,1] 8=(0.25,0.5) [7,1,3] 4=(0.5,0.75) [7,5,3] 6=(0.75,0.875) [9,5,3] 10=(0.875,1) [9,5]
id=1 1=(0,0.25) [8,2] 7=(0.25,0.5) [2,4,8] 3=(0.5,0.75) [12,8,6,4] 5=(0.75,0.875) [12,10,6] 9=(0.875,1) [6,10] id=2 2=(0,0.25) [7,1] 8=(0.25,0.5) [7,1,3] 4=(0.5,0.625) [7,3] 12=(0.625,0.75) [3,5] 6=(0.75,0.875) [9,5,3] 10=(0.875,1) [9,5]
id=1 1=(0,0.25) [8,2] 7=(0.25,0.5) [2,4,8] 3=(0.5,0.625) [12,8,4] 11=(0.625,0.75) [4,6,12] 5=(0.75,0.875) [12,10,6] 9=(0.875,1) [6,10] id=2 2=(0,0.25) [7,1] 8=(0.25,0.5) [7,1,3] 4=(0.5,0.625) [11,7,3] 12=(0.625,0.75) [11,3,5] 6=(0.75,0.875) [11,9,5] 10=(0.875,1) [9,5]
id=1 1=(0,0.25) [8,2] 7=(0.25,0.5) [14,2,4,8] 3=(0.5,0.625) [14,12,4] 11=(0.625,0.75) [4,6,12] 5=(0.75,0.875) [12,10,6] 9=(0.875,1) [6,10] id=2 2=(0,0.25) [7,1] 8=(0.25,0.375) [7,1] 14=(0.375,0.5) [3,7] 4=(0.5,0.625) [11,7,3] 12=(0.625,0.75) [11,3,5] 6=(0.75,0.875) [11,9,5] 10=(0.875,1) [9,5]
id=1 1=(0,0.25) [8,2] 7=(0.25,0.375) [14,2,8] 13=(0.375,0.5) [8,4,14] 3=(0.5,0.625) [14,12,4] 11=(0.625,0.75) [4,6,12] 5=(0.75,0.875) [12,10,6] 9=(0.875,1) [6,10] id=2 2=(0,0.25) [7,1] 8=(0.25,0.375) [13,7,1] 14=(0.375,0.5) [13,3,7] 4=(0.5,0.625) [13,11,3] 12=(0.625,0.75) [11,3,5] 6=(0.75,0.875) [11,9,5] 10=(0.875,1) [9,5]
id=1 1=(0,0.25) [16,8,2] 7=(0.25,0.375) [16,14,8] 13=(0.375,0.5) [8,4,14] 3=(0.5,0.625) [14,12,4] 11=(0.625,0.75) [4,6,12] 5=(0.75,0.875) [12,10,6] 9=(0.875,1) [6,10] id=2 2=(0,0.125) [1] 16=(0.125,0.25) [1,7] 8=(0.25,0.375) [13,7,1] 14=(0.375,0.5) [13,3,7] 4=(0.5,0.625) [13,11,3] 12=(0.625,0.75) [11,3,5] 6=(0.75,0.875) [11,9,5] 10=(0.875,1) [9,5]
id=1 1=(0,0.125) [16,2] 15=(0.125,0.25) [2,8,16] 7=(0.25,0.375) [16,14,8] 13=(0.375,0.5) [8,4,14] 3=(0.5,0.625) [14,12,4] 11=(0.625,0.75) [4,6,12] 5=(0.75,0.875) [12,10,6] 9=(0.875,1) [6,10] id=2 2=(0,0.125) [15,1] 16=(0.125,0.25) [15,1,7] 8=(0.25,0.375) [15,13,7] 14=(0.375,0.5) [13,3,7] 4=(0.5,0.625) [13,11,3] 12=(0.625,0.75) [11,3,5] 6=(0.75,0.875) [11,9,5] 10=(0.875,1) [9,5]
id=1 1=(0,0.125) [16,2] 15=(0.125,0.25) [2,8,16] 7=(0.25,0.375) [16,14,8] 13=(0.375,0.5) [8,4,14] 3=(0.5,0.625) [14,12,4] 11=(0.625,0.75) [4,6,12] 5=(0.75,0.875) [12,10,6] 9=(0.875,1) [18,6,10] id=2 2=(0,0.125) [15,1] 16=(0.125,0.25) [15,1,7] 8=(0.25,0.375) [15,13,7] 14=(0.375,0.5) [13,3,7] 4=(0.5,0.625) [13,11,3] 12=(0.625,0.75) [11,3,5] 6=(0.75,0.875) [11,9,5] 10=(0.875,0.9375) [9,5] 18=(0.9375,1) [9]
setPerp t=0 cPt=(38.6568527,38.6568527) == oppT=0 fPerpPt=(38.6568527,38.6568527)
setPerp t=0.125 cPt=(38.0559018,39.2060279) == oppT=0.125 fPerpPt=(38.0559018,39.2060279)
setPerp t=0.25 cPt=(37.4246206,39.6819797) == oppT=0.25 fPerpPt=(37.4246206,39.6819797)
setPerp t=0.375 cPt=(36.7630093,40.0847081) == oppT=0.375 fPerpPt=(36.7630093,40.0847081)
setPerp t=0.5 cPt=(36.0710678,40.4142132) == oppT=0.5 fPerpPt=(36.0710678,40.4142132)
setPerp t=0.625 cPt=(35.3487961,40.6704949) == oppT=0.625 fPerpPt=(35.3487961,40.6704949)
setPerp t=0.75 cPt=(34.5961943,40.8535533) == oppT=0.75 fPerpPt=(34.5961943,40.8535533)
setPerp t=0.875 cPt=(33.8132622,40.9633883) == oppT=0.875 fPerpPt=(33.8132622,40.9633883)
setPerp t=0.9375 cPt=(33.4104224,40.9908471) == oppT=0.9375 fPerpPt=(33.4104224,40.9908471)
setPerp t=1 cPt=(33,41) == oppT=1 fPerpPt=(33,41)
setPerp t=0 cPt=(38.6568527,38.6568527) == oppT=0 fPerpPt=(38.6568527,38.6568527)
setPerp t=1 cPt=(33,41) == oppT=1 fPerpPt=(33,41)
id=1 (empty) id=2 (empty)
debugShowQuadIntersection wtTs[0]=0 {{{38.6568527,38.6568527}, {36.3137093,41}, {33,41}}} {{38.6568527,38.6568527}} wtTs[1]=1 {{33,41}} wnTs[0]=0 {{{38.6568527,38.6568527}, {36.3137093,41}, {33,41}}} wnTs[1]=1
debugShowQuadIntersection wtTs[0]=1 {{{38.6568527,38.6568527}, {36.3137093,41}, {33,41}}} {{33,41}} wnTs[0]=0 {{{33,41}, {29.6862907,41}, {27.3431454,38.6568527}}}
debugShowQuadIntersection wtTs[0]=0 {{{33,41}, {29.6862907,41}, {27.3431454,38.6568527}}} {{33,41}} wnTs[0]=1 {{{38.6568527,38.6568527}, {36.3137093,41}, {33,41}}}
id=1 1=(0,1) [4,2] id=2 2=(0,0.5) [1] 4=(0.5,1) [1]
id=1 1=(0,0.5) [4,2] 3=(0.5,1) [2,4] id=2 2=(0,0.5) [3,1] 4=(0.5,1) [3,1]
id=1 1=(0,0.5) [6,4,2] 3=(0.5,1) [6,4] id=2 2=(0,0.25) [1] 6=(0.25,0.5) [1,3] 4=(0.5,1) [3,1]
id=1 1=(0,0.25) [6,2] 5=(0.25,0.5) [2,4,6] 3=(0.5,1) [6,4] id=2 2=(0,0.25) [5,1] 6=(0.25,0.5) [5,1,3] 4=(0.5,1) [5,3]
id=1 1=(0,0.25) [6,2] 5=(0.25,0.5) [2,4,6] 3=(0.5,1) [8,6,4] id=2 2=(0,0.25) [5,1] 6=(0.25,0.5) [5,1,3] 4=(0.5,0.75) [5,3] 8=(0.75,1) [3]
id=1 1=(0,0.25) [6,2] 5=(0.25,0.5) [2,4,6] 3=(0.5,0.75) [8,6,4] 7=(0.75,1) [4,8] id=2 2=(0,0.25) [5,1] 6=(0.25,0.5) [5,1,3] 4=(0.5,0.75) [7,5,3] 8=(0.75,1) [7,3]
id=1 1=(0,0.25) [10,6,2] 5=(0.25,0.5) [10,4,6] 3=(0.5,0.75) [8,6,4] 7=(0.75,1) [4,8] id=2 2=(0,0.125) [1] 10=(0.125,0.25) [1,5] 6=(0.25,0.5) [5,1,3] 4=(0.5,0.75) [7,5,3] 8=(0.75,1) [7,3]
id=1 1=(0,0.125) [10,2] 9=(0.125,0.25) [2,6,10] 5=(0.25,0.5) [10,4,6] 3=(0.5,0.75) [8,6,4] 7=(0.75,1) [4,8] id=2 2=(0,0.125) [9,1] 10=(0.125,0.25) [9,1,5] 6=(0.25,0.5) [9,5,3] 4=(0.5,0.75) [7,5,3] 8=(0.75,1) [7,3]
id=1 1=(0,0.125) [10,2] 9=(0.125,0.25) [2,6,10] 5=(0.25,0.5) [12,10,4,6] 3=(0.5,0.75) [12,8,4] 7=(0.75,1) [4,8] id=2 2=(0,0.125) [9,1] 10=(0.125,0.25) [9,1,5] 6=(0.25,0.375) [9,5] 12=(0.375,0.5) [3,5] 4=(0.5,0.75) [7,5,3] 8=(0.75,1) [7,3]
id=1 1=(0,0.125) [10,2] 9=(0.125,0.25) [2,6,10] 5=(0.25,0.375) [12,10,6] 11=(0.375,0.5) [6,4,12] 3=(0.5,0.75) [12,8,4] 7=(0.75,1) [4,8] id=2 2=(0,0.125) [9,1] 10=(0.125,0.25) [9,1,5] 6=(0.25,0.375) [11,9,5] 12=(0.375,0.5) [11,3,5] 4=(0.5,0.75) [11,7,3] 8=(0.75,1) [7,3]
id=1 1=(0,0.125) [10,2] 9=(0.125,0.25) [2,6,10] 5=(0.25,0.375) [12,10,6] 11=(0.375,0.5) [6,4,12] 3=(0.5,0.75) [14,12,8,4] 7=(0.75,1) [14,8] id=2 2=(0,0.125) [9,1] 10=(0.125,0.25) [9,1,5] 6=(0.25,0.375) [11,9,5] 12=(0.375,0.5) [11,3,5] 4=(0.5,0.625) [11,3] 14=(0.625,0.75) [3,7] 8=(0.75,1) [7,3]
id=1 1=(0,0.125) [10,2] 9=(0.125,0.25) [2,6,10] 5=(0.25,0.375) [12,10,6] 11=(0.375,0.5) [6,4,12] 3=(0.5,0.625) [14,12,4] 13=(0.625,0.75) [4,8,14] 7=(0.75,1) [14,8] id=2 2=(0,0.125) [9,1] 10=(0.125,0.25) [9,1,5] 6=(0.25,0.375) [11,9,5] 12=(0.375,0.5) [11,3,5] 4=(0.5,0.625) [13,11,3] 14=(0.625,0.75) [13,3,7] 8=(0.75,1) [13,7]
id=1 1=(0,0.125) [10,2] 9=(0.125,0.25) [2,6,10] 5=(0.25,0.375) [12,10,6] 11=(0.375,0.5) [6,4,12] 3=(0.5,0.625) [14,12,4] 13=(0.625,0.75) [4,8,14] 7=(0.75,1) [16,14,8] id=2 2=(0,0.125) [9,1] 10=(0.125,0.25) [9,1,5] 6=(0.25,0.375) [11,9,5] 12=(0.375,0.5) [11,3,5] 4=(0.5,0.625) [13,11,3] 14=(0.625,0.75) [13,3,7] 8=(0.75,0.875) [13,7] 16=(0.875,1) [7]
id=1 1=(0,0.125) [10,2] 9=(0.125,0.25) [2,6,10] 5=(0.25,0.375) [12,10,6] 11=(0.375,0.5) [6,4,12] 3=(0.5,0.625) [14,12,4] 13=(0.625,0.75) [4,8,14] 7=(0.75,0.875) [16,14,8] 15=(0.875,1) [8,16] id=2 2=(0,0.125) [9,1] 10=(0.125,0.25) [9,1,5] 6=(0.25,0.375) [11,9,5] 12=(0.375,0.5) [11,3,5] 4=(0.5,0.625) [13,11,3] 14=(0.625,0.75) [13,3,7] 8=(0.75,0.875) [15,13,7] 16=(0.875,1) [15,7]
id=1 1=(0,0.125) [18,10,2] 9=(0.125,0.25) [18,6,10] 5=(0.25,0.375) [12,10,6] 11=(0.375,0.5) [6,4,12] 3=(0.5,0.625) [14,12,4] 13=(0.625,0.75) [4,8,14] 7=(0.75,0.875) [16,14,8] 15=(0.875,1) [8,16] id=2 2=(0,0.0625) [1] 18=(0.0625,0.125) [1,9] 10=(0.125,0.25) [9,1,5] 6=(0.25,0.375) [11,9,5] 12=(0.375,0.5) [11,3,5] 4=(0.5,0.625) [13,11,3] 14=(0.625,0.75) [13,3,7] 8=(0.75,0.875) [15,13,7] 16=(0.875,1) [15,7]
setPerp t=0 cPt=(33,41) == oppT=0 fPerpPt=(33,41)
setPerp t=0.0625 cPt=(32.5895776,40.9908471) == oppT=0.0625 fPerpPt=(32.5895776,40.9908471)
setPerp t=0.125 cPt=(32.1867377,40.9633883) == oppT=0.125 fPerpPt=(32.1867377,40.9633883)
setPerp t=0.25 cPt=(31.4038056,40.8535533) == oppT=0.25 fPerpPt=(31.4038056,40.8535533)
setPerp t=0.375 cPt=(30.6512036,40.6704949) == oppT=0.375 fPerpPt=(30.6512036,40.6704949)
setPerp t=0.5 cPt=(29.9289317,40.4142132) == oppT=0.5 fPerpPt=(29.9289317,40.4142132)
setPerp t=0.625 cPt=(29.2369899,40.0847081) == oppT=0.625 fPerpPt=(29.2369899,40.0847081)
setPerp t=0.75 cPt=(28.5753783,39.6819797) == oppT=0.75 fPerpPt=(28.5753783,39.6819797)
setPerp t=0.875 cPt=(27.9440968,39.2060279) == oppT=0.875 fPerpPt=(27.9440968,39.2060279)
setPerp t=1 cPt=(27.3431454,38.6568527) == oppT=1 fPerpPt=(27.3431454,38.6568527)
setPerp t=0 cPt=(33,41) == oppT=0 fPerpPt=(33,41)
setPerp t=1 cPt=(27.3431454,38.6568527) == oppT=1 fPerpPt=(27.3431454,38.6568527)
id=1 (empty) id=2 (empty)
debugShowQuadIntersection wtTs[0]=0 {{{33,41}, {29.6862907,41}, {27.3431454,38.6568527}}} {{33,41}} wtTs[1]=1 {{27.3431454,38.6568527}} wnTs[0]=0 {{{33,41}, {29.6862907,41}, {27.3431454,38.6568527}}} wnTs[1]=1
debugShowQuadIntersection wtTs[0]=1 {{{33,41}, {29.6862907,41}, {27.3431454,38.6568527}}} {{27.3431454,38.6568527}} wnTs[0]=0 {{{27.3431454,38.6568527}, {25,36.3137093}, {25,33}}}
debugShowQuadIntersection wtTs[0]=0 {{{27.3431454,38.6568527}, {25,36.3137093}, {25,33}}} {{27.3431454,38.6568527}} wnTs[0]=1 {{{33,41}, {29.6862907,41}, {27.3431454,38.6568527}}}
id=1 1=(0,1) [4,2] id=2 2=(0,0.5) [1] 4=(0.5,1) [1]
id=1 1=(0,0.5) [4,2] 3=(0.5,1) [2,4] id=2 2=(0,0.5) [3,1] 4=(0.5,1) [3,1]
id=1 1=(0,0.5) [4,2] 3=(0.5,1) [6,2,4] id=2 2=(0,0.5) [3,1] 4=(0.5,0.75) [3,1] 6=(0.75,1) [3]
id=1 1=(0,0.5) [4,2] 3=(0.5,0.75) [6,2,4] 5=(0.75,1) [4,6] id=2 2=(0,0.5) [3,1] 4=(0.5,0.75) [5,3,1] 6=(0.75,1) [5,3]
id=1 1=(0,0.5) [8,4,2] 3=(0.5,0.75) [8,6,4] 5=(0.75,1) [4,6] id=2 2=(0,0.25) [1] 8=(0.25,0.5) [1,3] 4=(0.5,0.75) [5,3,1] 6=(0.75,1) [5,3]
id=1 1=(0,0.25) [8,2] 7=(0.25,0.5) [2,4,8] 3=(0.5,0.75) [8,6,4] 5=(0.75,1) [4,6] id=2 2=(0,0.25) [7,1] 8=(0.25,0.5) [7,1,3] 4=(0.5,0.75) [7,5,3] 6=(0.75,1) [5,3]
id=1 1=(0,0.25) [8,2] 7=(0.25,0.5) [2,4,8] 3=(0.5,0.75) [8,6,4] 5=(0.75,1) [10,4,6] id=2 2=(0,0.25) [7,1] 8=(0.25,0.5) [7,1,3] 4=(0.5,0.75) [7,5,3] 6=(0.75,0.875) [5,3] 10=(0.875,1) [5]
id=1 1=(0,0.25) [8,2] 7=(0.25,0.5) [2,4,8] 3=(0.5,0.75) [8,6,4] 5=(0.75,0.875) [10,4,6] 9=(0.875,1) [6,10] id=2 2=(0,0.25) [7,1] 8=(0.25,0.5) [7,1,3] 4=(0.5,0.75) [7,5,3] 6=(0.75,0.875) [9,5,3] 10=(0.875,1) [9,5]
id=1 1=(0,0.25) [8,2] 7=(0.25,0.5) [2,4,8] 3=(0.5,0.75) [12,8,6,4] 5=(0.75,0.875) [12,10,6] 9=(0.875,1) [6,10] id=2 2=(0,0.25) [7,1] 8=(0.25,0.5) [7,1,3] 4=(0.5,0.625) [7,3] 12=(0.625,0.75) [3,5] 6=(0.75,0.875) [9,5,3] 10=(0.875,1) [9,5]
id=1 1=(0,0.25) [8,2] 7=(0.25,0.5) [2,4,8] 3=(0.5,0.625) [12,8,4] 11=(0.625,0.75) [4,6,12] 5=(0.75,0.875) [12,10,6] 9=(0.875,1) [6,10] id=2 2=(0,0.25) [7,1] 8=(0.25,0.5) [7,1,3] 4=(0.5,0.625) [11,7,3] 12=(0.625,0.75) [11,3,5] 6=(0.75,0.875) [11,9,5] 10=(0.875,1) [9,5]
id=1 1=(0,0.25) [8,2] 7=(0.25,0.5) [14,2,4,8] 3=(0.5,0.625) [14,12,4] 11=(0.625,0.75) [4,6,12] 5=(0.75,0.875) [12,10,6] 9=(0.875,1) [6,10] id=2 2=(0,0.25) [7,1] 8=(0.25,0.375) [7,1] 14=(0.375,0.5) [3,7] 4=(0.5,0.625) [11,7,3] 12=(0.625,0.75) [11,3,5] 6=(0.75,0.875) [11,9,5] 10=(0.875,1) [9,5]
id=1 1=(0,0.25) [8,2] 7=(0.25,0.375) [14,2,8] 13=(0.375,0.5) [8,4,14] 3=(0.5,0.625) [14,12,4] 11=(0.625,0.75) [4,6,12] 5=(0.75,0.875) [12,10,6] 9=(0.875,1) [6,10] id=2 2=(0,0.25) [7,1] 8=(0.25,0.375) [13,7,1] 14=(0.375,0.5) [13,3,7] 4=(0.5,0.625) [13,11,3] 12=(0.625,0.75) [11,3,5] 6=(0.75,0.875) [11,9,5] 10=(0.875,1) [9,5]
id=1 1=(0,0.25) [16,8,2] 7=(0.25,0.375) [16,14,8] 13=(0.375,0.5) [8,4,14] 3=(0.5,0.625) [14,12,4] 11=(0.625,0.75) [4,6,12] 5=(0.75,0.875) [12,10,6] 9=(0.875,1) [6,10] id=2 2=(0,0.125) [1] 16=(0.125,0.25) [1,7] 8=(0.25,0.375) [13,7,1] 14=(0.375,0.5) [13,3,7] 4=(0.5,0.625) [13,11,3] 12=(0.625,0.75) [11,3,5] 6=(0.75,0.875) [11,9,5] 10=(0.875,1) [9,5]
id=1 1=(0,0.125) [16,2] 15=(0.125,0.25) [2,8,16] 7=(0.25,0.375) [16,14,8] 13=(0.375,0.5) [8,4,14] 3=(0.5,0.625) [14,12,4] 11=(0.625,0.75) [4,6,12] 5=(0.75,0.875) [12,10,6] 9=(0.875,1) [6,10] id=2 2=(0,0.125) [15,1] 16=(0.125,0.25) [15,1,7] 8=(0.25,0.375) [15,13,7] 14=(0.375,0.5) [13,3,7] 4=(0.5,0.625) [13,11,3] 12=(0.625,0.75) [11,3,5] 6=(0.75,0.875) [11,9,5] 10=(0.875,1) [9,5]
id=1 1=(0,0.125) [16,2] 15=(0.125,0.25) [2,8,16] 7=(0.25,0.375) [16,14,8] 13=(0.375,0.5) [8,4,14] 3=(0.5,0.625) [14,12,4] 11=(0.625,0.75) [4,6,12] 5=(0.75,0.875) [12,10,6] 9=(0.875,1) [18,6,10] id=2 2=(0,0.125) [15,1] 16=(0.125,0.25) [15,1,7] 8=(0.25,0.375) [15,13,7] 14=(0.375,0.5) [13,3,7] 4=(0.5,0.625) [13,11,3] 12=(0.625,0.75) [11,3,5] 6=(0.75,0.875) [11,9,5] 10=(0.875,0.9375) [9,5] 18=(0.9375,1) [9]
setPerp t=0 cPt=(27.3431454,38.6568527) == oppT=0 fPerpPt=(27.3431454,38.6568527)
setPerp t=0.125 cPt=(26.7939707,38.0559018) == oppT=0.125 fPerpPt=(26.7939707,38.0559018)
setPerp t=0.25 cPt=(26.3180193,37.4246206) == oppT=0.25 fPerpPt=(26.3180193,37.4246206)
setPerp t=0.375 cPt=(25.9152912,36.7630093) == oppT=0.375 fPerpPt=(25.9152912,36.7630093)
setPerp t=0.5 cPt=(25.5857863,36.0710678) == oppT=0.5 fPerpPt=(25.5857863,36.0710678)
setPerp t=0.625 cPt=(25.3295048,35.3487961) == oppT=0.625 fPerpPt=(25.3295048,35.3487961)
setPerp t=0.75 cPt=(25.1464466,34.5961943) == oppT=0.75 fPerpPt=(25.1464466,34.5961943)
setPerp t=0.875 cPt=(25.0366116,33.8132622) == oppT=0.875 fPerpPt=(25.0366116,33.8132622)
setPerp t=0.9375 cPt=(25.0091529,33.4104224) == oppT=0.9375 fPerpPt=(25.0091529,33.4104224)
setPerp t=1 cPt=(25,33) == oppT=1 fPerpPt=(25,33)
setPerp t=0 cPt=(27.3431454,38.6568527) == oppT=0 fPerpPt=(27.3431454,38.6568527)
setPerp t=1 cPt=(25,33) == oppT=1 fPerpPt=(25,33)
id=1 (empty) id=2 (empty)
debugShowQuadIntersection wtTs[0]=0 {{{27.3431454,38.6568527}, {25,36.3137093}, {25,33}}} {{27.3431454,38.6568527}} wtTs[1]=1 {{25,33}} wnTs[0]=0 {{{27.3431454,38.6568527}, {25,36.3137093}, {25,33}}} wnTs[1]=1
debugShowQuadIntersection wtTs[0]=1 {{{27.3431454,38.6568527}, {25,36.3137093}, {25,33}}} {{25,33}} wnTs[0]=0 {{{25,33}, {25,29.6862907}, {27.3431454,27.3431454}}}
debugShowQuadIntersection wtTs[0]=0 {{{25,33}, {25,29.6862907}, {27.3431454,27.3431454}}} {{25,33}} wnTs[0]=1 {{{27.3431454,38.6568527}, {25,36.3137093}, {25,33}}}
id=1 1=(0,1) [4,2] id=2 2=(0,0.5) [1] 4=(0.5,1) [1]
id=1 1=(0,0.5) [4,2] 3=(0.5,1) [2,4] id=2 2=(0,0.5) [3,1] 4=(0.5,1) [3,1]
id=1 1=(0,0.5) [6,4,2] 3=(0.5,1) [6,4] id=2 2=(0,0.25) [1] 6=(0.25,0.5) [1,3] 4=(0.5,1) [3,1]
id=1 1=(0,0.25) [6,2] 5=(0.25,0.5) [2,4,6] 3=(0.5,1) [6,4] id=2 2=(0,0.25) [5,1] 6=(0.25,0.5) [5,1,3] 4=(0.5,1) [5,3]
id=1 1=(0,0.25) [6,2] 5=(0.25,0.5) [2,4,6] 3=(0.5,1) [8,6,4] id=2 2=(0,0.25) [5,1] 6=(0.25,0.5) [5,1,3] 4=(0.5,0.75) [5,3] 8=(0.75,1) [3]
id=1 1=(0,0.25) [6,2] 5=(0.25,0.5) [2,4,6] 3=(0.5,0.75) [8,6,4] 7=(0.75,1) [4,8] id=2 2=(0,0.25) [5,1] 6=(0.25,0.5) [5,1,3] 4=(0.5,0.75) [7,5,3] 8=(0.75,1) [7,3]
id=1 1=(0,0.25) [10,6,2] 5=(0.25,0.5) [10,4,6] 3=(0.5,0.75) [8,6,4] 7=(0.75,1) [4,8] id=2 2=(0,0.125) [1] 10=(0.125,0.25) [1,5] 6=(0.25,0.5) [5,1,3] 4=(0.5,0.75) [7,5,3] 8=(0.75,1) [7,3]
id=1 1=(0,0.125) [10,2] 9=(0.125,0.25) [2,6,10] 5=(0.25,0.5) [10,4,6] 3=(0.5,0.75) [8,6,4] 7=(0.75,1) [4,8] id=2 2=(0,0.125) [9,1] 10=(0.125,0.25) [9,1,5] 6=(0.25,0.5) [9,5,3] 4=(0.5,0.75) [7,5,3] 8=(0.75,1) [7,3]
id=1 1=(0,0.125) [10,2] 9=(0.125,0.25) [2,6,10] 5=(0.25,0.5) [12,10,4,6] 3=(0.5,0.75) [12,8,4] 7=(0.75,1) [4,8] id=2 2=(0,0.125) [9,1] 10=(0.125,0.25) [9,1,5] 6=(0.25,0.375) [9,5] 12=(0.375,0.5) [3,5] 4=(0.5,0.75) [7,5,3] 8=(0.75,1) [7,3]
id=1 1=(0,0.125) [10,2] 9=(0.125,0.25) [2,6,10] 5=(0.25,0.375) [12,10,6] 11=(0.375,0.5) [6,4,12] 3=(0.5,0.75) [12,8,4] 7=(0.75,1) [4,8] id=2 2=(0,0.125) [9,1] 10=(0.125,0.25) [9,1,5] 6=(0.25,0.375) [11,9,5] 12=(0.375,0.5) [11,3,5] 4=(0.5,0.75) [11,7,3] 8=(0.75,1) [7,3]
id=1 1=(0,0.125) [10,2] 9=(0.125,0.25) [2,6,10] 5=(0.25,0.375) [12,10,6] 11=(0.375,0.5) [6,4,12] 3=(0.5,0.75) [14,12,8,4] 7=(0.75,1) [14,8] id=2 2=(0,0.125) [9,1] 10=(0.125,0.25) [9,1,5] 6=(0.25,0.375) [11,9,5] 12=(0.375,0.5) [11,3,5] 4=(0.5,0.625) [11,3] 14=(0.625,0.75) [3,7] 8=(0.75,1) [7,3]
id=1 1=(0,0.125) [10,2] 9=(0.125,0.25) [2,6,10] 5=(0.25,0.375) [12,10,6] 11=(0.375,0.5) [6,4,12] 3=(0.5,0.625) [14,12,4] 13=(0.625,0.75) [4,8,14] 7=(0.75,1) [14,8] id=2 2=(0,0.125) [9,1] 10=(0.125,0.25) [9,1,5] 6=(0.25,0.375) [11,9,5] 12=(0.375,0.5) [11,3,5] 4=(0.5,0.625) [13,11,3] 14=(0.625,0.75) [13,3,7] 8=(0.75,1) [13,7]
id=1 1=(0,0.125) [10,2] 9=(0.125,0.25) [2,6,10] 5=(0.25,0.375) [12,10,6] 11=(0.375,0.5) [6,4,12] 3=(0.5,0.625) [14,12,4] 13=(0.625,0.75) [4,8,14] 7=(0.75,1) [16,14,8] id=2 2=(0,0.125) [9,1] 10=(0.125,0.25) [9,1,5] 6=(0.25,0.375) [11,9,5] 12=(0.375,0.5) [11,3,5] 4=(0.5,0.625) [13,11,3] 14=(0.625,0.75) [13,3,7] 8=(0.75,0.875) [13,7] 16=(0.875,1) [7]
id=1 1=(0,0.125) [10,2] 9=(0.125,0.25) [2,6,10] 5=(0.25,0.375) [12,10,6] 11=(0.375,0.5) [6,4,12] 3=(0.5,0.625) [14,12,4] 13=(0.625,0.75) [4,8,14] 7=(0.75,0.875) [16,14,8] 15=(0.875,1) [8,16] id=2 2=(0,0.125) [9,1] 10=(0.125,0.25) [9,1,5] 6=(0.25,0.375) [11,9,5] 12=(0.375,0.5) [11,3,5] 4=(0.5,0.625) [13,11,3] 14=(0.625,0.75) [13,3,7] 8=(0.75,0.875) [15,13,7] 16=(0.875,1) [15,7]
id=1 1=(0,0.125) [18,10,2] 9=(0.125,0.25) [18,6,10] 5=(0.25,0.375) [12,10,6] 11=(0.375,0.5) [6,4,12] 3=(0.5,0.625) [14,12,4] 13=(0.625,0.75) [4,8,14] 7=(0.75,0.875) [16,14,8] 15=(0.875,1) [8,16] id=2 2=(0,0.0625) [1] 18=(0.0625,0.125) [1,9] 10=(0.125,0.25) [9,1,5] 6=(0.25,0.375) [11,9,5] 12=(0.375,0.5) [11,3,5] 4=(0.5,0.625) [13,11,3] 14=(0.625,0.75) [13,3,7] 8=(0.75,0.875) [15,13,7] 16=(0.875,1) [15,7]
setPerp t=0 cPt=(25,33) == oppT=0 fPerpPt=(25,33)
setPerp t=0.0625 cPt=(25.0091529,32.5895776) == oppT=0.0625 fPerpPt=(25.0091529,32.5895776)
setPerp t=0.125 cPt=(25.0366116,32.1867377) == oppT=0.125 fPerpPt=(25.0366116,32.1867377)
setPerp t=0.25 cPt=(25.1464466,31.4038056) == oppT=0.25 fPerpPt=(25.1464466,31.4038056)
setPerp t=0.375 cPt=(25.3295048,30.6512036) == oppT=0.375 fPerpPt=(25.3295048,30.6512036)
setPerp t=0.5 cPt=(25.5857863,29.9289317) == oppT=0.5 fPerpPt=(25.5857863,29.9289317)
setPerp t=0.625 cPt=(25.9152912,29.2369899) == oppT=0.625 fPerpPt=(25.9152912,29.2369899)
setPerp t=0.75 cPt=(26.3180193,28.5753783) == oppT=0.75 fPerpPt=(26.3180193,28.5753783)
setPerp t=0.875 cPt=(26.7939707,27.9440968) == oppT=0.875 fPerpPt=(26.7939707,27.9440968)
setPerp t=1 cPt=(27.3431454,27.3431454) == oppT=1 fPerpPt=(27.3431454,27.3431454)
setPerp t=0 cPt=(25,33) == oppT=0 fPerpPt=(25,33)
setPerp t=1 cPt=(27.3431454,27.3431454) == oppT=1 fPerpPt=(27.3431454,27.3431454)
id=1 (empty) id=2 (empty)
debugShowQuadIntersection wtTs[0]=0 {{{25,33}, {25,29.6862907}, {27.3431454,27.3431454}}} {{25,33}} wtTs[1]=1 {{27.3431454,27.3431454}} wnTs[0]=0 {{{25,33}, {25,29.6862907}, {27.3431454,27.3431454}}} wnTs[1]=1
debugShowQuadIntersection wtTs[0]=1 {{{25,33}, {25,29.6862907}, {27.3431454,27.3431454}}} {{27.3431454,27.3431454}} wnTs[0]=0 {{{27.3431454,27.3431454}, {29.6862907,25}, {33,25}}}
debugShowQuadIntersection wtTs[0]=0 {{{27.3431454,27.3431454}, {27.3875446,27.2987461}, {27.4323025,27.2551785}}} {{27.3431454,27.3431454}} wnTs[0]=1 {{{25,33}, {25,29.6862907}, {27.3431454,27.3431454}}}
id=1 1=(0,1) [2] id=2 2=(0,0.5) [1]
id=1 1=(0,1) [2] id=2 2=(0,0.25) [1]
id=1 1=(0,1) [2] id=2 2=(0,0.125) [1]
id=1 1=(0,1) [2] id=2 2=(0,0.0625) [1]
id=1 1=(0,1) [2] id=2 2=(0,0.03125) [1]
id=1 1=(0,1) [14,2] id=2 2=(0,0.015625) [1] 14=(0.015625,0.03125) [1]
id=1 1=(0,0.5) [2] 3=(0.5,1) [2,14] id=2 2=(0,0.015625) [3,1] 14=(0.015625,0.03125) [3]
id=1 1=(0,0.5) [2] 3=(0.5,1) [2,14] id=2 2=(0,0.015625) [3,1] 14=(0.015625,0.0234375) [3]
id=1 1=(0,0.5) [18,2] 3=(0.5,1) [18,14] id=2 2=(0,0.0078125) [1] 18=(0.0078125,0.015625) [1,3] 14=(0.015625,0.0234375) [3]
id=1 1=(0,0.5) [18,2] 3=(0.5,0.75) [18] 5=(0.75,1) [14,18] id=2 2=(0,0.0078125) [1] 18=(0.0078125,0.015625) [5,1,3] 14=(0.015625,0.0234375) [5]
id=1 1=(0,0.25) [2] 7=(0.25,0.5) [2,18] 3=(0.5,0.75) [18] 5=(0.75,1) [14,18] id=2 2=(0,0.0078125) [7,1] 18=(0.0078125,0.015625) [7,5,3] 14=(0.015625,0.0234375) [5]
id=1 1=(0,0.25) [2] 7=(0.25,0.5) [2,18] 3=(0.5,0.75) [18] 5=(0.75,1) [14,18] id=2 2=(0,0.0078125) [7,1] 18=(0.0078125,0.015625) [7,5,3] 14=(0.015625,0.0195313) [5]
id=1 1=(0,0.25) [2] 7=(0.25,0.5) [2,18] 3=(0.5,0.75) [22,18] 5=(0.75,1) [22,14] id=2 2=(0,0.0078125) [7,1] 18=(0.0078125,0.0117188) [7,3] 22=(0.0117188,0.015625) [3,5] 14=(0.015625,0.0195313) [5]
id=1 1=(0,0.25) [24,2] 7=(0.25,0.5) [24,18] 3=(0.5,0.75) [22,18] 5=(0.75,1) [22,14] id=2 2=(0,0.00390625) [1] 24=(0.00390625,0.0078125) [1,7] 18=(0.0078125,0.0117188) [7,3] 22=(0.0117188,0.015625) [3,5] 14=(0.015625,0.0195313) [5]
id=1 1=(0,0.25) [24,2] 7=(0.25,0.5) [24,18] 3=(0.5,0.75) [22,18] 5=(0.75,0.875) [22,14] 9=(0.875,1) [14] id=2 2=(0,0.00390625) [1] 24=(0.00390625,0.0078125) [1,7] 18=(0.0078125,0.0117188) [7,3] 22=(0.0117188,0.015625) [3,5] 14=(0.015625,0.0195313) [9,5]
id=1 1=(0,0.25) [24,2] 7=(0.25,0.5) [24,18] 3=(0.5,0.625) [22,18] 11=(0.625,0.75) [22] 5=(0.75,0.875) [22,14] 9=(0.875,1) [14] id=2 2=(0,0.00390625) [1] 24=(0.00390625,0.0078125) [1,7] 18=(0.0078125,0.0117188) [7,3] 22=(0.0117188,0.015625) [11,3,5] 14=(0.015625,0.0195313) [9,5]
id=1 1=(0,0.25) [24,2] 7=(0.25,0.375) [24] 13=(0.375,0.5) [18,24] 3=(0.5,0.625) [22,18] 11=(0.625,0.75) [22] 5=(0.75,0.875) [22,14] 9=(0.875,1) [14] id=2 2=(0,0.00390625) [1] 24=(0.00390625,0.0078125) [13,1,7] 18=(0.0078125,0.0117188) [13,3] 22=(0.0117188,0.015625) [11,3,5] 14=(0.015625,0.0195313) [9,5]
id=1 1=(0,0.125) [2] 15=(0.125,0.25) [2,24] 7=(0.25,0.375) [24] 13=(0.375,0.5) [18,24] 3=(0.5,0.625) [22,18] 11=(0.625,0.75) [22] 5=(0.75,0.875) [22,14] 9=(0.875,1) [14] id=2 2=(0,0.00390625) [15,1] 24=(0.00390625,0.0078125) [15,13,7] 18=(0.0078125,0.0117188) [13,3] 22=(0.0117188,0.015625) [11,3,5] 14=(0.015625,0.0195313) [9,5]
setPerp t=0.875 cPt=(27.4211186,27.2660834) == oppT=0.0165816271 fPerpPt=(27.4211186,27.2660833)
setPerp t=1 cPt=(27.4323025,27.2551785) == oppT=0.0189506978 fPerpPt=(27.4323024,27.2551784)
setPerp t=0.017578125 cPt=(27.4258215,27.2614932) == oppT=0.927578956 fPerpPt=(27.4258215,27.2614932)
setPerp t=0.75 cPt=(27.409946,27.2770143) == oppT=0.0142126233 fPerpPt=(27.4099459,27.2770142)
setPerp t=0.875 cPt=(27.4211186,27.2660834) == oppT=0.0165816271 fPerpPt=(27.4211186,27.2660833)
setPerp t=0.015625 cPt=(27.4166056,27.2704941) == oppT=0.824524193 fPerpPt=(27.4166057,27.2704942)
setPerp t=0.875 cPt=(27.4211186,27.2660834) == oppT=0.0165816271 fPerpPt=(27.4211186,27.2660833)
setPerp t=1 cPt=(27.4323025,27.2551785) == oppT=0.0189506978 fPerpPt=(27.4323024,27.2551784)
setPerp t=0.017578125 cPt=(27.4258215,27.2614932) == oppT=0.927578956 fPerpPt=(27.4258215,27.2614932)
id=1 1=(0,0.125) [2] 15=(0.125,0.25) [2,24] 7=(0.25,0.375) [24] 13=(0.375,0.5) [18,24] 3=(0.5,0.625) [22,18] 11=(0.625,0.75) [22] 5=(0.75,0.875) [22] id=2 2=(0,0.00390625) [15,1] 24=(0.00390625,0.0078125) [15,13,7] 18=(0.0078125,0.0117188) [13,3] 22=(0.0117188,0.015625) [11,3,5]
setPerp t=0.625 cPt=(27.3987845,27.2879711) == oppT=0.0118436864 fPerpPt=(27.3987845,27.2879711)
setPerp t=0.75 cPt=(27.409946,27.2770143) == oppT=0.0142126233 fPerpPt=(27.4099459,27.2770142)
setPerp t=0.013671875 cPt=(27.4073972,27.279513) == oppT=0.721467031 fPerpPt=(27.4073972,27.279513)
setPerp t=0.5 cPt=(27.3876343,27.298954) == oppT=0.00947481625 fPerpPt=(27.3876342,27.298954)
setPerp t=0.625 cPt=(27.3987845,27.2879711) == oppT=0.0118436864 fPerpPt=(27.3987845,27.2879711)
setPerp t=0.01171875 cPt=(27.3981961,27.2885497) == oppT=0.618407471 fPerpPt=(27.3981962,27.2885497)
setPerp t=0.75 cPt=(27.409946,27.2770143) == oppT=0.0142126233 fPerpPt=(27.4099459,27.2770142)
setPerp t=0.875 cPt=(27.4211186,27.2660834) == oppT=0.0165816271 fPerpPt=(27.4211186,27.2660833)
setPerp t=0.015625 cPt=(27.4166056,27.2704941) == oppT=0.824524193 fPerpPt=(27.4166057,27.2704942)
setPerp t=0.625 cPt=(27.3987845,27.2879711) == oppT=0.0118436864 fPerpPt=(27.3987845,27.2879711)
setPerp t=0.75 cPt=(27.409946,27.2770143) == oppT=0.0142126233 fPerpPt=(27.4099459,27.2770142)
setPerp t=0.013671875 cPt=(27.4073972,27.279513) == oppT=0.721467031 fPerpPt=(27.4073972,27.279513)
id=1 1=(0,0.125) [2] 15=(0.125,0.25) [2,24] 7=(0.25,0.375) [24] 13=(0.375,0.5) [18,24] 3=(0.5,0.625) [18] id=2 2=(0,0.00390625) [15,1] 24=(0.00390625,0.0078125) [15,13,7] 18=(0.0078125,0.0117188) [13,3]
setPerp t=0.375 cPt=(27.3764952,27.3099629) == oppT=0.00710601267 fPerpPt=(27.3764952,27.3099628)
setPerp t=0.5 cPt=(27.3876343,27.298954) == oppT=0.00947481625 fPerpPt=(27.3876342,27.298954)
setPerp t=0.0078125 cPt=(27.3798163,27.3066767) == oppT=0.412281177 fPerpPt=(27.3798163,27.3066768)
setPerp t=0.5 cPt=(27.3876343,27.298954) == oppT=0.00947481625 fPerpPt=(27.3876342,27.298954)
setPerp t=0.625 cPt=(27.3987845,27.2879711) == oppT=0.0118436864 fPerpPt=(27.3987845,27.2879711)
setPerp t=0.009765625 cPt=(27.3890025,27.2976043) == oppT=0.515345519 fPerpPt=(27.3890025,27.2976043)
setPerp t=0.5 cPt=(27.3876343,27.298954) == oppT=0.00947481625 fPerpPt=(27.3876342,27.298954)
setPerp t=0.625 cPt=(27.3987845,27.2879711) == oppT=0.0118436864 fPerpPt=(27.3987845,27.2879711)
setPerp t=0.009765625 cPt=(27.3890025,27.2976043) == oppT=0.515345519 fPerpPt=(27.3890025,27.2976043)
setPerp t=0.01171875 cPt=(27.3981961,27.2885497) == oppT=0.618407471 fPerpPt=(27.3981962,27.2885497)
id=1 1=(0,0.125) [2] 15=(0.125,0.25) [2,24] 7=(0.25,0.375) [24] 13=(0.375,0.5) [24] id=2 2=(0,0.00390625) [15,1] 24=(0.00390625,0.0078125) [15,13,7]
setPerp t=0.125 cPt=(27.3542508,27.3320585) == oppT=0.00236860468 fPerpPt=(27.3542508,27.3320585)
setPerp t=0.25 cPt=(27.3653674,27.3209977) == oppT=0.00473727552 fPerpPt=(27.3653674,27.3209977)
setPerp t=0.00390625 cPt=(27.361466,27.3248753) == oppT=0.206145343 fPerpPt=(27.361466,27.3248753)
setPerp t=0.25 cPt=(27.3653674,27.3209977) == oppT=0.00473727552 fPerpPt=(27.3653674,27.3209977)
setPerp t=0.375 cPt=(27.3764952,27.3099629) == oppT=0.00710601267 fPerpPt=(27.3764952,27.3099628)
setPerp t=0.005859375 cPt=(27.3706374,27.3157671) == oppT=0.309214451 fPerpPt=(27.3706374,27.3157671)
setPerp t=0.25 cPt=(27.3653674,27.3209977) == oppT=0.00473727552 fPerpPt=(27.3653674,27.3209977)
setPerp t=0.375 cPt=(27.3764952,27.3099629) == oppT=0.00710601267 fPerpPt=(27.3764952,27.3099628)
setPerp t=0.005859375 cPt=(27.3706374,27.3157671) == oppT=0.309214451 fPerpPt=(27.3706374,27.3157671)
setPerp t=0.375 cPt=(27.3764952,27.3099629) == oppT=0.00710601267 fPerpPt=(27.3764952,27.3099628)
setPerp t=0.5 cPt=(27.3876343,27.298954) == oppT=0.00947481625 fPerpPt=(27.3876342,27.298954)
setPerp t=0.0078125 cPt=(27.3798163,27.3066767) == oppT=0.412281177 fPerpPt=(27.3798163,27.3066768)
id=1 1=(0,0.125) [2] 15=(0.125,0.25) [2] id=2 2=(0,0.00390625) [15,1]
setPerp t=0.125 cPt=(27.3542508,27.3320585) == oppT=0.00236860468 fPerpPt=(27.3542508,27.3320585)
setPerp t=0.25 cPt=(27.3653674,27.3209977) == oppT=0.00473727552 fPerpPt=(27.3653674,27.3209977)
setPerp t=0.00390625 cPt=(27.361466,27.3248753) == oppT=0.206145343 fPerpPt=(27.361466,27.3248753)
id=1 1=(0,0.125) [34,2] id=2 2=(0,0.00195313) [1] 34=(0.00195313,0.00390625) [1]
id=1 1=(0,0.0625) [2] 17=(0.0625,0.125) [2,34] id=2 2=(0,0.00195313) [17,1] 34=(0.00195313,0.00390625) [17]
id=1 1=(0,0.0625) [2] 17=(0.0625,0.125) [2,34] id=2 2=(0,0.00195313) [17,1] 34=(0.00195313,0.00292969) [17]
id=1 1=(0,0.0625) [38,2] 17=(0.0625,0.125) [38,34] id=2 2=(0,0.000976563) [1] 38=(0.000976563,0.00195313) [1,17] 34=(0.00195313,0.00292969) [17]
setPerp t=0.001953125 cPt=(27.352302,27.3340014) == oppT=0.103073858 fPerpPt=(27.352302,27.3340014)
setPerp t=0.0029296875 cPt=(27.3568831,27.3294361) == oppT=0.154609898 fPerpPt=(27.3568831,27.3294361)
setPerp t=0.125 cPt=(27.3542508,27.3320585) == oppT=0.00236860468 fPerpPt=(27.3542508,27.3320585)
id=1 1=(0,0.0625) [38,2] 17=(0.0625,0.09375) [38] 19=(0.09375,0.125) [38] id=2 2=(0,0.000976563) [1] 38=(0.000976563,0.00195313) [19,1,17]
id=1 1=(0,0.03125) [2] 21=(0.03125,0.0625) [2,38] 17=(0.0625,0.09375) [38] 19=(0.09375,0.125) [38] id=2 2=(0,0.000976563) [21,1] 38=(0.000976563,0.00195313) [21,19,17]
setPerp t=0.09375 cPt=(27.3514734,27.3348278) == oppT=0.00177644731 fPerpPt=(27.3514734,27.3348278)
setPerp t=0.125 cPt=(27.3542508,27.3320585) == oppT=0.00236860468 fPerpPt=(27.3542508,27.3320585)
setPerp t=0.001953125 cPt=(27.352302,27.3340014) == oppT=0.103073858 fPerpPt=(27.352302,27.3340014)
id=1 1=(0,0.03125) [2] 21=(0.03125,0.0625) [2,38] 17=(0.0625,0.09375) [40,38] id=2 2=(0,0.000976563) [21,1] 38=(0.000976563,0.00146484) [21,17] 40=(0.00146484,0.00195313) [17]
id=1 1=(0,0.03125) [42,2] 21=(0.03125,0.0625) [42,38] 17=(0.0625,0.09375) [40,38] id=2 2=(0,0.000488281) [1] 42=(0.000488281,0.000976563) [1,21] 38=(0.000976563,0.00146484) [21,17] 40=(0.00146484,0.00195313) [17]
setPerp t=0.00146484375 cPt=(27.3500121,27.3362857) == oppT=0.0773056159 fPerpPt=(27.3500121,27.3362857)
setPerp t=0.001953125 cPt=(27.352302,27.3340014) == oppT=0.103073858 fPerpPt=(27.352302,27.3340014)
setPerp t=0.078125 cPt=(27.3500849,27.3362131) == oppT=0.00148037018 fPerpPt=(27.3500849,27.3362131)
setPerp t=0.00146484375 cPt=(27.3500121,27.3362857) == oppT=0.0773056159 fPerpPt=(27.3500121,27.3362857)
setPerp t=0.001953125 cPt=(27.352302,27.3340014) == oppT=0.103073858 fPerpPt=(27.352302,27.3340014)
setPerp t=0.078125 cPt=(27.3500849,27.3362131) == oppT=0.00148037018 fPerpPt=(27.3500849,27.3362131)
setPerp t=0.09375 cPt=(27.3514734,27.3348278) == oppT=0.00177644731 fPerpPt=(27.3514734,27.3348278)
id=1 1=(0,0.03125) [42,2] 21=(0.03125,0.0625) [42,38] 17=(0.0625,0.078125) [38] id=2 2=(0,0.000488281) [1] 42=(0.000488281,0.000976563) [1,21] 38=(0.000976563,0.00146484) [21,17]
id=1 1=(0,0.03125) [42,2] 21=(0.03125,0.046875) [42] 25=(0.046875,0.0625) [38,42] 17=(0.0625,0.078125) [38] id=2 2=(0,0.000488281) [1] 42=(0.000488281,0.000976563) [25,1,21] 38=(0.000976563,0.00146484) [25,17]
id=1 1=(0,0.015625) [2] 27=(0.015625,0.03125) [2,42] 21=(0.03125,0.046875) [42] 25=(0.046875,0.0625) [38,42] 17=(0.0625,0.078125) [38] id=2 2=(0,0.000488281) [27,1] 42=(0.000488281,0.000976563) [27,25,21] 38=(0.000976563,0.00146484) [25,17]
setPerp t=0.0625 cPt=(27.3486967,27.3375987) == oppT=0.00118429408 fPerpPt=(27.3486967,27.3375987)
setPerp t=0.078125 cPt=(27.3500849,27.3362131) == oppT=0.00148037018 fPerpPt=(27.3500849,27.3362131)
setPerp t=0.00122070313 cPt=(27.3488674,27.3374283) == oppT=0.0644214392 fPerpPt=(27.3488674,27.3374283)
setPerp t=0.00146484375 cPt=(27.3500121,27.3362857) == oppT=0.0773056159 fPerpPt=(27.3500121,27.3362857)
id=1 1=(0,0.015625) [2] 27=(0.015625,0.03125) [2,42] 21=(0.03125,0.046875) [42] 25=(0.046875,0.0625) [38,42] 17=(0.0625,0.078125) [38] id=2 2=(0,0.000488281) [27,1] 42=(0.000488281,0.000976563) [27,25,21] 38=(0.000976563,0.0012207) [25,17]
id=1 1=(0,0.015625) [2] 27=(0.015625,0.03125) [2,42] 21=(0.03125,0.046875) [46,42] 25=(0.046875,0.0625) [46,38] 17=(0.0625,0.078125) [38] id=2 2=(0,0.000488281) [27,1] 42=(0.000488281,0.000732422) [27,21] 46=(0.000732422,0.000976563) [21,25] 38=(0.000976563,0.0012207) [25,17]
id=1 1=(0,0.015625) [48,2] 27=(0.015625,0.03125) [48,42] 21=(0.03125,0.046875) [46,42] 25=(0.046875,0.0625) [46,38] 17=(0.0625,0.078125) [38] id=2 2=(0,0.000244141) [1] 48=(0.000244141,0.000488281) [1,27] 42=(0.000488281,0.000732422) [27,21] 46=(0.000732422,0.000976563) [21,25] 38=(0.000976563,0.0012207) [25,17]
id=1 1=(0,0.015625) [48,2] 27=(0.015625,0.03125) [48,42] 21=(0.03125,0.046875) [46,42] 25=(0.046875,0.0625) [46,38] 17=(0.0625,0.0703125) [38] id=2 2=(0,0.000244141) [1] 48=(0.000244141,0.000488281) [1,27] 42=(0.000488281,0.000732422) [27,21] 46=(0.000732422,0.000976563) [21,25] 38=(0.000976563,0.0012207) [25,17]
id=1 1=(0,0.015625) [48,2] 27=(0.015625,0.03125) [48,42] 21=(0.03125,0.046875) [46,42] 25=(0.046875,0.0546875) [46,38] 31=(0.0546875,0.0625) [38] 17=(0.0625,0.0703125) [38] id=2 2=(0,0.000244141) [1] 48=(0.000244141,0.000488281) [1,27] 42=(0.000488281,0.000732422) [27,21] 46=(0.000732422,0.000976563) [21,25] 38=(0.000976563,0.0012207) [31,25,17]
id=1 1=(0,0.015625) [48,2] 27=(0.015625,0.03125) [48,42] 21=(0.03125,0.0390625) [46,42] 33=(0.0390625,0.046875) [46] 25=(0.046875,0.0546875) [46,38] 31=(0.0546875,0.0625) [38] 17=(0.0625,0.0703125) [38] id=2 2=(0,0.000244141) [1] 48=(0.000244141,0.000488281) [1,27] 42=(0.000488281,0.000732422) [27,21] 46=(0.000732422,0.000976563) [33,21,25] 38=(0.000976563,0.0012207) [31,25,17]
id=1 1=(0,0.015625) [48,2] 27=(0.015625,0.0234375) [48] 35=(0.0234375,0.03125) [42,48] 21=(0.03125,0.0390625) [46,42] 33=(0.0390625,0.046875) [46] 25=(0.046875,0.0546875) [46,38] 31=(0.0546875,0.0625) [38] 17=(0.0625,0.0703125) [38] id=2 2=(0,0.000244141) [1] 48=(0.000244141,0.000488281) [35,1,27] 42=(0.000488281,0.000732422) [35,21] 46=(0.000732422,0.000976563) [33,21,25] 38=(0.000976563,0.0012207) [31,25,17]
id=1 1=(0,0.0078125) [2] 37=(0.0078125,0.015625) [2,48] 27=(0.015625,0.0234375) [48] 35=(0.0234375,0.03125) [42,48] 21=(0.03125,0.0390625) [46,42] 33=(0.0390625,0.046875) [46] 25=(0.046875,0.0546875) [46,38] 31=(0.0546875,0.0625) [38] 17=(0.0625,0.0703125) [38] id=2 2=(0,0.000244141) [37,1] 48=(0.000244141,0.000488281) [37,35,27] 42=(0.000488281,0.000732422) [35,21] 46=(0.000732422,0.000976563) [33,21,25] 38=(0.000976563,0.0012207) [31,25,17]
setPerp t=0.0546875 cPt=(27.3480026,27.3382917) == oppT=0.00103625641 fPerpPt=(27.3480026,27.3382917)
setPerp t=0.0625 cPt=(27.3486967,27.3375987) == oppT=0.00118429408 fPerpPt=(27.3486967,27.3375987)
setPerp t=0.00109863281 cPt=(27.3482951,27.3379997) == oppT=0.057979337 fPerpPt=(27.3482951,27.3379997)
setPerp t=0.046875 cPt=(27.3473086,27.3389848) == oppT=0.00088821901 fPerpPt=(27.3473086,27.3389848)
setPerp t=0.0546875 cPt=(27.3480026,27.3382917) == oppT=0.00103625641 fPerpPt=(27.3480026,27.3382917)
setPerp t=0.0009765625 cPt=(27.3477228,27.3385711) == oppT=0.0515372255 fPerpPt=(27.3477228,27.3385711)
setPerp t=0.0625 cPt=(27.3486967,27.3375987) == oppT=0.00118429408 fPerpPt=(27.3486967,27.3375987)
setPerp t=0.0703125 cPt=(27.3493908,27.3369058) == oppT=0.001332332 fPerpPt=(27.3493908,27.3369058)
setPerp t=0.00122070313 cPt=(27.3488674,27.3374283) == oppT=0.0644214392 fPerpPt=(27.3488674,27.3374283)
setPerp t=0.0546875 cPt=(27.3480026,27.3382917) == oppT=0.00103625641 fPerpPt=(27.3480026,27.3382917)
setPerp t=0.0625 cPt=(27.3486967,27.3375987) == oppT=0.00118429408 fPerpPt=(27.3486967,27.3375987)
setPerp t=0.00109863281 cPt=(27.3482951,27.3379997) == oppT=0.057979337 fPerpPt=(27.3482951,27.3379997)
id=1 1=(0,0.0078125) [2] 37=(0.0078125,0.015625) [2,48] 27=(0.015625,0.0234375) [48] 35=(0.0234375,0.03125) [42,48] 21=(0.03125,0.0390625) [46,42] 33=(0.0390625,0.046875) [46] 25=(0.046875,0.0546875) [46] id=2 2=(0,0.000244141) [37,1] 48=(0.000244141,0.000488281) [37,35,27] 42=(0.000488281,0.000732422) [35,21] 46=(0.000732422,0.000976563) [33,21,25]
setPerp t=0.046875 cPt=(27.3473086,27.3389848) == oppT=0.00088821901 fPerpPt=(27.3473086,27.3389848)
setPerp t=0.0546875 cPt=(27.3480026,27.3382917) == oppT=0.00103625641 fPerpPt=(27.3480026,27.3382917)
setPerp t=0.0009765625 cPt=(27.3477228,27.3385711) == oppT=0.0515372255 fPerpPt=(27.3477228,27.3385711)
id=1 1=(0,0.0078125) [2] 37=(0.0078125,0.015625) [2,48] 27=(0.015625,0.0234375) [48] 35=(0.0234375,0.03125) [42,48] 21=(0.03125,0.0390625) [46,42] 33=(0.0390625,0.046875) [52,46] id=2 2=(0,0.000244141) [37,1] 48=(0.000244141,0.000488281) [37,35,27] 42=(0.000488281,0.000732422) [35,21] 46=(0.000732422,0.000854492) [33,21] 52=(0.000854492,0.000976563) [33]
id=1 1=(0,0.0078125) [2] 37=(0.0078125,0.015625) [2,48] 27=(0.015625,0.0234375) [48] 35=(0.0234375,0.03125) [42,48] 21=(0.03125,0.0390625) [54,46,42] 33=(0.0390625,0.046875) [52,46] id=2 2=(0,0.000244141) [37,1] 48=(0.000244141,0.000488281) [37,35,27] 42=(0.000488281,0.000610352) [35,21] 54=(0.000610352,0.000732422) [21] 46=(0.000732422,0.000854492) [33,21] 52=(0.000854492,0.000976563) [33]
id=1 1=(0,0.0078125) [2] 37=(0.0078125,0.015625) [2,48] 27=(0.015625,0.0234375) [56,48] 35=(0.0234375,0.03125) [56,42] 21=(0.03125,0.0390625) [54,46,42] 33=(0.0390625,0.046875) [52,46] id=2 2=(0,0.000244141) [37,1] 48=(0.000244141,0.000366211) [37,27] 56=(0.000366211,0.000488281) [27,35] 42=(0.000488281,0.000610352) [35,21] 54=(0.000610352,0.000732422) [21] 46=(0.000732422,0.000854492) [33,21] 52=(0.000854492,0.000976563) [33]
id=1 1=(0,0.0078125) [58,2] 37=(0.0078125,0.015625) [58,48] 27=(0.015625,0.0234375) [56,48] 35=(0.0234375,0.03125) [56,42] 21=(0.03125,0.0390625) [54,46,42] 33=(0.0390625,0.046875) [52,46] id=2 2=(0,0.00012207) [1] 58=(0.00012207,0.000244141) [1,37] 48=(0.000244141,0.000366211) [37,27] 56=(0.000366211,0.000488281) [27,35] 42=(0.000488281,0.000610352) [35,21] 54=(0.000610352,0.000732422) [21] 46=(0.000732422,0.000854492) [33,21] 52=(0.000854492,0.000976563) [33]
setPerp t=0.000854492188 cPt=(27.3471505,27.3391427) == oppT=0.0450951047 fPerpPt=(27.3471505,27.3391427)
setPerp t=0.0009765625 cPt=(27.3477228,27.3385711) == oppT=0.0515372255 fPerpPt=(27.3477228,27.3385711)
setPerp t=0.046875 cPt=(27.3473086,27.3389848) == oppT=0.00088821901 fPerpPt=(27.3473086,27.3389848)
id=1 1=(0,0.0078125) [58,2] 37=(0.0078125,0.015625) [58,48] 27=(0.015625,0.0234375) [56,48] 35=(0.0234375,0.03125) [56,42] 21=(0.03125,0.0390625) [54,46,42] 33=(0.0390625,0.0429688) [46] 39=(0.0429688,0.046875) [46] id=2 2=(0,0.00012207) [1] 58=(0.00012207,0.000244141) [1,37] 48=(0.000244141,0.000366211) [37,27] 56=(0.000366211,0.000488281) [27,35] 42=(0.000488281,0.000610352) [35,21] 54=(0.000610352,0.000732422) [21] 46=(0.000732422,0.000854492) [39,33,21]
id=1 1=(0,0.0078125) [58,2] 37=(0.0078125,0.015625) [58,48] 27=(0.015625,0.0234375) [56,48] 35=(0.0234375,0.03125) [56,42] 21=(0.03125,0.0351563) [54,42] 41=(0.0351563,0.0390625) [46,54] 33=(0.0390625,0.0429688) [46] 39=(0.0429688,0.046875) [46] id=2 2=(0,0.00012207) [1] 58=(0.00012207,0.000244141) [1,37] 48=(0.000244141,0.000366211) [37,27] 56=(0.000366211,0.000488281) [27,35] 42=(0.000488281,0.000610352) [35,21] 54=(0.000610352,0.000732422) [41,21] 46=(0.000732422,0.000854492) [41,39,33]
id=1 1=(0,0.0078125) [58,2] 37=(0.0078125,0.015625) [58,48] 27=(0.015625,0.0234375) [56,48] 35=(0.0234375,0.0273438) [56,42] 43=(0.0273438,0.03125) [42] 21=(0.03125,0.0351563) [54,42] 41=(0.0351563,0.0390625) [46,54] 33=(0.0390625,0.0429688) [46] 39=(0.0429688,0.046875) [46] id=2 2=(0,0.00012207) [1] 58=(0.00012207,0.000244141) [1,37] 48=(0.000244141,0.000366211) [37,27] 56=(0.000366211,0.000488281) [27,35] 42=(0.000488281,0.000610352) [43,35,21] 54=(0.000610352,0.000732422) [41,21] 46=(0.000732422,0.000854492) [41,39,33]
id=1 1=(0,0.0078125) [58,2] 37=(0.0078125,0.015625) [58,48] 27=(0.015625,0.0195313) [56,48] 45=(0.0195313,0.0234375) [56] 35=(0.0234375,0.0273438) [56,42] 43=(0.0273438,0.03125) [42] 21=(0.03125,0.0351563) [54,42] 41=(0.0351563,0.0390625) [46,54] 33=(0.0390625,0.0429688) [46] 39=(0.0429688,0.046875) [46] id=2 2=(0,0.00012207) [1] 58=(0.00012207,0.000244141) [1,37] 48=(0.000244141,0.000366211) [37,27] 56=(0.000366211,0.000488281) [45,27,35] 42=(0.000488281,0.000610352) [43,35,21] 54=(0.000610352,0.000732422) [41,21] 46=(0.000732422,0.000854492) [41,39,33]
id=1 1=(0,0.0078125) [58,2] 37=(0.0078125,0.0117188) [58] 47=(0.0117188,0.015625) [48,58] 27=(0.015625,0.0195313) [56,48] 45=(0.0195313,0.0234375) [56] 35=(0.0234375,0.0273438) [56,42] 43=(0.0273438,0.03125) [42] 21=(0.03125,0.0351563) [54,42] 41=(0.0351563,0.0390625) [46,54] 33=(0.0390625,0.0429688) [46] 39=(0.0429688,0.046875) [46] id=2 2=(0,0.00012207) [1] 58=(0.00012207,0.000244141) [47,1,37] 48=(0.000244141,0.000366211) [47,27] 56=(0.000366211,0.000488281) [45,27,35] 42=(0.000488281,0.000610352) [43,35,21] 54=(0.000610352,0.000732422) [41,21] 46=(0.000732422,0.000854492) [41,39,33]
id=1 1=(0,0.00390625) [2] 49=(0.00390625,0.0078125) [2,58] 37=(0.0078125,0.0117188) [58] 47=(0.0117188,0.015625) [48,58] 27=(0.015625,0.0195313) [56,48] 45=(0.0195313,0.0234375) [56] 35=(0.0234375,0.0273438) [56,42] 43=(0.0273438,0.03125) [42] 21=(0.03125,0.0351563) [54,42] 41=(0.0351563,0.0390625) [46,54] 33=(0.0390625,0.0429688) [46] 39=(0.0429688,0.046875) [46] id=2 2=(0,0.00012207) [49,1] 58=(0.00012207,0.000244141) [49,47,37] 48=(0.000244141,0.000366211) [47,27] 56=(0.000366211,0.000488281) [45,27,35] 42=(0.000488281,0.000610352) [43,35,21] 54=(0.000610352,0.000732422) [41,21] 46=(0.000732422,0.000854492) [41,39,33]
setPerp t=0.03515625 cPt=(27.3462676,27.3400246) == oppT=0.000666163387 fPerpPt=(27.3462676,27.3400246)
setPerp t=0.0390625 cPt=(27.3466146,27.3396779) == oppT=0.000740181863 fPerpPt=(27.3466146,27.3396779)
setPerp t=0.000732421875 cPt=(27.3465782,27.3397143) == oppT=0.0386529746 fPerpPt=(27.3465782,27.3397143)
setPerp t=0.0390625 cPt=(27.3466146,27.3396779) == oppT=0.000740181863 fPerpPt=(27.3466146,27.3396779)
setPerp t=0.04296875 cPt=(27.3469616,27.3393313) == oppT=0.000814200404 fPerpPt=(27.3469616,27.3393313)
setPerp t=0.000793457031 cPt=(27.3468644,27.3394285) == oppT=0.0418740408 fPerpPt=(27.3468644,27.3394285)
setPerp t=0.0390625 cPt=(27.3466146,27.3396779) == oppT=0.000740181863 fPerpPt=(27.3466146,27.3396779)
setPerp t=0.04296875 cPt=(27.3469616,27.3393313) == oppT=0.000814200404 fPerpPt=(27.3469616,27.3393313)
setPerp t=0.000793457031 cPt=(27.3468644,27.3394285) == oppT=0.0418740408 fPerpPt=(27.3468644,27.3394285)
setPerp t=0.04296875 cPt=(27.3469616,27.3393313) == oppT=0.000814200404 fPerpPt=(27.3469616,27.3393313)
setPerp t=0.046875 cPt=(27.3473086,27.3389848) == oppT=0.00088821901 fPerpPt=(27.3473086,27.3389848)
setPerp t=0.000854492188 cPt=(27.3471505,27.3391427) == oppT=0.0450951047 fPerpPt=(27.3471505,27.3391427)
id=1 1=(0,0.00390625) [2] 49=(0.00390625,0.0078125) [2,58] 37=(0.0078125,0.0117188) [58] 47=(0.0117188,0.015625) [48,58] 27=(0.015625,0.0195313) [56,48] 45=(0.0195313,0.0234375) [56] 35=(0.0234375,0.0273438) [56,42] 43=(0.0273438,0.03125) [42] 21=(0.03125,0.0351563) [54,42] 41=(0.0351563,0.0390625) [54] id=2 2=(0,0.00012207) [49,1] 58=(0.00012207,0.000244141) [49,47,37] 48=(0.000244141,0.000366211) [47,27] 56=(0.000366211,0.000488281) [45,27,35] 42=(0.000488281,0.000610352) [43,35,21] 54=(0.000610352,0.000732422) [41,21]
setPerp t=0.03515625 cPt=(27.3462676,27.3400246) == oppT=0.000666163387 fPerpPt=(27.3462676,27.3400246)
setPerp t=0.0390625 cPt=(27.3466146,27.3396779) == oppT=0.000740181863 fPerpPt=(27.3466146,27.3396779)
setPerp t=0.000671386719 cPt=(27.3462921,27.3400001) == oppT=0.0354319062 fPerpPt=(27.3462921,27.3400001)
setPerp t=0.03515625 cPt=(27.3462676,27.3400246) == oppT=0.000666163387 fPerpPt=(27.3462676,27.3400246)
setPerp t=0.0390625 cPt=(27.3466146,27.3396779) == oppT=0.000740181863 fPerpPt=(27.3466146,27.3396779)
setPerp t=0.000671386719 cPt=(27.3462921,27.3400001) == oppT=0.0354319062 fPerpPt=(27.3462921,27.3400001)
setPerp t=0.000732421875 cPt=(27.3465782,27.3397143) == oppT=0.0386529746 fPerpPt=(27.3465782,27.3397143)
id=1 1=(0,0.00390625) [2] 49=(0.00390625,0.0078125) [2,58] 37=(0.0078125,0.0117188) [58] 47=(0.0117188,0.015625) [48,58] 27=(0.015625,0.0195313) [56,48] 45=(0.0195313,0.0234375) [56] 35=(0.0234375,0.0273438) [56,42] 43=(0.0273438,0.03125) [42] 21=(0.03125,0.0351563) [54,42] id=2 2=(0,0.00012207) [49,1] 58=(0.00012207,0.000244141) [49,47,37] 48=(0.000244141,0.000366211) [47,27] 56=(0.000366211,0.000488281) [45,27,35] 42=(0.000488281,0.000610352) [43,35,21] 54=(0.000610352,0.000671387) [21]
id=1 1=(0,0.00390625) [2] 49=(0.00390625,0.0078125) [2,58] 37=(0.0078125,0.0117188) [58] 47=(0.0117188,0.015625) [48,58] 27=(0.015625,0.0195313) [56,48] 45=(0.0195313,0.0234375) [56] 35=(0.0234375,0.0273438) [56,42] 43=(0.0273438,0.03125) [64,42] 21=(0.03125,0.0351563) [64,54] id=2 2=(0,0.00012207) [49,1] 58=(0.00012207,0.000244141) [49,47,37] 48=(0.000244141,0.000366211) [47,27] 56=(0.000366211,0.000488281) [45,27,35] 42=(0.000488281,0.000549316) [43,35] 64=(0.000549316,0.000610352) [21,43] 54=(0.000610352,0.000671387) [21]
id=1 1=(0,0.00390625) [2] 49=(0.00390625,0.0078125) [2,58] 37=(0.0078125,0.0117188) [58] 47=(0.0117188,0.015625) [48,58] 27=(0.015625,0.0195313) [56,48] 45=(0.0195313,0.0234375) [66,56] 35=(0.0234375,0.0273438) [66,42] 43=(0.0273438,0.03125) [64,42] 21=(0.03125,0.0351563) [64,54] id=2 2=(0,0.00012207) [49,1] 58=(0.00012207,0.000244141) [49,47,37] 48=(0.000244141,0.000366211) [47,27] 56=(0.000366211,0.000427246) [45,27] 66=(0.000427246,0.000488281) [35,45] 42=(0.000488281,0.000549316) [43,35] 64=(0.000549316,0.000610352) [21,43] 54=(0.000610352,0.000671387) [21]
setPerp t=0 cPt=(27.3431454,27.3431454) == oppT=0 fPerpPt=(27.3431454,27.3431454)
setPerp t=0.00390625 cPt=(27.3434922,27.3427985) == oppT=7.40178961e-05 fPerpPt=(27.3434922,27.3427985)
setPerp t=0.0078125 cPt=(27.3438391,27.3424517) == oppT=0.000148035857 fPerpPt=(27.3438391,27.3424517)
setPerp t=0.01171875 cPt=(27.344186,27.3421049) == oppT=0.000222053882 fPerpPt=(27.344186,27.3421049)
setPerp t=0.015625 cPt=(27.3445329,27.3417581) == oppT=0.000296071971 fPerpPt=(27.3445329,27.3417581)
setPerp t=0.01953125 cPt=(27.3448799,27.3414113) == oppT=0.000370090126 fPerpPt=(27.3448799,27.3414113)
setPerp t=0.0234375 cPt=(27.3452268,27.3410646) == oppT=0.000444108344 fPerpPt=(27.3452268,27.3410646)
setPerp t=0.02734375 cPt=(27.3455737,27.3407179) == oppT=0.000518126627 fPerpPt=(27.3455737,27.3407179)
setPerp t=0.03125 cPt=(27.3459207,27.3403712) == oppT=0.000592144975 fPerpPt=(27.3459207,27.3403712)
setPerp t=0.03515625 cPt=(27.3462676,27.3400246) == oppT=0.000666163387 fPerpPt=(27.3462676,27.3400246)
setPerp t=0 cPt=(27.3431454,27.3431454) == oppT=0 fPerpPt=(27.3431454,27.3431454)
setPerp t=0.03515625 cPt=(27.3462676,27.3400246) == oppT=0.000666163387 fPerpPt=(27.3462676,27.3400246)
id=1 (empty) id=2 (empty)
debugShowQuadIntersection wtTs[0]=0 {{{27.3431454,27.3431454}, {27.3875446,27.2987461}, {27.4323025,27.2551785}}} {{27.3431454,27.3431454}} wtTs[1]=0.03515625 {{27.3462677,27.3400249}} wnTs[0]=0 {{{27.3431454,27.3431454}, {29.6862907,25}, {33,25}}} wnTs[1]=0.000666163387
SkOpSegment::addT insert t=0.03515625 segID=20 spanID=49
SkOpSegment::addT insert t=0.000666163387 segID=6 spanID=50
id=1 1=(0,1) [2] id=2 2=(0,0.5) [1]
id=1 1=(0,1) [2] id=2 2=(0,0.25) [1]
id=1 1=(0,1) [2] id=2 2=(0,0.125) [1]
id=1 1=(0,1) [2] id=2 2=(0,0.0625) [1]
id=1 1=(0,1) [12,2] id=2 2=(0,0.03125) [1] 12=(0.03125,0.0625) [1]
id=1 1=(0,1) [12,2] id=2 2=(0,0.03125) [1] 12=(0.03125,0.046875) [1]
id=1 1=(0,1) [16,12] id=2 16=(0.015625,0.03125) [1] 12=(0.03125,0.046875) [1]
id=1 1=(0,0.5) [16] 3=(0.5,1) [16] id=2 16=(0.015625,0.03125) [3,1]
id=1 1=(0,0.5) [18,16] id=2 16=(0.015625,0.0234375) [1] 18=(0.0234375,0.03125) [1]
id=1 1=(0,0.25) [16] id=2 16=(0.015625,0.0234375) [1]
id=1 1=(0,0.25) [20,16] id=2 16=(0.015625,0.0195313) [1] 20=(0.0195313,0.0234375) [1]
id=1 1=(0,0.125) [20,16] id=2 16=(0.015625,0.0195313) [1] 20=(0.0195313,0.0234375) [1]
setPerp t=0 cPt=(27.4323025,27.2551785) == oppT=0.0189506973 fPerpPt=(27.4323024,27.2551784)
setPerp t=0.125 cPt=(27.4431369,27.243922) != oppT=0.0213231007 fPerpPt=(27.4435129,27.2442845)
setPerp t=0.01953125 cPt=(27.4350447,27.2525101) != oppT=0.0306377854 fPerpPt=(27.4349556,27.2524185)
id=1 1=(0,0.125) [16] id=2 16=(0.015625,0.0195313) [1]
id=1 (empty) id=2 (empty)
debugShowQuadIntersection no intersect {{{27.4323025,27.2551785}, {27.4755878,27.2101307}, {27.5197105,27.165432}}} {{{27.3431454,27.3431454}, {29.6862907,25}, {33,25}}}
debugShowQuadIntersection no intersect {{{27.5197105,27.165432}, {27.541851,27.1430035}, {27.5638676,27.1209965}}} {{{27.3431454,27.3431454}, {29.6862907,25}, {33,25}}}
id=1 (empty) id=2 (empty)
debugShowQuadIntersection no intersect {{{27.5638676,27.1209965}, {27.5855064,27.0986347}, {27.6075668,27.0761414}}} {{{27.3431454,27.3431454}, {29.6862907,25}, {33,25}}}
id=1 1=(0,1) [4,2] id=2 2=(0,0.5) [1] 4=(0.5,1) [1]
id=1 1=(0,0.5) [2] 3=(0.5,1) [4] id=2 2=(0,0.5) [1] 4=(0.5,1) [3]
id=1 1=(0,0.5) [2] id=2 2=(0,0.5) [1]
id=1 1=(0,0.5) [8,2] id=2 2=(0,0.25) [1] 8=(0.25,0.5) [1]
id=1 1=(0,0.25) [2] id=2 2=(0,0.25) [1]
id=1 1=(0,0.25) [10,2] id=2 2=(0,0.125) [1] 10=(0.125,0.25) [1]
id=1 (empty) id=2 (empty)
debugShowQuadIntersection no intersect {{{27.6075668,27.0761414}, {29.9278316,24.7103367}, {33.2413864,24.6781349}}} {{{27.3431454,27.3431454}, {29.6862907,25}, {33,25}}}
debugShowQuadIntersection no intersect {{{27.6075668,27.0761414}, {29.9278316,24.7103367}, {33.2413864,24.6781349}}} {{{33,25}, {36.3137093,25}, {38.6568527,27.3431454}}}
debugShowQuadIntersection wtTs[0]=1 {{{41,33}, {41,36.3137093}, {38.6568527,38.6568527}}} {{38.6568527,38.6568527}} wnTs[0]=0 {{{38.6568527,38.6568527}, {36.3137093,41}, {33,41}}}
debugShowQuadIntersection wtTs[0]=0 {{{41,33}, {41,36.3137093}, {38.6568527,38.6568527}}} {{41,33}} wnTs[0]=1 {{{38.6568527,27.3431454}, {41,29.6862907}, {41,33}}}
debugShowQuadIntersection wtTs[0]=1 {{{38.6568527,38.6568527}, {36.3137093,41}, {33,41}}} {{33,41}} wnTs[0]=0 {{{33,41}, {29.6862907,41}, {27.3431454,38.6568527}}}
debugShowQuadIntersection wtTs[0]=1 {{{33,41}, {29.6862907,41}, {27.3431454,38.6568527}}} {{27.3431454,38.6568527}} wnTs[0]=0 {{{27.3431454,38.6568527}, {25,36.3137093}, {25,33}}}
debugShowQuadIntersection wtTs[0]=1 {{{27.3431454,38.6568527}, {25,36.3137093}, {25,33}}} {{25,33}} wnTs[0]=0 {{{25,33}, {25,29.6862907}, {27.3431454,27.3431454}}}
debugShowQuadIntersection wtTs[0]=1 {{{25,33}, {25,29.6862907}, {27.3431454,27.3431454}}} {{27.3431454,27.3431454}} wnTs[0]=0 {{{27.3431454,27.3431454}, {29.6862907,25}, {33,25}}}
debugShowQuadIntersection wtTs[0]=1 {{{27.3431454,27.3431454}, {29.6862907,25}, {33,25}}} {{33,25}} wnTs[0]=0 {{{33,25}, {36.3137093,25}, {38.6568527,27.3431454}}}
debugShowQuadIntersection wtTs[0]=1 {{{33,25}, {36.3137093,25}, {38.6568527,27.3431454}}} {{38.6568527,27.3431454}} wnTs[0]=0 {{{38.6568527,27.3431454}, {41,29.6862907}, {41,33}}}
SkOpSegment::markDone id=6 (27.3431454,27.3431454 29.6862907,25 33,25) t=0 [11] (27.3431454,27.3431454) tEnd=0.000666163387 newWindSum=? newOppSum=? oppSum=? windSum=? windValue=0 oppValue=0
SkOpSegment::markDone id=5 (25,33 25,29.6862907 27.3431454,27.3431454) t=0 [9] (25,33) tEnd=1 newWindSum=? newOppSum=? oppSum=? windSum=? windValue=0 oppValue=0
SkOpSegment::markDone id=4 (27.3431454,38.6568527 25,36.3137093 25,33) t=0 [7] (27.3431454,38.6568527) tEnd=1 newWindSum=? newOppSum=? oppSum=? windSum=? windValue=0 oppValue=0
SkOpSegment::markDone id=3 (33,41 29.6862907,41 27.3431454,38.6568527) t=0 [5] (33,41) tEnd=1 newWindSum=? newOppSum=? oppSum=? windSum=? windValue=0 oppValue=0
SkOpSegment::markDone id=2 (38.6568527,38.6568527 36.3137093,41 33,41) t=0 [3] (38.6568527,38.6568527) tEnd=1 newWindSum=? newOppSum=? oppSum=? windSum=? windValue=0 oppValue=0
SkOpSegment::sortAngles [15] tStart=1 [30]
SkOpAngle::after [15/1] 4/5 tStart=1 tEnd=0 < [16/2] 21/17 tStart=0 tEnd=1 < [1/13] 1/5 tStart=1 tEnd=0 T 5
SkOpAngle::afterPart {{{38.6568527,38.6568527}, {38.7196693,38.5940361}, {38.7809143,38.5304031}}} id=15
SkOpAngle::afterPart {{{38.6568527,38.6568527}, {36.3137093,41}, {33,41}}} id=16
SkOpAngle::afterPart {{{38.6568527,38.6568527}, {41,36.3137093}, {41,33}}} id=1
SkOpSegment::sortAngles [16] tStart=0 [31]
SkOpSegment::sortAngles [16] tStart=1 [32]
SkOpSegment::sortAngles [17] tStart=0 [33]
SkOpSegment::sortAngles [17] tStart=1 [34]
SkOpSegment::sortAngles [18] tStart=0 [35]
SkOpSegment::sortAngles [18] tStart=1 [36]
SkOpSegment::sortAngles [19] tStart=0 [37]
SkOpSegment::sortAngles [19] tStart=1 [38]
SkOpSegment::sortAngles [20] tStart=0 [39]
SkOpSegment::sortAngles [20] tStart=0.03515625 [49]
SkOpAngle::after [20/11] 17/17 tStart=0.03515625 tEnd=0 < [6/14] 1/1 tStart=0.000666163387 tEnd=1 < [20/12] 1/1 tStart=0.03515625 tEnd=1 F 11
SkOpAngle::afterPart {{{27.3462677,27.3400249}, {27.3447063,27.3415846}, {27.3431454,27.3431454}}} id=20
SkOpAngle::afterPart {{{27.3462677,27.3400249}, {29.6884986,25}, {33,25}}} id=6
SkOpAngle::afterPart {{{27.3462677,27.3400249}, {27.3891352,27.2971979}, {27.4323025,27.2551785}}} id=20
SkOpSegment::sortAngles [1] tStart=1 [2]
SkOpSegment::sortAngles [6] tStart=0.000666163387 [50]
SkOpCoincidence::debugShowCoincidence - id=20 t=0 tEnd=0.03515625
SkOpCoincidence::debugShowCoincidence + id=6 t=0 tEnd=0.000666163387
SkOpCoincidence::debugShowCoincidence - id=19 t=0 tEnd=1
SkOpCoincidence::debugShowCoincidence + id=5 t=0 tEnd=1
SkOpCoincidence::debugShowCoincidence - id=18 t=0 tEnd=1
SkOpCoincidence::debugShowCoincidence + id=4 t=0 tEnd=1
SkOpCoincidence::debugShowCoincidence - id=17 t=0 tEnd=1
SkOpCoincidence::debugShowCoincidence + id=3 t=0 tEnd=1
SkOpCoincidence::debugShowCoincidence - id=16 t=0 tEnd=1
SkOpCoincidence::debugShowCoincidence + id=2 t=0 tEnd=1
SkOpSegment::debugShowActiveSpans id=9 (33.2413864,24.6781349 36.5549393,24.6459332 38.920742,26.966198) t=0 (33.2413864,24.6781349) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=10 (38.920742,26.966198 41.2865486,29.2864628 41.3187523,32.6000175) t=0 (38.920742,26.966198) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=11 (41.3187523,32.6000175 41.3509521,35.9135704 39.0306854,38.2793732) t=0 (41.3187523,32.6000175) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=12 (39.0306854,38.2793732 38.9995995,38.3110695 38.9681816,38.3424988) t=0 (39.0306854,38.2793732) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=13 (38.9681816,38.3424988 38.9374619,38.3742142 38.9064751,38.4056053) t=0 (38.9681816,38.3424988) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=14 (38.9064751,38.4056053 38.8441086,38.4687881 38.7809143,38.5304031) t=0 (38.9064751,38.4056053) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=15 (38.7809143,38.5304031 38.7196693,38.5940361 38.6568527,38.6568527) t=0 (38.7809143,38.5304031) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=16 (38.6568527,38.6568527 36.3137093,41 33,41) t=0 (38.6568527,38.6568527) tEnd=1 windSum=? windValue=2
SkOpSegment::debugShowActiveSpans id=17 (33,41 29.6862907,41 27.3431454,38.6568527) t=0 (33,41) tEnd=1 windSum=? windValue=2
SkOpSegment::debugShowActiveSpans id=18 (27.3431454,38.6568527 25,36.3137093 25,33) t=0 (27.3431454,38.6568527) tEnd=1 windSum=? windValue=2
SkOpSegment::debugShowActiveSpans id=19 (25,33 25,29.6862907 27.3431454,27.3431454) t=0 (25,33) tEnd=1 windSum=? windValue=2
SkOpSegment::debugShowActiveSpans id=20 (27.3431454,27.3431454 27.3875446,27.2987461 27.4323025,27.2551785) t=0 (27.3431454,27.3431454) tEnd=0.03515625 windSum=? windValue=2
SkOpSegment::debugShowActiveSpans id=20 (27.3431454,27.3431454 27.3875446,27.2987461 27.4323025,27.2551785) t=0.03515625 (27.3462677,27.3400249) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=21 (27.4323025,27.2551785 27.4755878,27.2101307 27.5197105,27.165432) t=0 (27.4323025,27.2551785) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=22 (27.5197105,27.165432 27.541851,27.1430035 27.5638676,27.1209965) t=0 (27.5197105,27.165432) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=23 (27.5638676,27.1209965 27.5855064,27.0986347 27.6075668,27.0761414) t=0 (27.5638676,27.1209965) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=24 (27.6075668,27.0761414 29.9278316,24.7103367 33.2413864,24.6781349) t=0 (27.6075668,27.0761414) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=1 (41,33 41,36.3137093 38.6568527,38.6568527) t=0 (41,33) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=6 (27.3431454,27.3431454 29.6862907,25 33,25) t=0.000666163387 (27.3462677,27.3400249) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=7 (33,25 36.3137093,25 38.6568527,27.3431454) t=0 (33,25) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=8 (38.6568527,27.3431454 41,29.6862907 41,33) t=0 (38.6568527,27.3431454) tEnd=1 windSum=? windValue=1
SkOpSpan::sortableTop dir=kTop seg=9 t=0.5 pt=(36.3180008,25.2340508)
SkOpSpan::sortableTop [0] valid=1 operand=0 span=17 ccw=1 seg=9 {{{33.2413864f, 24.6781349f}, {36.5549393f, 24.6459332f}, {38.920742f, 26.966198f}}} t=0.5 pt=(36.3180008,25.2340508) slope=(2.83967781,1.14403152)
SkOpSegment::markWinding id=9 (33.2413864,24.6781349 36.5549393,24.6459332 38.920742,26.966198) t=0 [17] (33.2413864,24.6781349) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
SkOpSegment::markWinding id=10 (38.920742,26.966198 41.2865486,29.2864628 41.3187523,32.6000175) t=0 [19] (38.920742,26.966198) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=11 (41.3187523,32.6000175 41.3509521,35.9135704 39.0306854,38.2793732) t=0 [21] (41.3187523,32.6000175) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=12 (39.0306854,38.2793732 38.9995995,38.3110695 38.9681816,38.3424988) t=0 [23] (39.0306854,38.2793732) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=13 (38.9681816,38.3424988 38.9374619,38.3742142 38.9064751,38.4056053) t=0 [25] (38.9681816,38.3424988) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=14 (38.9064751,38.4056053 38.8441086,38.4687881 38.7809143,38.5304031) t=0 [27] (38.9064751,38.4056053) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=15 (38.7809143,38.5304031 38.7196693,38.5940361 38.6568527,38.6568527) t=0 [29] (38.7809143,38.5304031) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=9 (33.2413864,24.6781349 36.5549393,24.6459332 38.920742,26.966198) t=0 [17] (33.2413864,24.6781349) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
SkOpSegment::markWinding id=24 (27.6075668,27.0761414 29.9278316,24.7103367 33.2413864,24.6781349) t=0 [47] (27.6075668,27.0761414) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=23 (27.5638676,27.1209965 27.5855064,27.0986347 27.6075668,27.0761414) t=0 [45] (27.5638676,27.1209965) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=22 (27.5197105,27.165432 27.541851,27.1430035 27.5638676,27.1209965) t=0 [43] (27.5197105,27.165432) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=21 (27.4323025,27.2551785 27.4755878,27.2101307 27.5197105,27.165432) t=0 [41] (27.4323025,27.2551785) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=20 (27.3431454,27.3431454 27.3875446,27.2987461 27.4323025,27.2551785) t=0.03515625 [49] (27.3462677,27.3400249) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::findNextWinding simple
SkOpSegment::markDone id=9 (33.2413864,24.6781349 36.5549393,24.6459332 38.920742,26.966198) t=0 [17] (33.2413864,24.6781349) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeWinding current id=9 from=(38.920742,26.966198) to=(33.2413864,24.6781349)
path.moveTo(38.920742,26.966198);
path.quadTo(36.5549393,24.6459332, 33.2413864,24.6781349);
SkOpSegment::findNextWinding simple
SkOpSegment::markDone id=24 (27.6075668,27.0761414 29.9278316,24.7103367 33.2413864,24.6781349) t=0 [47] (27.6075668,27.0761414) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeWinding current id=24 from=(33.2413864,24.6781349) to=(27.6075668,27.0761414)
path.quadTo(29.9278316,24.7103367, 27.6075668,27.0761414);
SkOpSegment::findNextWinding simple
SkOpSegment::markDone id=23 (27.5638676,27.1209965 27.5855064,27.0986347 27.6075668,27.0761414) t=0 [45] (27.5638676,27.1209965) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeWinding current id=23 from=(27.6075668,27.0761414) to=(27.5638676,27.1209965)
path.quadTo(27.5855064,27.0986347, 27.5638676,27.1209965);
SkOpSegment::findNextWinding simple
SkOpSegment::markDone id=22 (27.5197105,27.165432 27.541851,27.1430035 27.5638676,27.1209965) t=0 [43] (27.5197105,27.165432) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeWinding current id=22 from=(27.5638676,27.1209965) to=(27.5197105,27.165432)
path.quadTo(27.541851,27.1430035, 27.5197105,27.165432);
SkOpSegment::findNextWinding simple
SkOpSegment::markDone id=21 (27.4323025,27.2551785 27.4755878,27.2101307 27.5197105,27.165432) t=0 [41] (27.4323025,27.2551785) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeWinding current id=21 from=(27.5197105,27.165432) to=(27.4323025,27.2551785)
path.quadTo(27.4755878,27.2101307, 27.4323025,27.2551785);
SkOpSegment::markWinding id=6 (27.3431454,27.3431454 29.6862907,25 33,25) t=0.000666163387 [50] (27.3462677,27.3400249) tEnd=1 newWindSum=1 windSum=? windValue=1
SkOpSegment::markWinding id=7 (33,25 36.3137093,25 38.6568527,27.3431454) t=0 [13] (33,25) tEnd=1 newWindSum=1 windSum=? windValue=1
SkOpSegment::markWinding id=8 (38.6568527,27.3431454 41,29.6862907 41,33) t=0 [15] (38.6568527,27.3431454) tEnd=1 newWindSum=1 windSum=? windValue=1
SkOpSegment::markWinding id=1 (41,33 41,36.3137093 38.6568527,38.6568527) t=0 [1] (41,33) tEnd=1 newWindSum=1 windSum=? windValue=1
SkOpSegment::markAngle last seg=1 span=2
SkOpSegment::markWinding id=20 (27.3431454,27.3431454 27.3875446,27.2987461 27.4323025,27.2551785) t=0 [39] (27.3431454,27.3431454) tEnd=0.03515625 newWindSum=1 windSum=? windValue=2
SkOpSegment::nextChase mismatched signs
SkOpSegment::markWinding id=19 (25,33 25,29.6862907 27.3431454,27.3431454) t=0 [37] (25,33) tEnd=1 newWindSum=1 windSum=? windValue=2
SkOpSegment::nextChase mismatched signs
SkOpSegment::markWinding id=18 (27.3431454,38.6568527 25,36.3137093 25,33) t=0 [35] (27.3431454,38.6568527) tEnd=1 newWindSum=1 windSum=? windValue=2
SkOpSegment::nextChase mismatched signs
SkOpSegment::markWinding id=17 (33,41 29.6862907,41 27.3431454,38.6568527) t=0 [33] (33,41) tEnd=1 newWindSum=1 windSum=? windValue=2
SkOpSegment::nextChase mismatched signs
SkOpSegment::markWinding id=16 (38.6568527,38.6568527 36.3137093,41 33,41) t=0 [31] (38.6568527,38.6568527) tEnd=1 newWindSum=1 windSum=? windValue=2
SkOpSegment::markAngle last seg=16 span=31 windSum=1
SkOpSegment::findNextWinding
SkOpAngle::dumpOne [20/12] next=6/14 sect=1/1 s=0.03515625 [49] e=1 [40] sgn=-1 windVal=1 windSum=-1 oppVal=0 oppSum=0
SkOpAngle::dumpOne [6/14] next=20/11 sect=1/1 s=0.000666163387 [50] e=1 [12] sgn=-1 windVal=1 windSum=1
SkOpAngle::dumpOne [20/11] next=20/12 sect=17/17 s=0.03515625 [49] e=0 [39] sgn=1 windVal=2 windSum=1
SkOpSegment::findNextWinding chase.append segment=1 span=2
SkOpSegment::markDone id=20 (27.3431454,27.3431454 27.3875446,27.2987461 27.4323025,27.2551785) t=0 [39] (27.3431454,27.3431454) tEnd=0.03515625 newWindSum=1 newOppSum=? oppSum=? windSum=1 windValue=2 oppValue=0
SkOpSegment::nextChase mismatched signs
SkOpSegment::markDone id=19 (25,33 25,29.6862907 27.3431454,27.3431454) t=0 [37] (25,33) tEnd=1 newWindSum=1 newOppSum=? oppSum=? windSum=1 windValue=2 oppValue=0
SkOpSegment::nextChase mismatched signs
SkOpSegment::markDone id=18 (27.3431454,38.6568527 25,36.3137093 25,33) t=0 [35] (27.3431454,38.6568527) tEnd=1 newWindSum=1 newOppSum=? oppSum=? windSum=1 windValue=2 oppValue=0
SkOpSegment::nextChase mismatched signs
SkOpSegment::markDone id=17 (33,41 29.6862907,41 27.3431454,38.6568527) t=0 [33] (33,41) tEnd=1 newWindSum=1 newOppSum=? oppSum=? windSum=1 windValue=2 oppValue=0
SkOpSegment::nextChase mismatched signs
SkOpSegment::markDone id=16 (38.6568527,38.6568527 36.3137093,41 33,41) t=0 [31] (38.6568527,38.6568527) tEnd=1 newWindSum=1 newOppSum=? oppSum=? windSum=1 windValue=2 oppValue=0
SkOpSegment::findNextWinding chase.append segment=16 span=31 windSum=1
SkOpSegment::markDone id=20 (27.3431454,27.3431454 27.3875446,27.2987461 27.4323025,27.2551785) t=0.03515625 [49] (27.3462677,27.3400249) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
SkOpSegment::findNextWinding from:[20] to:[6] start=5584652 end=5579668
bridgeWinding current id=20 from=(27.4323025,27.2551785) to=(27.3462677,27.3400249)
path.quadTo(27.3891354,27.2971973, 27.3462677,27.3400249);
SkOpSegment::findNextWinding simple
SkOpSegment::markDone id=6 (27.3431454,27.3431454 29.6862907,25 33,25) t=0.000666163387 [50] (27.3462677,27.3400249) tEnd=1 newWindSum=1 newOppSum=? oppSum=? windSum=1 windValue=1 oppValue=0
bridgeWinding current id=6 from=(27.3462677,27.3400249) to=(33,25)
path.quadTo(29.6884995,25, 33,25);
SkOpSegment::findNextWinding simple
SkOpSegment::markDone id=7 (33,25 36.3137093,25 38.6568527,27.3431454) t=0 [13] (33,25) tEnd=1 newWindSum=1 newOppSum=? oppSum=? windSum=1 windValue=1 oppValue=0
bridgeWinding current id=7 from=(33,25) to=(38.6568527,27.3431454)
path.quadTo(36.3137093,25, 38.6568527,27.3431454);
SkOpSegment::findNextWinding simple
SkOpSegment::markDone id=8 (38.6568527,27.3431454 41,29.6862907 41,33) t=0 [15] (38.6568527,27.3431454) tEnd=1 newWindSum=1 newOppSum=? oppSum=? windSum=1 windValue=1 oppValue=0
bridgeWinding current id=8 from=(38.6568527,27.3431454) to=(41,33)
path.quadTo(41,29.6862907, 41,33);
SkOpSegment::findNextWinding
SkOpAngle::dumpOne [1/13] next=15/1 sect=1/5 s=1 [2] e=0 [1] sgn=1 windVal=1 windSum=1
SkOpAngle::dumpOne [15/1] next=16/2 sect=4/5 s=1 [30] e=0 [29] sgn=1 windVal=1 windSum=-1 oppVal=0 oppSum=0
SkOpAngle::dumpOne [16/2] next=1/13 sect=21/17 s=0 [31] e=1 [32] sgn=-1 windVal=2 windSum=1 done
SkOpSegment::markDone id=1 (41,33 41,36.3137093 38.6568527,38.6568527) t=0 [1] (41,33) tEnd=1 newWindSum=1 newOppSum=? oppSum=? windSum=1 windValue=1 oppValue=0
SkOpSegment::findNextWinding from:[1] to:[15] start=5581892 end=5581788
bridgeWinding current id=1 from=(41,33) to=(38.6568527,38.6568527)
path.quadTo(41,36.3137093, 38.6568527,38.6568527);
SkOpSegment::findNextWinding simple
SkOpSegment::markDone id=15 (38.7809143,38.5304031 38.7196693,38.5940361 38.6568527,38.6568527) t=0 [29] (38.7809143,38.5304031) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeWinding current id=15 from=(38.6568527,38.6568527) to=(38.7809143,38.5304031)
path.quadTo(38.7196693,38.5940361, 38.7809143,38.5304031);
SkOpSegment::findNextWinding simple
SkOpSegment::markDone id=14 (38.9064751,38.4056053 38.8441086,38.4687881 38.7809143,38.5304031) t=0 [27] (38.9064751,38.4056053) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeWinding current id=14 from=(38.7809143,38.5304031) to=(38.9064751,38.4056053)
path.quadTo(38.8441086,38.4687881, 38.9064751,38.4056053);
SkOpSegment::findNextWinding simple
SkOpSegment::markDone id=13 (38.9681816,38.3424988 38.9374619,38.3742142 38.9064751,38.4056053) t=0 [25] (38.9681816,38.3424988) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeWinding current id=13 from=(38.9064751,38.4056053) to=(38.9681816,38.3424988)
path.quadTo(38.9374619,38.3742142, 38.9681816,38.3424988);
SkOpSegment::findNextWinding simple
SkOpSegment::markDone id=12 (39.0306854,38.2793732 38.9995995,38.3110695 38.9681816,38.3424988) t=0 [23] (39.0306854,38.2793732) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeWinding current id=12 from=(38.9681816,38.3424988) to=(39.0306854,38.2793732)
path.quadTo(38.9995995,38.3110695, 39.0306854,38.2793732);
SkOpSegment::findNextWinding simple
SkOpSegment::markDone id=11 (41.3187523,32.6000175 41.3509521,35.9135704 39.0306854,38.2793732) t=0 [21] (41.3187523,32.6000175) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeWinding current id=11 from=(39.0306854,38.2793732) to=(41.3187523,32.6000175)
path.quadTo(41.3509521,35.9135704, 41.3187523,32.6000175);
SkOpSegment::findNextWinding simple
SkOpSegment::markDone id=10 (38.920742,26.966198 41.2865486,29.2864628 41.3187523,32.6000175) t=0 [19] (38.920742,26.966198) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeWinding current id=10 from=(41.3187523,32.6000175) to=(38.920742,26.966198)
path.quadTo(41.2865486,29.2864628, 38.920742,26.966198);
path.close();
</div>
<div id="fuzz763_4713parts">
seg=1 {{{-33.1326447f, -40.8928833f}, {-29.8189526f, -40.9036179f}, {-27.4682293f, -38.5680733f}}}
seg=2 {{{-27.4682293f, -38.5680733f}, {-25.117506f, -36.2325325f}, {-25.1067715f, -32.9188423f}}}
seg=3 {{{-25.1067715f, -32.9188423f}, {-25.0960369f, -29.6051483f}, {-27.4315796f, -27.254425f}}}
seg=4 {{{-27.4315796f, -27.254425f}, {-29.7671204f, -24.9036999f}, {-33.0808144f, -24.8929653f}}}
seg=5 {{{-33.0808144f, -24.8929653f}, {-36.3945045f, -24.8822308f}, {-38.7452278f, -27.2177753f}}}
seg=6 {{{-38.7452278f, -27.2177753f}, {-41.0959549f, -29.5533161f}, {-41.1066895f, -32.867012f}}}
seg=7 {{{-41.1066895f, -32.867012f}, {-41.117424f, -36.1807022f}, {-38.7818794f, -38.5314217f}}}
seg=8 {{{-38.7818794f, -38.5314217f}, {-36.4463348f, -40.8821487f}, {-33.1326447f, -40.8928833f}}}
op union
seg=9 {{{41, 33}, {41, 36.3137093f}, {38.6568527f, 38.6568527f}}}
seg=10 {{{38.6568527f, 38.6568527f}, {36.3137093f, 41}, {33, 41}}}
seg=11 {{{33, 41}, {29.6862907f, 41}, {27.3431454f, 38.6568527f}}}
seg=12 {{{27.3431454f, 38.6568527f}, {25, 36.3137093f}, {25, 33}}}
seg=13 {{{25, 33}, {25, 29.6862907f}, {27.3431454f, 27.3431454f}}}
seg=14 {{{27.3431454f, 27.3431454f}, {29.6862907f, 25}, {33, 25}}}
seg=15 {{{33, 25}, {36.3137093f, 25}, {38.6568527f, 27.3431454f}}}
seg=16 {{{38.6568527f, 27.3431454f}, {41, 29.6862907f}, {41, 33}}}
debugShowQuadIntersection wtTs[0]=1 {{{-33.1326447,-40.8928833}, {-29.8189526,-40.9036179}, {-27.4682293,-38.5680733}}} {{-27.4682293,-38.5680733}} wnTs[0]=0 {{{-27.4682293,-38.5680733}, {-25.117506,-36.2325325}, {-25.1067715,-32.9188423}}}
debugShowQuadIntersection wtTs[0]=0 {{{-33.1326447,-40.8928833}, {-29.8189526,-40.9036179}, {-27.4682293,-38.5680733}}} {{-33.1326447,-40.8928833}} wnTs[0]=1 {{{-38.7818794,-38.5314217}, {-36.4463348,-40.8821487}, {-33.1326447,-40.8928833}}}
debugShowQuadIntersection wtTs[0]=1 {{{-27.4682293,-38.5680733}, {-25.117506,-36.2325325}, {-25.1067715,-32.9188423}}} {{-25.1067715,-32.9188423}} wnTs[0]=0 {{{-25.1067715,-32.9188423}, {-25.0960369,-29.6051483}, {-27.4315796,-27.254425}}}
debugShowQuadIntersection wtTs[0]=1 {{{-25.1067715,-32.9188423}, {-25.0960369,-29.6051483}, {-27.4315796,-27.254425}}} {{-27.4315796,-27.254425}} wnTs[0]=0 {{{-27.4315796,-27.254425}, {-29.7671204,-24.9036999}, {-33.0808144,-24.8929653}}}
debugShowQuadIntersection wtTs[0]=1 {{{-27.4315796,-27.254425}, {-29.7671204,-24.9036999}, {-33.0808144,-24.8929653}}} {{-33.0808144,-24.8929653}} wnTs[0]=0 {{{-33.0808144,-24.8929653}, {-36.3945045,-24.8822308}, {-38.7452278,-27.2177753}}}
debugShowQuadIntersection wtTs[0]=1 {{{-33.0808144,-24.8929653}, {-36.3945045,-24.8822308}, {-38.7452278,-27.2177753}}} {{-38.7452278,-27.2177753}} wnTs[0]=0 {{{-38.7452278,-27.2177753}, {-41.0959549,-29.5533161}, {-41.1066895,-32.867012}}}
debugShowQuadIntersection wtTs[0]=1 {{{-38.7452278,-27.2177753}, {-41.0959549,-29.5533161}, {-41.1066895,-32.867012}}} {{-41.1066895,-32.867012}} wnTs[0]=0 {{{-41.1066895,-32.867012}, {-41.117424,-36.1807022}, {-38.7818794,-38.5314217}}}
debugShowQuadIntersection wtTs[0]=1 {{{-41.1066895,-32.867012}, {-41.117424,-36.1807022}, {-38.7818794,-38.5314217}}} {{-38.7818794,-38.5314217}} wnTs[0]=0 {{{-38.7818794,-38.5314217}, {-36.4463348,-40.8821487}, {-33.1326447,-40.8928833}}}
debugShowQuadIntersection wtTs[0]=1 {{{41,33}, {41,36.3137093}, {38.6568527,38.6568527}}} {{38.6568527,38.6568527}} wnTs[0]=0 {{{38.6568527,38.6568527}, {36.3137093,41}, {33,41}}}
debugShowQuadIntersection wtTs[0]=0 {{{41,33}, {41,36.3137093}, {38.6568527,38.6568527}}} {{41,33}} wnTs[0]=1 {{{38.6568527,27.3431454}, {41,29.6862907}, {41,33}}}
debugShowQuadIntersection wtTs[0]=1 {{{38.6568527,38.6568527}, {36.3137093,41}, {33,41}}} {{33,41}} wnTs[0]=0 {{{33,41}, {29.6862907,41}, {27.3431454,38.6568527}}}
debugShowQuadIntersection wtTs[0]=1 {{{33,41}, {29.6862907,41}, {27.3431454,38.6568527}}} {{27.3431454,38.6568527}} wnTs[0]=0 {{{27.3431454,38.6568527}, {25,36.3137093}, {25,33}}}
debugShowQuadIntersection wtTs[0]=1 {{{27.3431454,38.6568527}, {25,36.3137093}, {25,33}}} {{25,33}} wnTs[0]=0 {{{25,33}, {25,29.6862907}, {27.3431454,27.3431454}}}
debugShowQuadIntersection wtTs[0]=1 {{{25,33}, {25,29.6862907}, {27.3431454,27.3431454}}} {{27.3431454,27.3431454}} wnTs[0]=0 {{{27.3431454,27.3431454}, {29.6862907,25}, {33,25}}}
debugShowQuadIntersection wtTs[0]=1 {{{27.3431454,27.3431454}, {29.6862907,25}, {33,25}}} {{33,25}} wnTs[0]=0 {{{33,25}, {36.3137093,25}, {38.6568527,27.3431454}}}
debugShowQuadIntersection wtTs[0]=1 {{{33,25}, {36.3137093,25}, {38.6568527,27.3431454}}} {{38.6568527,27.3431454}} wnTs[0]=0 {{{38.6568527,27.3431454}, {41,29.6862907}, {41,33}}}
SkOpSegment::debugShowActiveSpans id=1 (-33.1326447,-40.8928833 -29.8189526,-40.9036179 -27.4682293,-38.5680733) t=0 (-33.1326447,-40.8928833) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=2 (-27.4682293,-38.5680733 -25.117506,-36.2325325 -25.1067715,-32.9188423) t=0 (-27.4682293,-38.5680733) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=3 (-25.1067715,-32.9188423 -25.0960369,-29.6051483 -27.4315796,-27.254425) t=0 (-25.1067715,-32.9188423) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=4 (-27.4315796,-27.254425 -29.7671204,-24.9036999 -33.0808144,-24.8929653) t=0 (-27.4315796,-27.254425) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=5 (-33.0808144,-24.8929653 -36.3945045,-24.8822308 -38.7452278,-27.2177753) t=0 (-33.0808144,-24.8929653) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=6 (-38.7452278,-27.2177753 -41.0959549,-29.5533161 -41.1066895,-32.867012) t=0 (-38.7452278,-27.2177753) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=7 (-41.1066895,-32.867012 -41.117424,-36.1807022 -38.7818794,-38.5314217) t=0 (-41.1066895,-32.867012) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=8 (-38.7818794,-38.5314217 -36.4463348,-40.8821487 -33.1326447,-40.8928833) t=0 (-38.7818794,-38.5314217) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=9 (41,33 41,36.3137093 38.6568527,38.6568527) t=0 (41,33) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=10 (38.6568527,38.6568527 36.3137093,41 33,41) t=0 (38.6568527,38.6568527) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=11 (33,41 29.6862907,41 27.3431454,38.6568527) t=0 (33,41) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=12 (27.3431454,38.6568527 25,36.3137093 25,33) t=0 (27.3431454,38.6568527) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=13 (25,33 25,29.6862907 27.3431454,27.3431454) t=0 (25,33) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=14 (27.3431454,27.3431454 29.6862907,25 33,25) t=0 (27.3431454,27.3431454) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=15 (33,25 36.3137093,25 38.6568527,27.3431454) t=0 (33,25) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=16 (38.6568527,27.3431454 41,29.6862907 41,33) t=0 (38.6568527,27.3431454) tEnd=1 windSum=? windValue=1
SkOpSpan::sortableTop dir=kTop seg=1 t=0.5 pt=(-30.0596943,-40.3170471)
SkOpSpan::sortableTop [0] valid=1 operand=0 span=1 ccw=1 seg=1 {{{-33.1326447f, -40.8928833f}, {-29.8189526f, -40.9036179f}, {-27.4682293f, -38.5680733f}}} t=0.5 pt=(-30.0596943,-40.3170471) slope=(2.83220768,1.16240501)
SkOpSegment::markWinding id=1 (-33.1326447,-40.8928833 -29.8189526,-40.9036179 -27.4682293,-38.5680733) t=0 [1] (-33.1326447,-40.8928833) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
SkOpSegment::markWinding id=2 (-27.4682293,-38.5680733 -25.117506,-36.2325325 -25.1067715,-32.9188423) t=0 [3] (-27.4682293,-38.5680733) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=3 (-25.1067715,-32.9188423 -25.0960369,-29.6051483 -27.4315796,-27.254425) t=0 [5] (-25.1067715,-32.9188423) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=4 (-27.4315796,-27.254425 -29.7671204,-24.9036999 -33.0808144,-24.8929653) t=0 [7] (-27.4315796,-27.254425) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=5 (-33.0808144,-24.8929653 -36.3945045,-24.8822308 -38.7452278,-27.2177753) t=0 [9] (-33.0808144,-24.8929653) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=6 (-38.7452278,-27.2177753 -41.0959549,-29.5533161 -41.1066895,-32.867012) t=0 [11] (-38.7452278,-27.2177753) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=7 (-41.1066895,-32.867012 -41.117424,-36.1807022 -38.7818794,-38.5314217) t=0 [13] (-41.1066895,-32.867012) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=8 (-38.7818794,-38.5314217 -36.4463348,-40.8821487 -33.1326447,-40.8928833) t=0 [15] (-38.7818794,-38.5314217) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=1 (-33.1326447,-40.8928833 -29.8189526,-40.9036179 -27.4682293,-38.5680733) t=0 [1] (-33.1326447,-40.8928833) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
SkOpSegment::activeOp id=1 t=1 tEnd=0 op=union miFrom=0 miTo=1 suFrom=0 suTo=0 result=1
SkOpSegment::findNextOp simple
SkOpSegment::markDone id=1 (-33.1326447,-40.8928833 -29.8189526,-40.9036179 -27.4682293,-38.5680733) t=0 [1] (-33.1326447,-40.8928833) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeOp current id=1 from=(-27.4682293,-38.5680733) to=(-33.1326447,-40.8928833)
path.moveTo(-27.4682293,-38.5680733);
path.quadTo(-29.8189526,-40.9036179, -33.1326447,-40.8928833);
SkOpSegment::findNextOp simple
SkOpSegment::markDone id=8 (-38.7818794,-38.5314217 -36.4463348,-40.8821487 -33.1326447,-40.8928833) t=0 [15] (-38.7818794,-38.5314217) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeOp current id=8 from=(-33.1326447,-40.8928833) to=(-38.7818794,-38.5314217)
path.quadTo(-36.4463348,-40.8821487, -38.7818794,-38.5314217);
SkOpSegment::findNextOp simple
SkOpSegment::markDone id=7 (-41.1066895,-32.867012 -41.117424,-36.1807022 -38.7818794,-38.5314217) t=0 [13] (-41.1066895,-32.867012) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeOp current id=7 from=(-38.7818794,-38.5314217) to=(-41.1066895,-32.867012)
path.quadTo(-41.117424,-36.1807022, -41.1066895,-32.867012);
SkOpSegment::findNextOp simple
SkOpSegment::markDone id=6 (-38.7452278,-27.2177753 -41.0959549,-29.5533161 -41.1066895,-32.867012) t=0 [11] (-38.7452278,-27.2177753) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeOp current id=6 from=(-41.1066895,-32.867012) to=(-38.7452278,-27.2177753)
path.quadTo(-41.0959549,-29.5533161, -38.7452278,-27.2177753);
SkOpSegment::findNextOp simple
SkOpSegment::markDone id=5 (-33.0808144,-24.8929653 -36.3945045,-24.8822308 -38.7452278,-27.2177753) t=0 [9] (-33.0808144,-24.8929653) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeOp current id=5 from=(-38.7452278,-27.2177753) to=(-33.0808144,-24.8929653)
path.quadTo(-36.3945045,-24.8822308, -33.0808144,-24.8929653);
SkOpSegment::findNextOp simple
SkOpSegment::markDone id=4 (-27.4315796,-27.254425 -29.7671204,-24.9036999 -33.0808144,-24.8929653) t=0 [7] (-27.4315796,-27.254425) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeOp current id=4 from=(-33.0808144,-24.8929653) to=(-27.4315796,-27.254425)
path.quadTo(-29.7671204,-24.9036999, -27.4315796,-27.254425);
SkOpSegment::findNextOp simple
SkOpSegment::markDone id=3 (-25.1067715,-32.9188423 -25.0960369,-29.6051483 -27.4315796,-27.254425) t=0 [5] (-25.1067715,-32.9188423) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeOp current id=3 from=(-27.4315796,-27.254425) to=(-25.1067715,-32.9188423)
path.quadTo(-25.0960369,-29.6051483, -25.1067715,-32.9188423);
SkOpSegment::findNextOp simple
SkOpSegment::markDone id=2 (-27.4682293,-38.5680733 -25.117506,-36.2325325 -25.1067715,-32.9188423) t=0 [3] (-27.4682293,-38.5680733) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeOp current id=2 from=(-25.1067715,-32.9188423) to=(-27.4682293,-38.5680733)
path.quadTo(-25.117506,-36.2325325, -27.4682293,-38.5680733);
path.close();
SkOpSegment::debugShowActiveSpans id=9 (41,33 41,36.3137093 38.6568527,38.6568527) t=0 (41,33) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=10 (38.6568527,38.6568527 36.3137093,41 33,41) t=0 (38.6568527,38.6568527) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=11 (33,41 29.6862907,41 27.3431454,38.6568527) t=0 (33,41) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=12 (27.3431454,38.6568527 25,36.3137093 25,33) t=0 (27.3431454,38.6568527) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=13 (25,33 25,29.6862907 27.3431454,27.3431454) t=0 (25,33) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=14 (27.3431454,27.3431454 29.6862907,25 33,25) t=0 (27.3431454,27.3431454) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=15 (33,25 36.3137093,25 38.6568527,27.3431454) t=0 (33,25) tEnd=1 windSum=? windValue=1
SkOpSegment::debugShowActiveSpans id=16 (38.6568527,27.3431454 41,29.6862907 41,33) t=0 (38.6568527,27.3431454) tEnd=1 windSum=? windValue=1
SkOpSpan::sortableTop dir=kLeft seg=9 t=0.5 pt=(40.4142151,36.0710678)
SkOpSpan::sortableTop [0] valid=1 operand=1 span=23 ccw=1 seg=12 {{{27.3431454f, 38.6568527f}, {25, 36.3137093f}, {25, 33}}} t=0.5 pt=(25.5857868,36.0710678) slope=(-1.17157269,-2.82842636)
SkOpSpan::sortableTop [1] valid=1 operand=1 span=17 ccw=0 seg=9 {{{41, 33}, {41, 36.3137093f}, {38.6568527f, 38.6568527f}}} t=0.5 pt=(40.4142151,36.0710678) slope=(-1.17157364,2.82842636)
SkOpSegment::markWinding id=12 (27.3431454,38.6568527 25,36.3137093 25,33) t=0 [23] (27.3431454,38.6568527) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
SkOpSegment::markWinding id=13 (25,33 25,29.6862907 27.3431454,27.3431454) t=0 [25] (25,33) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=14 (27.3431454,27.3431454 29.6862907,25 33,25) t=0 [27] (27.3431454,27.3431454) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=15 (33,25 36.3137093,25 38.6568527,27.3431454) t=0 [29] (33,25) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=16 (38.6568527,27.3431454 41,29.6862907 41,33) t=0 [31] (38.6568527,27.3431454) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=9 (41,33 41,36.3137093 38.6568527,38.6568527) t=0 [17] (41,33) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=10 (38.6568527,38.6568527 36.3137093,41 33,41) t=0 [19] (38.6568527,38.6568527) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=11 (33,41 29.6862907,41 27.3431454,38.6568527) t=0 [21] (33,41) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=? windSum=? windValue=1 oppValue=0
SkOpSegment::markWinding id=12 (27.3431454,38.6568527 25,36.3137093 25,33) t=0 [23] (27.3431454,38.6568527) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
SkOpSegment::activeOp id=9 t=1 tEnd=0 op=union miFrom=0 miTo=0 suFrom=0 suTo=1 result=1
SkOpSegment::findNextOp simple
SkOpSegment::markDone id=9 (41,33 41,36.3137093 38.6568527,38.6568527) t=0 [17] (41,33) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeOp current id=9 from=(38.6568527,38.6568527) to=(41,33)
path.moveTo(38.6568527,38.6568527);
path.quadTo(41,36.3137093, 41,33);
SkOpSegment::findNextOp simple
SkOpSegment::markDone id=16 (38.6568527,27.3431454 41,29.6862907 41,33) t=0 [31] (38.6568527,27.3431454) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeOp current id=16 from=(41,33) to=(38.6568527,27.3431454)
path.quadTo(41,29.6862907, 38.6568527,27.3431454);
SkOpSegment::findNextOp simple
SkOpSegment::markDone id=15 (33,25 36.3137093,25 38.6568527,27.3431454) t=0 [29] (33,25) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeOp current id=15 from=(38.6568527,27.3431454) to=(33,25)
path.quadTo(36.3137093,25, 33,25);
SkOpSegment::findNextOp simple
SkOpSegment::markDone id=14 (27.3431454,27.3431454 29.6862907,25 33,25) t=0 [27] (27.3431454,27.3431454) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeOp current id=14 from=(33,25) to=(27.3431454,27.3431454)
path.quadTo(29.6862907,25, 27.3431454,27.3431454);
SkOpSegment::findNextOp simple
SkOpSegment::markDone id=13 (25,33 25,29.6862907 27.3431454,27.3431454) t=0 [25] (25,33) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeOp current id=13 from=(27.3431454,27.3431454) to=(25,33)
path.quadTo(25,29.6862907, 25,33);
SkOpSegment::findNextOp simple
SkOpSegment::markDone id=12 (27.3431454,38.6568527 25,36.3137093 25,33) t=0 [23] (27.3431454,38.6568527) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeOp current id=12 from=(25,33) to=(27.3431454,38.6568527)
path.quadTo(25,36.3137093, 27.3431454,38.6568527);
SkOpSegment::findNextOp simple
SkOpSegment::markDone id=11 (33,41 29.6862907,41 27.3431454,38.6568527) t=0 [21] (33,41) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeOp current id=11 from=(27.3431454,38.6568527) to=(33,41)
path.quadTo(29.6862907,41, 33,41);
SkOpSegment::findNextOp simple
SkOpSegment::markDone id=10 (38.6568527,38.6568527 36.3137093,41 33,41) t=0 [19] (38.6568527,38.6568527) tEnd=1 newWindSum=-1 newOppSum=0 oppSum=0 windSum=-1 windValue=1 oppValue=0
bridgeOp current id=10 from=(33,41) to=(38.6568527,38.6568527)
path.quadTo(36.3137093,41, 38.6568527,38.6568527);
path.close();
</div>
</div>
<script type="text/javascript">
var testDivs = [
fuzz763_4713_b,
fuzz763_4713parts,
];
var decimal_places = 3; // make this 3 to show more precision
var tests = [];
var testLines = [];
var testTitles = [];
var testIndex = 0;
var ctx;
var xmin, xmax, focusXmin, focusXmax;
var ymin, ymax, focusYmin, focusYmax;
var scale;
var mouseX, mouseY;
var srcLeft, srcTop;
var screenWidth, screenHeight;
var drawnPts, drawnLines, drawnQuads, drawnConics, drawnCubics;
var curveT = 0;
var pt_labels = 2;
var collect_bounds = false;
var control_lines = 0;
var curve_t = false;
var debug_xy = 1;
var focus_enabled = false;
var focus_on_selection = false;
var step_limit = 0;
var draw_active = false;
var draw_add = false;
var draw_angle = 0;
var draw_coincidence = false;
var draw_deriviatives = 0;
var draw_hints = false;
var draw_id = false;
var draw_intersection = 0;
var draw_intersectT = false;
var draw_legend = true;
var draw_log = false;
var draw_mark = false;
var draw_midpoint = false;
var draw_op = 0;
var draw_sequence = false;
var draw_sort = 0;
var draw_top = false;
var draw_path = 3;
var draw_computed = 0;
var retina_scale = !!window.devicePixelRatio;
var activeCount = 0;
var addCount = 0;
var angleCount = 0;
var coinCount = 0;
var opCount = 0;
var sectCount = 0;
var sortCount = 0;
var topCount = 0;
var markCount = 0;
var activeMax = 0;
var addMax = 0;
var angleMax = 0;
var coinMax = 0;
var sectMax = 0;
var sectMax2 = 0;
var sortMax = 0;
var topMax = 0;
var markMax = 0;
var opMax = 0;
var stepMax = 0;
var lastIndex = 0;
var hasPath = false;
var hasAlignedPath = false;
var hasComputedPath = false;
var angleBetween = false;
var afterIndex = 0;
var firstActiveSpan = -1;
var logStart = -1;
var logRange = 0;
var SPAN_ID = 0;
var SPAN_X1 = SPAN_ID + 1;
var SPAN_Y1 = SPAN_X1 + 1;
var SPAN_X2 = SPAN_Y1 + 1;
var SPAN_Y2 = SPAN_X2 + 1;
var SPAN_L_T = SPAN_Y2 + 1;
var SPAN_L_TX = SPAN_L_T + 1;
var SPAN_L_TY = SPAN_L_TX + 1;
var SPAN_L_TEND = SPAN_L_TY + 1;
var SPAN_L_OTHER = SPAN_L_TEND + 1;
var SPAN_L_OTHERT = SPAN_L_OTHER + 1;
var SPAN_L_OTHERI = SPAN_L_OTHERT + 1;
var SPAN_L_SUM = SPAN_L_OTHERI + 1;
var SPAN_L_VAL = SPAN_L_SUM + 1;
var SPAN_L_OPP = SPAN_L_VAL + 1;
var SPAN_X3 = SPAN_Y2 + 1;
var SPAN_Y3 = SPAN_X3 + 1;
var SPAN_Q_T = SPAN_Y3 + 1;
var SPAN_Q_TX = SPAN_Q_T + 1;
var SPAN_Q_TY = SPAN_Q_TX + 1;
var SPAN_Q_TEND = SPAN_Q_TY + 1;
var SPAN_Q_OTHER = SPAN_Q_TEND + 1;
var SPAN_Q_OTHERT = SPAN_Q_OTHER + 1;
var SPAN_Q_OTHERI = SPAN_Q_OTHERT + 1;
var SPAN_Q_SUM = SPAN_Q_OTHERI + 1;
var SPAN_Q_VAL = SPAN_Q_SUM + 1;
var SPAN_Q_OPP = SPAN_Q_VAL + 1;
var SPAN_K_W = SPAN_Y3 + 1;
var SPAN_K_T = SPAN_K_W + 1;
var SPAN_K_TX = SPAN_K_T + 1;
var SPAN_K_TY = SPAN_K_TX + 1;
var SPAN_K_TEND = SPAN_K_TY + 1;
var SPAN_K_OTHER = SPAN_K_TEND + 1;
var SPAN_K_OTHERT = SPAN_K_OTHER + 1;
var SPAN_K_OTHERI = SPAN_K_OTHERT + 1;
var SPAN_K_SUM = SPAN_K_OTHERI + 1;
var SPAN_K_VAL = SPAN_K_SUM + 1;
var SPAN_K_OPP = SPAN_K_VAL + 1;
var SPAN_X4 = SPAN_Y3 + 1;
var SPAN_Y4 = SPAN_X4 + 1;
var SPAN_C_T = SPAN_Y4 + 1;
var SPAN_C_TX = SPAN_C_T + 1;
var SPAN_C_TY = SPAN_C_TX + 1;
var SPAN_C_TEND = SPAN_C_TY + 1;
var SPAN_C_OTHER = SPAN_C_TEND + 1;
var SPAN_C_OTHERT = SPAN_C_OTHER + 1;
var SPAN_C_OTHERI = SPAN_C_OTHERT + 1;
var SPAN_C_SUM = SPAN_C_OTHERI + 1;
var SPAN_C_VAL = SPAN_C_SUM + 1;
var SPAN_C_OPP = SPAN_C_VAL + 1;
var ACTIVE_LINE_SPAN = 1;
var ACTIVE_QUAD_SPAN = ACTIVE_LINE_SPAN + 1;
var ACTIVE_CONIC_SPAN = ACTIVE_QUAD_SPAN + 1;
var ACTIVE_CUBIC_SPAN = ACTIVE_CONIC_SPAN + 1;
var ADD_MOVETO = ACTIVE_CUBIC_SPAN + 1;
var ADD_LINETO = ADD_MOVETO + 1;
var ADD_QUADTO = ADD_LINETO + 1;
var ADD_CONICTO = ADD_QUADTO + 1;
var ADD_CUBICTO = ADD_CONICTO + 1;
var ADD_CLOSE = ADD_CUBICTO + 1;
var ADD_FILL = ADD_CLOSE + 1;
var PATH_LINE = ADD_FILL + 1;
var PATH_QUAD = PATH_LINE + 1;
var PATH_CONIC = PATH_QUAD + 1;
var PATH_CUBIC = PATH_CONIC + 1;
var INTERSECT_LINE = PATH_CUBIC + 1;
var INTERSECT_LINE_2 = INTERSECT_LINE + 1;
var INTERSECT_LINE_NO = INTERSECT_LINE_2 + 1;
var INTERSECT_QUAD_LINE = INTERSECT_LINE_NO + 1;
var INTERSECT_QUAD_LINE_2 = INTERSECT_QUAD_LINE + 1;
var INTERSECT_QUAD_LINE_NO = INTERSECT_QUAD_LINE_2 + 1;
var INTERSECT_QUAD = INTERSECT_QUAD_LINE_NO + 1;
var INTERSECT_QUAD_2 = INTERSECT_QUAD + 1;
var INTERSECT_QUAD_NO = INTERSECT_QUAD_2 + 1;
var INTERSECT_CONIC_LINE = INTERSECT_QUAD_NO + 1;
var INTERSECT_CONIC_LINE_2 = INTERSECT_CONIC_LINE + 1;
var INTERSECT_CONIC_LINE_NO = INTERSECT_CONIC_LINE_2 + 1;
var INTERSECT_CONIC = INTERSECT_CONIC_LINE_NO + 1;
var INTERSECT_CONIC_2 = INTERSECT_CONIC + 1;
var INTERSECT_CONIC_NO = INTERSECT_CONIC_2 + 1;
var INTERSECT_SELF_CUBIC = INTERSECT_CONIC_NO + 1;
var INTERSECT_SELF_CUBIC_NO = INTERSECT_SELF_CUBIC + 1;
var INTERSECT_CUBIC_LINE = INTERSECT_SELF_CUBIC_NO + 1;
var INTERSECT_CUBIC_LINE_2 = INTERSECT_CUBIC_LINE + 1;
var INTERSECT_CUBIC_LINE_3 = INTERSECT_CUBIC_LINE_2 + 1;
var INTERSECT_CUBIC_LINE_NO = INTERSECT_CUBIC_LINE_3 + 1;
var INTERSECT_CUBIC_QUAD = INTERSECT_CUBIC_LINE_NO + 1;
var INTERSECT_CUBIC_QUAD_2 = INTERSECT_CUBIC_QUAD + 1;
var INTERSECT_CUBIC_QUAD_3 = INTERSECT_CUBIC_QUAD_2 + 1;
var INTERSECT_CUBIC_QUAD_4 = INTERSECT_CUBIC_QUAD_3 + 1;
var INTERSECT_CUBIC_QUAD_NO = INTERSECT_CUBIC_QUAD_4 + 1;
var INTERSECT_CUBIC = INTERSECT_CUBIC_QUAD_NO + 1;
var INTERSECT_CUBIC_2 = INTERSECT_CUBIC + 1;
var INTERSECT_CUBIC_3 = INTERSECT_CUBIC_2 + 1;
var INTERSECT_CUBIC_4 = INTERSECT_CUBIC_3 + 1;
// FIXME: add cubic 5- 9
var INTERSECT_CUBIC_NO = INTERSECT_CUBIC_4 + 1;
var SORT_UNARY = INTERSECT_CUBIC_NO + 1;
var SORT_BINARY = SORT_UNARY + 1;
var OP_DIFFERENCE = SORT_BINARY + 1;
var OP_INTERSECT = OP_DIFFERENCE + 1;
var OP_UNION = OP_INTERSECT + 1;
var OP_XOR = OP_UNION + 1;
var MARK_LINE = OP_XOR + 1;
var MARK_QUAD = MARK_LINE + 1;
var MARK_CONIC = MARK_QUAD + 1;
var MARK_CUBIC = MARK_CONIC + 1;
var MARK_DONE_LINE = MARK_CUBIC + 1;
var MARK_DONE_QUAD = MARK_DONE_LINE + 1;
var MARK_DONE_CONIC = MARK_DONE_QUAD + 1;
var MARK_DONE_CUBIC = MARK_DONE_CONIC + 1;
var MARK_UNSORTABLE_LINE = MARK_DONE_CUBIC + 1;
var MARK_UNSORTABLE_QUAD = MARK_UNSORTABLE_LINE + 1;
var MARK_UNSORTABLE_CONIC = MARK_UNSORTABLE_QUAD + 1;
var MARK_UNSORTABLE_CUBIC = MARK_UNSORTABLE_CONIC + 1;
var MARK_SIMPLE_LINE = MARK_UNSORTABLE_CUBIC + 1;
var MARK_SIMPLE_QUAD = MARK_SIMPLE_LINE + 1;
var MARK_SIMPLE_CONIC = MARK_SIMPLE_QUAD + 1;
var MARK_SIMPLE_CUBIC = MARK_SIMPLE_CONIC + 1;
var MARK_SIMPLE_DONE_LINE = MARK_SIMPLE_CUBIC + 1;
var MARK_SIMPLE_DONE_QUAD = MARK_SIMPLE_DONE_LINE + 1;
var MARK_SIMPLE_DONE_CONIC = MARK_SIMPLE_DONE_QUAD + 1;
var MARK_SIMPLE_DONE_CUBIC = MARK_SIMPLE_DONE_CONIC + 1;
var MARK_DONE_UNARY_LINE = MARK_SIMPLE_DONE_CUBIC + 1;
var MARK_DONE_UNARY_QUAD = MARK_DONE_UNARY_LINE + 1;
var MARK_DONE_UNARY_CONIC = MARK_DONE_UNARY_QUAD + 1;
var MARK_DONE_UNARY_CUBIC = MARK_DONE_UNARY_CONIC + 1;
var MARK_ANGLE_LAST = MARK_DONE_UNARY_CUBIC + 1;
var COMPUTED_SET_1 = MARK_ANGLE_LAST + 1;
var COMPUTED_SET_2 = COMPUTED_SET_1 + 1;
var ANGLE_AFTER = COMPUTED_SET_2 + 1;
var ANGLE_AFTERPART = ANGLE_AFTER + 1;
var ACTIVE_OP = ANGLE_AFTERPART + 1;
var COIN_MAIN_SPAN = ACTIVE_OP + 1;
var COIN_OPP_SPAN = COIN_MAIN_SPAN + 1;
var FRAG_TYPE_LAST = COIN_OPP_SPAN;
var REC_TYPE_UNKNOWN = -1;
var REC_TYPE_PATH = 0;
var REC_TYPE_PATH2 = 1;
var REC_TYPE_SECT = 2;
var REC_TYPE_ACTIVE = 3;
var REC_TYPE_ADD = 4;
var REC_TYPE_SORT = 5;
var REC_TYPE_OP = 6;
var REC_TYPE_MARK = 7;
var REC_TYPE_COMPUTED = 8;
var REC_TYPE_COIN = 9;
var REC_TYPE_ANGLE = 10;
var REC_TYPE_ACTIVE_OP = 11;
var REC_TYPE_AFTERPART = 12;
var REC_TYPE_TOP = 13;
var REC_TYPE_COINCIDENCE = 14;
var REC_TYPE_ALIGNED = 15;
var REC_TYPE_LAST = REC_TYPE_ALIGNED;
function strs_to_nums(strs) {
var result = [];
for (var idx = 1; idx < strs.length; ++idx) {
var str = strs[idx];
var num = parseFloat(str);
if (isNaN(num)) {
result.push(str);
} else {
result.push(num);
}
}
return result;
}
function filter_str_by(id, str, regex, array) {
if (regex.test(str)) {
var strs = regex.exec(str);
var result = strs_to_nums(strs);
array.push(id);
array.push(result);
return true;
}
return false;
}
function construct_regexp2(pattern) {
var escape = pattern.replace(/[-/\\^$*+?.()|[\]{}]/g, '\\$&');
escape = escape.replace(/UNSORTABLE/g, "\\*\\*\\* UNSORTABLE \\*\\*\\*");
escape = escape.replace(/CUBIC_VAL/g, "\\(P_VAL P_VAL P_VAL P_VAL\\)");
escape = escape.replace(/CONIC_VAL/g, "\\(P_VAL P_VAL P_VAL W_VAL\\)");
escape = escape.replace(/QUAD_VAL/g, "\\(P_VAL P_VAL P_VAL\\)");
escape = escape.replace(/LINE_VAL/g, "\\(P_VAL P_VAL\\)");
escape = escape.replace(/FILL_TYPE/g, "SkPath::k[a-zA-Z]+_FillType");
escape = escape.replace(/PTR_VAL/g, "0x[0-9A-F]+");
escape = escape.replace(/PT_VAL/g, "\\(P_VAL\\)");
escape = escape.replace(/P_VAL/g, "(-?\\d+\\.?\\d*(?:e-?\\d+)?)[Ff]?, ?(-?\\d+\\.?\\d*(?:e-?\\d+)?)[Ff]?");
escape = escape.replace(/T_VAL/g, "(-?\\d+\\.?\\d*(?:e-?\\d+)?)");
escape = escape.replace(/W_VAL/g, "(-?\\d+\\.?\\d*(?:e-?\\d+)?)[Ff]?");
escape = escape.replace(/PATH/g, "pathB?");
escape = escape.replace(/IDX/g, "(-?\\d+)");
escape = escape.replace(/NUM/g, "(-?\\d+)");
escape = escape.replace(/OPT/g, "(\\?|-?\\d+)");
return new RegExp(escape, 'i');
}
function construct_regexp2c(pattern) {
var escape = pattern.replace(/[-/\\^$*+?.()|[\]{}]/g, '\\$&');
escape = escape.replace(/UNSORTABLE/g, "\\*\\*\\* UNSORTABLE \\*\\*\\*");
escape = escape.replace(/CUBIC_VAL/g, "(?:\\$\\d = )?\\{\\{\\{P_VAL\\}, \\{P_VAL\\}, \\{P_VAL\\}, \\{P_VAL\\}\\}\\}");
escape = escape.replace(/CONIC_VAL/g, "(?:\\$\\d = )?\\{\\{\\{\\{P_VAL\\}, \\{P_VAL\\}, \\{P_VAL\\}\\}\\}, W_VAL\\}");
escape = escape.replace(/QUAD_VAL/g, "(?:\\$\\d = )?\\{\\{\\{P_VAL\\}, \\{P_VAL\\}, \\{P_VAL\\}\\}\\}");
escape = escape.replace(/LINE_VAL/g, "(?:\\$\\d = )?\\{\\{\\{P_VAL\\}, \\{P_VAL\\}\\}\\}");
escape = escape.replace(/FILL_TYPE/g, "SkPath::k[a-zA-Z]+_FillType");
escape = escape.replace(/PTR_VAL/g, "0x[0-9A-F]+");
escape = escape.replace(/PT_VAL/g, "\\{\\{P_VAL\\}\\}");
escape = escape.replace(/P_VAL/g, "(?:f?[xX] = )?(-?\\d+\\.?\\d*(?:e-?\\d+)?)[Ff]?, *(?: f?[yY] = )?(-?\\d+\\.?\\d*(?:e-?\\d+)?)[Ff]?");
escape = escape.replace(/T_VAL/g, "(-?\\d+\\.?\\d*(?:e-?\\d+)?)");
escape = escape.replace(/W_VAL/g, "(-?\\d+\\.?\\d*(?:e-?\\d+)?)[Ff]?");
escape = escape.replace(/OPER/g, "[a-z]+");
escape = escape.replace(/PATH/g, "pathB?");
escape = escape.replace(/T_F/g, "([TF])");
escape = escape.replace(/IDX/g, "(-?\\d+)");
escape = escape.replace(/NUM/g, "(-?\\d+)");
escape = escape.replace(/OPT/g, "(\\?|-?\\d+)");
return new RegExp(escape, 'i');
}
function match_regexp(str, lineNo, array, id, pattern) {
var regex = construct_regexp2(pattern);
if (filter_str_by(id, str, regex, array)) {
return true;
}
regex = construct_regexp2c(pattern);
return filter_str_by(id, str, regex, array);
}
function endsWith(str, suffix) {
return str.indexOf(suffix, str.length - suffix.length) !== -1;
}
function parse_all(test) {
var lines = test.match(/[^\r\n]+/g);
var records = []; // a rec can be the original paths, a set of intersections, a set of active spans, a sort, or a path add
var record = [];
var recType = REC_TYPE_UNKNOWN;
var lastLineNo;
var moveX, moveY;
for (var lineNo = 0; lineNo < lines.length; ++lineNo) {
var line = lines[lineNo];
if (line.length == 0) {
continue;
}
var opStart = "SkOpSegment::";
if (line.lastIndexOf(opStart, 0) === 0) {
line = line.substr(opStart.length);
}
var angleStart = "SkOpAngle::";
if (line.lastIndexOf(angleStart, 0) === 0) {
line = line.substr(angleStart.length);
}
var coinStart = "SkOpCoincidence::";
if (line.lastIndexOf(coinStart, 0) === 0) {
line = line.substr(coinStart.length);
}
var type = line.lastIndexOf("debugShowActiveSpans", 0) === 0 ? REC_TYPE_ACTIVE
: line.lastIndexOf("debugShowCoincidence", 0) === 0 ? REC_TYPE_COINCIDENCE
: line.lastIndexOf("((SkOpSegment*)", 0) === 0 ? REC_TYPE_PATH2
: line.lastIndexOf("debugShowTs", 0) === 0 ? REC_TYPE_COIN
: line.lastIndexOf("afterPart", 0) === 0 ? REC_TYPE_AFTERPART
: line.lastIndexOf("debugShow", 0) === 0 ? REC_TYPE_SECT
: line.lastIndexOf("activeOp", 0) === 0 ? REC_TYPE_ACTIVE_OP
: line.lastIndexOf("computed", 0) === 0 ? REC_TYPE_COMPUTED
: line.lastIndexOf("debugOne", 0) === 0 ? REC_TYPE_SORT
: line.lastIndexOf("aligned=", 0) === 0 ? REC_TYPE_ALIGNED
: line.lastIndexOf("dumpOne", 0) === 0 ? REC_TYPE_SORT
: line.lastIndexOf("findTop", 0) === 0 ? REC_TYPE_TOP
: line.lastIndexOf("pathB.", 0) === 0 ? REC_TYPE_ADD
: line.lastIndexOf("path.", 0) === 0 ? REC_TYPE_ADD
: line.lastIndexOf("after", 0) === 0 ? REC_TYPE_ANGLE
: line.lastIndexOf("mark", 0) === 0 ? REC_TYPE_MARK
: line.lastIndexOf(" {{", 0) === 0 ? REC_TYPE_COMPUTED
: line.lastIndexOf("seg=", 0) === 0 ? REC_TYPE_PATH
: line.lastIndexOf("op", 0) === 0 ? REC_TYPE_OP
: line.lastIndexOf("$", 0) === 0 ? REC_TYPE_PATH
: REC_TYPE_UNKNOWN;
if (recType != type || recType == REC_TYPE_ADD || recType == REC_TYPE_SECT
|| recType == REC_TYPE_ACTIVE_OP || recType == REC_TYPE_ANGLE) {
if (recType != REC_TYPE_UNKNOWN) {
records.push(recType);
records.push(lastLineNo);
records.push(record);
}
record = [];
recType = type;
lastLineNo = lineNo;
}
var found = false;
switch (recType) {
case REC_TYPE_ACTIVE:
found = match_regexp(line, lineNo, record, ACTIVE_LINE_SPAN, "debugShowActiveSpans" +
" id=IDX LINE_VAL t=T_VAL PT_VAL tEnd=T_VAL windSum=OPT windValue=IDX"
) || match_regexp(line, lineNo, record, ACTIVE_QUAD_SPAN, "debugShowActiveSpans" +
" id=IDX QUAD_VAL t=T_VAL PT_VAL tEnd=T_VAL windSum=OPT windValue=IDX"
) || match_regexp(line, lineNo, record, ACTIVE_CONIC_SPAN, "debugShowActiveSpans" +
" id=IDX CONIC_VAL t=T_VAL PT_VAL tEnd=T_VAL windSum=OPT windValue=IDX"
) || match_regexp(line, lineNo, record, ACTIVE_CUBIC_SPAN, "debugShowActiveSpans" +
" id=IDX CUBIC_VAL t=T_VAL PT_VAL tEnd=T_VAL windSum=OPT windValue=IDX"
) || match_regexp(line, lineNo, record, ACTIVE_LINE_SPAN, "debugShowActiveSpans" +
" id=IDX LINE_VAL t=T_VAL PT_VAL tEnd=T_VAL windSum=OPT oppSum=OPT windValue=IDX oppValue=NUM"
) || match_regexp(line, lineNo, record, ACTIVE_QUAD_SPAN, "debugShowActiveSpans" +
" id=IDX QUAD_VAL t=T_VAL PT_VAL tEnd=T_VAL windSum=OPT oppSum=OPT windValue=IDX oppValue=NUM"
) || match_regexp(line, lineNo, record, ACTIVE_CONIC_SPAN, "debugShowActiveSpans" +
" id=IDX CONIC_VAL t=T_VAL PT_VAL tEnd=T_VAL windSum=OPT oppSum=OPT windValue=IDX oppValue=NUM"
) || match_regexp(line, lineNo, record, ACTIVE_CUBIC_SPAN, "debugShowActiveSpans" +
" id=IDX CUBIC_VAL t=T_VAL PT_VAL tEnd=T_VAL windSum=OPT oppSum=OPT windValue=IDX oppValue=NUM"
);
break;
case REC_TYPE_ACTIVE_OP:
found = match_regexp(line, lineNo, record, ACTIVE_OP, "activeOp" +
" id=IDX t=T_VAL tEnd=T_VAL op=OPER miFrom=NUM miTo=NUM suFrom=NUM suTo=NUM result=IDX"
);
break;
case REC_TYPE_ADD:
if (match_regexp(line, lineNo, record, ADD_MOVETO, "PATH.moveTo(P_VAL);")) {
moveX = record[1][0];
moveY = record[1][1];
found = true;
} else if (match_regexp(line, lineNo, record, ADD_LINETO, "PATH.lineTo(P_VAL);")) {
record[1].unshift(moveY);
record[1].unshift(moveX);
moveX = record[1][2];
moveY = record[1][3];
found = true;
} else if (match_regexp(line, lineNo, record, ADD_QUADTO, "PATH.quadTo(P_VAL, P_VAL);")) {
record[1].unshift(moveY);
record[1].unshift(moveX);
moveX = record[1][4];
moveY = record[1][5];
found = true;
} else if (match_regexp(line, lineNo, record, ADD_CONICTO, "PATH.conicTo(P_VAL, P_VAL, T_VAL);")) {
record[1].unshift(moveY);
record[1].unshift(moveX);
moveX = record[1][4];
moveY = record[1][5];
found = true;
} else if (match_regexp(line, lineNo, record, ADD_CUBICTO, "PATH.cubicTo(P_VAL, P_VAL, P_VAL);")) {
record[1].unshift(moveY);
record[1].unshift(moveX);
moveX = record[1][6];
moveY = record[1][7];
found = true;
} else if (match_regexp(line, lineNo, record, ADD_FILL, "PATH.setFillType(FILL_TYPE);")) {
found = true;
} else {
found = match_regexp(line, lineNo, record, ADD_CLOSE, "PATH.close();");
}
break;
case REC_TYPE_AFTERPART:
found = match_regexp(line, lineNo, record, PATH_LINE, "afterPart LINE_VAL")
|| match_regexp(line, lineNo, record, PATH_QUAD, "afterPart QUAD_VAL")
|| match_regexp(line, lineNo, record, PATH_CONIC, "afterPart CONIC_VAL")
|| match_regexp(line, lineNo, record, PATH_CUBIC, "afterPart CUBIC_VAL")
break;
case REC_TYPE_ALIGNED:
found = match_regexp(line, lineNo, record, PATH_LINE, "aligned=IDX LINE_VAL"
) || match_regexp(line, lineNo, record, PATH_QUAD, "aligned=IDX QUAD_VAL"
) || match_regexp(line, lineNo, record, PATH_CONIC, "aligned=IDX CONIC_VAL"
) || match_regexp(line, lineNo, record, PATH_CUBIC, "aligned=IDX CUBIC_VAL"
);
break;
case REC_TYPE_ANGLE:
found = match_regexp(line, lineNo, record, ANGLE_AFTER, "after " +
"[IDX/IDX] NUM/NUM tStart=T_VAL tEnd=T_VAL < [IDX/IDX] NUM/NUM tStart=T_VAL tEnd=T_VAL < [IDX/IDX] NUM/NUM tStart=T_VAL tEnd=T_VAL T_F IDX");
break;
case REC_TYPE_COIN:
found = true;
break;
case REC_TYPE_COINCIDENCE:
found = match_regexp(line, lineNo, record, COIN_MAIN_SPAN, "debugShowCoincidence" +
" + id=IDX t=T_VAL tEnd=T_VAL"
) || match_regexp(line, lineNo, record, COIN_OPP_SPAN, "debugShowCoincidence" +
" - id=IDX t=T_VAL tEnd=T_VAL"
);
break;
case REC_TYPE_COMPUTED:
found = line == "computed quadratics given"
|| match_regexp(line, lineNo, record, COMPUTED_SET_1, "computed quadratics set 1"
) || match_regexp(line, lineNo, record, COMPUTED_SET_2, "computed quadratics set 2"
) || match_regexp(line, lineNo, record, PATH_QUAD, " QUAD_VAL,"
) || match_regexp(line, lineNo, record, PATH_CONIC, " CONIC_VAL,"
) || match_regexp(line, lineNo, record, PATH_CUBIC, " CUBIC_VAL,"
);
break;
case REC_TYPE_PATH:
found = match_regexp(line, lineNo, record, PATH_LINE, "seg=IDX LINE_VAL"
) || match_regexp(line, lineNo, record, PATH_QUAD, "seg=IDX QUAD_VAL"
) || match_regexp(line, lineNo, record, PATH_CONIC, "seg=IDX CONIC_VAL"
) || match_regexp(line, lineNo, record, PATH_CUBIC, "seg=IDX CUBIC_VAL"
);
break;
case REC_TYPE_PATH2:
found = match_regexp(line, lineNo, record, PATH_LINE, "((SkOpSegment*) PTR_VAL) [IDX] {LINE_VAL}"
) || match_regexp(line, lineNo, record, PATH_QUAD, "((SkOpSegment*) PTR_VAL) [IDX] {QUAD_VAL}"
) || match_regexp(line, lineNo, record, PATH_CONIC, "((SkOpSegment*) PTR_VAL) [IDX] {CONIC_VAL}"
) || match_regexp(line, lineNo, record, PATH_CUBIC, "((SkOpSegment*) PTR_VAL) [IDX] {CUBIC_VAL}"
);
break;
case REC_TYPE_SECT:
found = match_regexp(line, lineNo, record, INTERSECT_LINE, "debugShowLineIntersection" +
" wtTs[0]=T_VAL LINE_VAL PT_VAL wnTs[0]=T_VAL LINE_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_LINE_2, "debugShowLineIntersection" +
" wtTs[0]=T_VAL LINE_VAL PT_VAL wtTs[1]=T_VAL PT_VAL wnTs[0]=T_VAL LINE_VAL wnTs[1]=T_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_LINE_NO, "debugShowLineIntersection" +
" no intersect LINE_VAL LINE_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_QUAD_LINE, "debugShowQuadLineIntersection" +
" wtTs[0]=T_VAL QUAD_VAL PT_VAL wnTs[0]=T_VAL LINE_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_QUAD_LINE_2, "debugShowQuadLineIntersection" +
" wtTs[0]=T_VAL QUAD_VAL PT_VAL wtTs[1]=T_VAL PT_VAL wnTs[0]=T_VAL LINE_VAL wnTs[1]=T_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_QUAD_LINE_NO, "debugShowQuadLineIntersection" +
" no intersect QUAD_VAL LINE_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_QUAD, "debugShowQuadIntersection" +
" wtTs[0]=T_VAL QUAD_VAL PT_VAL wnTs[0]=T_VAL QUAD_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_QUAD_2, "debugShowQuadIntersection" +
" wtTs[0]=T_VAL QUAD_VAL PT_VAL wtTs[1]=T_VAL PT_VAL wnTs[0]=T_VAL QUAD_VAL wnTs[1]=T_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_QUAD_NO, "debugShowQuadIntersection" +
" no intersect QUAD_VAL QUAD_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CONIC_LINE, "debugShowConicLineIntersection" +
" wtTs[0]=T_VAL CONIC_VAL PT_VAL wnTs[0]=T_VAL LINE_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CONIC_LINE_2, "debugShowConicLineIntersection" +
" wtTs[0]=T_VAL CONIC_VAL PT_VAL wtTs[1]=T_VAL PT_VAL wnTs[0]=T_VAL LINE_VAL wnTs[1]=T_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CONIC_LINE_NO, "debugShowConicLineIntersection" +
" no intersect CONIC_VAL LINE_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CONIC, "debugShowConicIntersection" +
" wtTs[0]=T_VAL CONIC_VAL PT_VAL wnTs[0]=T_VAL CONIC_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CONIC_2, "debugShowConicIntersection" +
" wtTs[0]=T_VAL CONIC_VAL PT_VAL wtTs[1]=T_VAL PT_VAL wnTs[0]=T_VAL CONIC_VAL wnTs[1]=T_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CONIC_NO, "debugShowConicIntersection" +
" no intersect CONIC_VAL CONIC_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CUBIC_LINE, "debugShowCubicLineIntersection" +
" wtTs[0]=T_VAL CUBIC_VAL PT_VAL wnTs[0]=T_VAL LINE_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CUBIC_LINE_2, "debugShowCubicLineIntersection" +
" wtTs[0]=T_VAL CUBIC_VAL PT_VAL wtTs[1]=T_VAL PT_VAL wnTs[0]=T_VAL LINE_VAL wnTs[1]=T_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CUBIC_LINE_3, "debugShowCubicLineIntersection" +
" wtTs[0]=T_VAL CUBIC_VAL PT_VAL wtTs[1]=T_VAL PT_VAL wtTs[2]=T_VAL PT_VAL wnTs[0]=T_VAL LINE_VAL wnTs[1]=T_VAL wnTs[2]=T_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CUBIC_LINE_NO, "debugShowCubicLineIntersection" +
" no intersect CUBIC_VAL LINE_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CUBIC_QUAD, "debugShowCubicQuadIntersection" +
" wtTs[0]=T_VAL CUBIC_VAL PT_VAL wnTs[0]=T_VAL QUAD_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CUBIC_QUAD_2, "debugShowCubicQuadIntersection" +
" wtTs[0]=T_VAL CUBIC_VAL PT_VAL wtTs[1]=T_VAL PT_VAL wnTs[0]=T_VAL QUAD_VAL wnTs[1]=T_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CUBIC_QUAD_3, "debugShowCubicQuadIntersection" +
" wtTs[0]=T_VAL CUBIC_VAL PT_VAL wtTs[1]=T_VAL PT_VAL wtTs[2]=T_VAL PT_VAL wnTs[0]=T_VAL QUAD_VAL wnTs[1]=T_VAL wnTs[2]=T_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CUBIC_QUAD_4, "debugShowCubicQuadIntersection" +
" wtTs[0]=T_VAL CUBIC_VAL PT_VAL wtTs[1]=T_VAL PT_VAL wtTs[2]=T_VAL wtTs[3]=T_VAL PT_VAL wnTs[0]=T_VAL QUAD_VAL wnTs[1]=T_VAL wnTs[2]=T_VAL wnTs[3]=T_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CUBIC_QUAD_NO, "debugShowCubicQuadIntersection" +
" no intersect CUBIC_VAL QUAD_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CUBIC, "debugShowCubicIntersection" +
" wtTs[0]=T_VAL CUBIC_VAL PT_VAL wnTs[0]=T_VAL CUBIC_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CUBIC_2, "debugShowCubicIntersection" +
" wtTs[0]=T_VAL CUBIC_VAL PT_VAL wtTs[1]=T_VAL PT_VAL wnTs[0]=T_VAL CUBIC_VAL wnTs[1]=T_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CUBIC_3, "debugShowCubicIntersection" +
" wtTs[0]=T_VAL CUBIC_VAL PT_VAL wtTs[1]=T_VAL PT_VAL wtTs[2]=T_VAL PT_VAL wnTs[0]=T_VAL CUBIC_VAL wnTs[1]=T_VAL wnTs[2]=T_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CUBIC_4, "debugShowCubicIntersection" +
" wtTs[0]=T_VAL CUBIC_VAL PT_VAL wtTs[1]=T_VAL PT_VAL wtTs[2]=T_VAL PT_VAL wtTs[3]=T_VAL PT_VAL wnTs[0]=T_VAL CUBIC_VAL wnTs[1]=T_VAL wnTs[2]=T_VAL wnTs[3]=T_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_CUBIC_NO, "debugShowCubicIntersection" +
" no intersect CUBIC_VAL CUBIC_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_SELF_CUBIC, "debugShowCubicIntersection" +
" wtTs[0]=T_VAL CUBIC_VAL PT_VAL wtTs[1]=T_VAL"
) || match_regexp(line, lineNo, record, INTERSECT_SELF_CUBIC_NO, "debugShowCubicIntersection" +
" no self intersect CUBIC_VAL"
);
break;
case REC_TYPE_SORT:
var hasDone = / done/.test(line);
var hasUnorderable = / unorderable/.test(line);
var hasSmall = / small/.test(line);
var hasTiny = / tiny/.test(line);
var hasOperand = / operand/.test(line);
var hasStop = / stop/.test(line);
line.replace(/[ a-z]+$/, "");
found = match_regexp(line, lineNo, record, SORT_UNARY, "debugOne" +
" [IDX/IDX] next=IDX/IDX sect=IDX/IDX s=T_VAL [IDX] e=T_VAL [IDX] sgn=NUM windVal=IDX windSum=OPT"
) || match_regexp(line, lineNo, record, SORT_BINARY, "debugOne" +
" [IDX/IDX] next=IDX/IDX sect=IDX/IDX s=T_VAL [IDX] e=T_VAL [IDX] sgn=NUM windVal=IDX windSum=OPT oppVal=IDX oppSum=OPT"
) || match_regexp(line, lineNo, record, SORT_UNARY, "dumpOne" +
" [IDX/IDX] next=IDX/IDX sect=NUM/NUM s=T_VAL [IDX] e=T_VAL [IDX] sgn=NUM windVal=IDX windSum=OPT"
) || match_regexp(line, lineNo, record, SORT_BINARY, "dumpOne" +
" [IDX/IDX] next=IDX/IDX sect=NUM/NUM s=T_VAL [IDX] e=T_VAL [IDX] sgn=NUM windVal=IDX windSum=OPT oppVal=IDX oppSum=OPT"
);
if (found) {
record[1].push(hasDone);
record[1].push(hasUnorderable);
record[1].push(hasSmall);
record[1].push(hasTiny);
record[1].push(hasOperand);
record[1].push(hasStop);
}
break;
case REC_TYPE_TOP:
found = match_regexp(line, lineNo, record, ACTIVE_OP, "findTop" +
" id=IDX s=T_VAL e=T_VAL cw=NUM swap=NUM inflections=NUM monotonic=NUM"
) || match_regexp(line, lineNo, record, ACTIVE_OP, "findTop" +
" id=IDX s=T_VAL e=T_VAL (-) cw=NUM swap=NUM inflections=NUM monotonic=NUM"
) || match_regexp(line, lineNo, record, ACTIVE_OP, "findTop" +
" id=IDX s=T_VAL e=T_VAL (+) cw=NUM swap=NUM inflections=NUM monotonic=NUM"
);
break;
case REC_TYPE_MARK:
found = match_regexp(line, lineNo, record, MARK_LINE, "markWinding" +
" id=IDX LINE_VAL t=T_VAL [IDX] PT_VAL tEnd=T_VAL newWindSum=NUM newOppSum=OPT oppSum=OPT windSum=OPT windValue=IDX"
) || match_regexp(line, lineNo, record, MARK_QUAD, "markWinding" +
" id=IDX QUAD_VAL t=T_VAL [IDX] PT_VAL tEnd=T_VAL newWindSum=NUM newOppSum=OPT oppSum=OPT windSum=OPT windValue=IDX"
) || match_regexp(line, lineNo, record, MARK_CONIC, "markWinding" +
" id=IDX CONIC_VAL t=T_VAL [IDX] PT_VAL tEnd=T_VAL newWindSum=NUM newOppSum=OPT oppSum=OPT windSum=OPT windValue=IDX"
) || match_regexp(line, lineNo, record, MARK_CUBIC, "markWinding" +
" id=IDX CUBIC_VAL t=T_VAL [IDX] PT_VAL tEnd=T_VAL newWindSum=NUM newOppSum=OPT oppSum=OPT windSum=OPT windValue=IDX"
) || match_regexp(line, lineNo, record, MARK_DONE_LINE, "markDone" +
" id=IDX LINE_VAL t=T_VAL [IDX] PT_VAL tEnd=T_VAL newWindSum=OPT newOppSum=OPT oppSum=OPT windSum=OPT windValue=IDX oppValue=OPT"
) || match_regexp(line, lineNo, record, MARK_DONE_QUAD, "markDone" +
" id=IDX QUAD_VAL t=T_VAL [IDX] PT_VAL tEnd=T_VAL newWindSum=OPT newOppSum=OPT oppSum=OPT windSum=OPT windValue=IDX oppValue=OPT"
) || match_regexp(line, lineNo, record, MARK_DONE_CONIC, "markDone" +
" id=IDX CONIC_VAL t=T_VAL [IDX] PT_VAL tEnd=T_VAL newWindSum=OPT newOppSum=OPT oppSum=OPT windSum=OPT windValue=IDX oppValue=OPT"
) || match_regexp(line, lineNo, record, MARK_DONE_CUBIC, "markDone" +
" id=IDX CUBIC_VAL t=T_VAL [IDX] PT_VAL tEnd=T_VAL newWindSum=OPT newOppSum=OPT oppSum=OPT windSum=OPT windValue=IDX oppValue=OPT"
) || match_regexp(line, lineNo, record, MARK_SIMPLE_LINE, "markWinding" +
" id=IDX LINE_VAL t=T_VAL [IDX] PT_VAL tEnd=T_VAL newWindSum=NUM windSum=OPT windValue=IDX"
) || match_regexp(line, lineNo, record, MARK_SIMPLE_QUAD, "markWinding" +
" id=IDX QUAD_VAL t=T_VAL [IDX] PT_VAL tEnd=T_VAL newWindSum=NUM windSum=OPT windValue=IDX"
) || match_regexp(line, lineNo, record, MARK_SIMPLE_CONIC, "markWinding" +
" id=IDX CONIC_VAL t=T_VAL [IDX] PT_VAL tEnd=T_VAL newWindSum=NUM windSum=OPT windValue=IDX"
) || match_regexp(line, lineNo, record, MARK_SIMPLE_CUBIC, "markWinding" +
" id=IDX CUBIC_VAL t=T_VAL [IDX] PT_VAL tEnd=T_VAL newWindSum=NUM windSum=OPT windValue=IDX"
) || match_regexp(line, lineNo, record, MARK_ANGLE_LAST, "markAngle" +
" last segment=IDX span=IDX"
) || match_regexp(line, lineNo, record, MARK_ANGLE_LAST, "markAngle" +
" last segment=IDX span=IDX windSum=OPT");
break;
case REC_TYPE_OP:
if (line.lastIndexOf("oppSign oppSign=", 0) === 0
|| line.lastIndexOf("operator<", 0) === 0) {
found = true;
break;
}
found = match_regexp(line, lineNo, record, OP_DIFFERENCE, "op diff"
) || match_regexp(line, lineNo, record, OP_INTERSECT, "op intersect"
) || match_regexp(line, lineNo, record, OP_INTERSECT, "op sect"
) || match_regexp(line, lineNo, record, OP_UNION, "op union"
) || match_regexp(line, lineNo, record, OP_XOR, "op xor"
);
break;
case REC_TYPE_UNKNOWN:
found = true;
break;
}
if (!found) {
console.log(line + " [" + lineNo + "] of type " + type + " not found");
}
}
if (recType != REC_TYPE_UNKNOWN) {
records.push(recType);
records.push(lastLineNo);
records.push(record);
}
if (records.length >= 1) {
tests[testIndex] = records;
testLines[testIndex] = lines;
}
}
function init(test) {
var canvas = document.getElementById('canvas');
if (!canvas.getContext) return;
ctx = canvas.getContext('2d');
var resScale = retina_scale && window.devicePixelRatio ? window.devicePixelRatio : 1;
var unscaledWidth = window.innerWidth - 20;
var unscaledHeight = window.innerHeight - 20;
screenWidth = unscaledWidth;
screenHeight = unscaledHeight;
canvas.width = unscaledWidth * resScale;
canvas.height = unscaledHeight * resScale;
canvas.style.width = unscaledWidth + 'px';
canvas.style.height = unscaledHeight + 'px';
if (resScale != 1) {
ctx.scale(resScale, resScale);
}
xmin = Infinity;
xmax = -Infinity;
ymin = Infinity;
ymax = -Infinity;
hasPath = hasAlignedPath = hasComputedPath = false;
firstActiveSpan = -1;
for (var tIndex = 0; tIndex < test.length; tIndex += 3) {
var recType = test[tIndex];
if (!typeof recType == 'number' || recType < REC_TYPE_UNKNOWN || recType > REC_TYPE_LAST) {
console.log("unknown rec type: " + recType);
throw "stop execution";
}
var records = test[tIndex + 2];
for (var recordIndex = 0; recordIndex < records.length; recordIndex += 2) {
var fragType = records[recordIndex];
if (!typeof fragType == 'number' || fragType < 1 || fragType > FRAG_TYPE_LAST) {
console.log("unknown in range frag type: " + fragType);
throw "stop execution";
}
var frags = records[recordIndex + 1];
var first = 0;
var last = -1;
var first2 = 0;
var last2 = 0;
switch (recType) {
case REC_TYPE_ALIGNED:
hasAlignedPath = true;
case REC_TYPE_COMPUTED:
if (fragType == COMPUTED_SET_1 || fragType == COMPUTED_SET_2) {
break;
}
if (REC_TYPE_COMPUTED == recType) {
hasComputedPath = true;
}
case REC_TYPE_PATH:
first = 1;
switch (fragType) {
case PATH_LINE:
last = 5;
break;
case PATH_CONIC:
case PATH_QUAD:
last = 7;
break;
case PATH_CUBIC:
last = 9;
break;
default:
console.log("unknown " + (recType == REC_TYPE_PATH ? "REC_TYPE_PATH"
: "REC_TYPE_COMPUTED") + " frag type:" + fragType);
throw "stop execution";
}
if (recType == REC_TYPE_PATH) {
hasPath = true;
}
break;
case REC_TYPE_PATH2:
first = 1;
switch (fragType) {
case PATH_LINE:
last = 5;
break;
case PATH_CONIC:
case PATH_QUAD:
last = 7;
break;
case PATH_CUBIC:
last = 9;
break;
default:
console.log("unknown " + (recType == REC_TYPE_PATH2 ? "REC_TYPE_PATH2"
: "REC_TYPE_COMPUTED") + " frag type:" + fragType);
throw "stop execution";
}
if (recType == REC_TYPE_PATH2) {
hasPath = true;
}
break;
case REC_TYPE_ACTIVE:
if (firstActiveSpan < 0) {
firstActiveSpan = tIndex;
}
first = 1;
switch (fragType) {
case ACTIVE_LINE_SPAN:
last = 5;
break;
case ACTIVE_CONIC_SPAN:
case ACTIVE_QUAD_SPAN:
last = 7;
break;
case ACTIVE_CUBIC_SPAN:
last = 9;
break;
default:
console.log("unknown REC_TYPE_ACTIVE frag type: " + fragType);
throw "stop execution";
}
break;
case REC_TYPE_ADD:
switch (fragType) {
case ADD_MOVETO:
break;
case ADD_LINETO:
last = 4;
break;
case ADD_CONICTO:
case ADD_QUADTO:
last = 6;
break;
case ADD_CUBICTO:
last = 8;
break;
case ADD_CLOSE:
case ADD_FILL:
break;
default:
console.log("unknown REC_TYPE_ADD frag type: " + fragType);
throw "stop execution";
}
break;
case REC_TYPE_AFTERPART:
switch (fragType) {
case PATH_LINE:
last = 4;
break;
case PATH_CONIC:
case PATH_QUAD:
last = 6;
break;
case PATH_CUBIC:
last = 8;
break;
default:
console.log("unknown REC_TYPE_ACTIVEPART frag type: " + fragType);
throw "stop execution";
}
break;
case REC_TYPE_SECT:
switch (fragType) {
case INTERSECT_LINE:
first = 1; last = 5; first2 = 8; last2 = 12;
break;
case INTERSECT_LINE_2:
first = 1; last = 5; first2 = 11; last2 = 15;
break;
case INTERSECT_LINE_NO:
first = 0; last = 4; first2 = 4; last2 = 8;
break;
case INTERSECT_CONIC_LINE:
first = 1; last = 7; first2 = 11; last2 = 15;
break;
case INTERSECT_QUAD_LINE:
first = 1; last = 7; first2 = 10; last2 = 14;
break;
case INTERSECT_CONIC_LINE_2:
first = 1; last = 7; first2 = 14; last2 = 18;
break;
case INTERSECT_QUAD_LINE_2:
first = 1; last = 7; first2 = 13; last2 = 17;
break;
case INTERSECT_CONIC_LINE_NO:
first = 0; last = 6; first2 = 7; last2 = 11;
break;
case INTERSECT_QUAD_LINE_NO:
first = 0; last = 6; first2 = 6; last2 = 10;
break;
case INTERSECT_CONIC:
first = 1; last = 7; first2 = 11; last2 = 17;
break;
case INTERSECT_QUAD:
first = 1; last = 7; first2 = 10; last2 = 16;
break;
case INTERSECT_CONIC_2:
first = 1; last = 7; first2 = 14; last2 = 20;
break;
case INTERSECT_QUAD_2:
first = 1; last = 7; first2 = 13; last2 = 19;
break;
case INTERSECT_CONIC_NO:
first = 0; last = 6; first2 = 7; last2 = 13;
break;
case INTERSECT_QUAD_NO:
first = 0; last = 6; first2 = 6; last2 = 12;
break;
case INTERSECT_SELF_CUBIC:
first = 1; last = 9;
break;
case INTERSECT_SELF_CUBIC_NO:
first = 0; last = 8;
break;
case INTERSECT_CUBIC_LINE:
first = 1; last = 9; first2 = 12; last2 = 16;
break;
case INTERSECT_CUBIC_LINE_2:
first = 1; last = 9; first2 = 15; last2 = 19;
break;
case INTERSECT_CUBIC_LINE_3:
first = 1; last = 9; first2 = 18; last2 = 22;
break;
case INTERSECT_CUBIC_LINE_NO:
first = 0; last = 8; first2 = 8; last2 = 12;
break;
case INTERSECT_CUBIC_QUAD:
first = 1; last = 9; first2 = 12; last2 = 18;
break;
case INTERSECT_CUBIC_QUAD_2:
first = 1; last = 9; first2 = 15; last2 = 21;
break;
case INTERSECT_CUBIC_QUAD_3:
first = 1; last = 9; first2 = 18; last2 = 24;
break;
case INTERSECT_CUBIC_QUAD_4:
first = 1; last = 9; first2 = 21; last2 = 27;
break;
case INTERSECT_CUBIC_QUAD_NO:
first = 0; last = 8; first2 = 8; last2 = 14;
break;
case INTERSECT_CUBIC:
first = 1; last = 9; first2 = 12; last2 = 20;
break;
case INTERSECT_CUBIC_2:
first = 1; last = 9; first2 = 15; last2 = 23;
break;
case INTERSECT_CUBIC_3:
first = 1; last = 9; first2 = 18; last2 = 26;
break;
case INTERSECT_CUBIC_4:
first = 1; last = 9; first2 = 21; last2 = 29;
break;
case INTERSECT_CUBIC_NO:
first = 0; last = 8; first2 = 8; last2 = 16;
break;
default:
console.log("unknown REC_TYPE_SECT frag type: " + fragType);
throw "stop execution";
}
break;
default:
continue;
}
for (var idx = first; idx < last; idx += 2) {
xmin = Math.min(xmin, frags[idx]);
xmax = Math.max(xmax, frags[idx]);
ymin = Math.min(ymin, frags[idx + 1]);
ymax = Math.max(ymax, frags[idx + 1]);
}
for (var idx = first2; idx < last2; idx += 2) {
xmin = Math.min(xmin, frags[idx]);
xmax = Math.max(xmax, frags[idx]);
ymin = Math.min(ymin, frags[idx + 1]);
ymax = Math.max(ymax, frags[idx + 1]);
}
}
}
var angleBounds = [Infinity, Infinity, -Infinity, -Infinity];
for (var tIndex = 0; tIndex < test.length; tIndex += 3) {
var recType = test[tIndex];
var records = test[tIndex + 2];
for (var recordIndex = 0; recordIndex < records.length; recordIndex += 2) {
var fragType = records[recordIndex];
var frags = records[recordIndex + 1];
switch (recType) {
case REC_TYPE_ACTIVE_OP:
if (!draw_op) {
break;
}
{
var curve = curvePartialByID(test, frags[0], frags[1], frags[2]);
curve_extremes(curve, angleBounds);
}
break;
case REC_TYPE_ANGLE:
if (!draw_angle) {
break;
}
{
var curve = curvePartialByID(test, frags[0], frags[4], frags[5]);
curve_extremes(curve, angleBounds);
curve = curvePartialByID(test, frags[6], frags[10], frags[11]);
curve_extremes(curve, angleBounds);
curve = curvePartialByID(test, frags[12], frags[16], frags[17]);
}
break;
case REC_TYPE_COINCIDENCE:
if (!draw_coincidence) {
break;
}
{
var curve = curvePartialByID(test, frags[0], frags[1], frags[2]);
curve_extremes(curve, angleBounds);
}
break;
case REC_TYPE_SORT:
if (!draw_sort) {
break;
}
if (fragType == SORT_UNARY || fragType == SORT_BINARY) {
var curve = curvePartialByID(test, frags[0], frags[6], frags[8]);
curve_extremes(curve, angleBounds);
}
break;
case REC_TYPE_TOP:
if (!draw_top) {
break;
}
{
var curve = curvePartialByID(test, frags[0], frags[1], frags[2]);
curve_extremes(curve, angleBounds);
}
break;
}
}
}
xmin = Math.min(xmin, angleBounds[0]);
ymin = Math.min(ymin, angleBounds[1]);
xmax = Math.max(xmax, angleBounds[2]);
ymax = Math.max(ymax, angleBounds[3]);
setScale(xmin, xmax, ymin, ymax);
if (hasPath == false && hasComputedPath == true && !draw_computed) {
draw_computed = 7; // show quadratics, conics, and cubics
}
if (hasPath == true && hasComputedPath == false && draw_computed) {
draw_computed = 0;
}
}
function curveByIDMatch(test, id, recMatch) {
var tIndex = -3;
while ((tIndex += 3) < test.length) {
var recType = test[tIndex];
if (recType == REC_TYPE_OP) {
continue;
}
if (recType != recMatch) {
return [];
}
var records = test[tIndex + 2];
for (var recordIndex = 0; recordIndex < records.length; recordIndex += 2) {
var fragType = records[recordIndex];
var frags = records[recordIndex + 1];
if (frags[0] == id) {
switch (fragType) {
case PATH_LINE:
return [frags[1], frags[2], frags[3], frags[4]];
case PATH_QUAD:
return [frags[1], frags[2], frags[3], frags[4],
frags[5], frags[6]];
case PATH_CONIC:
return [frags[1], frags[2], frags[3], frags[4],
frags[5], frags[6], frags[7]];
case PATH_CUBIC:
return [frags[1], frags[2], frags[3], frags[4],
frags[5], frags[6], frags[7], frags[8]];
}
}
}
}
return [];
}
function curveByID(test, id) {
var result = draw_path >= 4 ? curveByIDMatch(test, id, REC_TYPE_ALIGNED) : [];
if (!result.length) {
result = curveByIDMatch(test, id, REC_TYPE_PATH);
}
return result;
}
function curvePartialByIDMatch(test, id, t0, t1, recMatch) {
var tIndex = -3;
while ((tIndex += 3) < test.length) {
var recType = test[tIndex];
if (recType == REC_TYPE_OP) {
continue;
}
if (recType != recMatch) {
return [];
}
var records = test[tIndex + 2];
for (var recordIndex = 0; recordIndex < records.length; recordIndex += 2) {
var fragType = records[recordIndex];
var frags = records[recordIndex + 1];
if (frags[0] == id) {
switch (fragType) {
case PATH_LINE:
return linePartial(frags[1], frags[2], frags[3], frags[4], t0, t1);
case PATH_QUAD:
return quadPartial(frags[1], frags[2], frags[3], frags[4],
frags[5], frags[6], t0, t1);
case PATH_CONIC:
return conicPartial(frags[1], frags[2], frags[3], frags[4],
frags[5], frags[6], frags[7], t0, t1);
case PATH_CUBIC:
return cubicPartial(frags[1], frags[2], frags[3], frags[4],
frags[5], frags[6], frags[7], frags[8], t0, t1);
}
}
}
}
return [];
}
function curvePartialByID(test, id, t0, t1) {
var result = draw_path >= 4 ? curvePartialByIDMatch(test, id, t0, t1, REC_TYPE_ALIGNED) : [];
if (!result.length) {
result = curvePartialByIDMatch(test, id, t0, t1, REC_TYPE_PATH);
}
return result;
}
function idByCurveIDMatch(test, frag, type, recMatch) {
var tIndex = 0;
while (tIndex < test.length) {
var recType = test[tIndex];
if (recType != recMatch) {
++tIndex;
continue;
}
var records = test[tIndex + 2];
for (var recordIndex = 0; recordIndex < records.length; recordIndex += 2) {
var fragType = records[recordIndex];
var frags = records[recordIndex + 1];
if (frag.length != frags.length - 1) {
continue;
}
switch (fragType) {
case PATH_LINE:
if (frag[0] != frags[1] || frag[1] != frags[2]
|| frag[2] != frags[3] || frag[3] != frags[4]) {
continue;
}
return frags[0];
case PATH_QUAD:
if (frag[0] != frags[1] || frag[1] != frags[2]
|| frag[2] != frags[3] || frag[3] != frags[4]
|| frag[4] != frags[5] || frag[5] != frags[6]) {
continue;
}
return frags[0];
case PATH_CONIC:
if (frag[0] != frags[1] || frag[1] != frags[2]
|| frag[2] != frags[3] || frag[3] != frags[4]
|| frag[4] != frags[5] || frag[5] != frags[6]
|| frag[6] != frags[7]) {
continue;
}
return frags[0];
case PATH_CUBIC:
if (frag[0] != frags[1] || frag[1] != frags[2]
|| frag[2] != frags[3] || frag[3] != frags[4]
|| frag[4] != frags[5] || frag[5] != frags[6]
|| frag[6] != frags[7] || frag[7] != frags[8]) {
continue;
}
return frags[0];
}
}
++tIndex;
}
return -1;
}
function idByCurve(test, frag, type) {
var result = draw_path >= 4 ? idByCurveIDMatch(test, frag, type, REC_TYPE_ALIGNED) : [];
if (!result.length) {
result = idByCurveIDMatch(test, frag, type, REC_TYPE_PATH);
}
return result;
}
function curve_extremes(curve, bounds) {
var length = curve.length == 7 ? 6 : curve.length;
for (var index = 0; index < length; index += 2) {
var x = curve[index];
var y = curve[index + 1];
bounds[0] = Math.min(bounds[0], x);
bounds[1] = Math.min(bounds[1], y);
bounds[2] = Math.max(bounds[2], x);
bounds[3] = Math.max(bounds[3], y);
}
}
function setScale(x0, x1, y0, y1) {
var srcWidth = x1 - x0;
var srcHeight = y1 - y0;
var usableWidth = screenWidth;
var xDigits = Math.ceil(Math.log(Math.abs(xmax)) / Math.log(10));
var yDigits = Math.ceil(Math.log(Math.abs(ymax)) / Math.log(10));
usableWidth -= (xDigits + yDigits) * 10;
usableWidth -= decimal_places * 10;
if (draw_legend) {
usableWidth -= 40;
}
var hscale = usableWidth / srcWidth;
var vscale = screenHeight / srcHeight;
scale = Math.min(hscale, vscale);
var invScale = 1 / scale;
var sxmin = x0 - invScale * 5;
var symin = y0 - invScale * 10;
var sxmax = x1 + invScale * (6 * decimal_places + 10);
var symax = y1 + invScale * 10;
srcWidth = sxmax - sxmin;
srcHeight = symax - symin;
hscale = usableWidth / srcWidth;
vscale = screenHeight / srcHeight;
scale = Math.min(hscale, vscale);
srcLeft = sxmin;
srcTop = symin;
}
function drawArc(curve, op, from, to) {
var type = PATH_LINE + (curve.length / 2 - 2);
var pt = pointAtT(curve, type, op ? 0.4 : 0.6);
var dy = pt.y - curve[1];
var dx = pt.x - curve[0];
var dist = Math.sqrt(dy * dy + dx * dx);
var _dist = dist * scale;
var angle = Math.atan2(dy, dx);
var _px = (curve[0] - srcLeft) * scale;
var _py = (curve[1] - srcTop) * scale;
var divisor = 4;
var endDist;
do {
var ends = [];
for (var index = -1; index <= 1; index += 2) {
var px = Math.cos(index * Math.PI / divisor);
var py = Math.sin(index * Math.PI / divisor);
ends.push(px);
ends.push(py);
}
var endDx = (ends[2] - ends[0]) * scale * dist;
var endDy = (ends[3] - ends[1]) * scale * dist;
endDist = Math.sqrt(endDx * endDx + endDy * endDy);
if (endDist < 100) {
break;
}
divisor *= 2;
} while (true);
if (endDist < 30) {
return;
}
if (op) {
divisor *= 2;
}
ctx.strokeStyle = op ? "rgba(210,0,45, 0.4)" : "rgba(90,90,90, 0.5)";
ctx.beginPath();
ctx.arc(_px, _py, _dist, angle - Math.PI / divisor, angle + Math.PI / divisor, false);
ctx.stroke();
var saveAlign = ctx.textAlign;
var saveStyle = ctx.fillStyle;
var saveFont = ctx.font;
ctx.textAlign = "center";
ctx.fillStyle = "black";
ctx.font = "normal 24px Arial";
divisor *= 0.8;
for (var index = -1; index <= 1; index += 2) {
var px = curve[0] + Math.cos(angle + index * Math.PI / divisor) * dist;
var py = curve[1] + Math.sin(angle + index * Math.PI / divisor) * dist;
var _px = (px - srcLeft) * scale;
var _py = (py - srcTop) * scale;
ctx.fillText(index < 0 ? to.toString() : from.toString(), _px, _py + 8);
}
ctx.textAlign = saveAlign;
ctx.fillStyle = saveStyle;
ctx.font = saveFont;
}
function drawPoint(px, py, end) {
var length = drawnPts.length == 7 ? 6 : drawnPts.length;
for (var pts = 0; pts < length; pts += 2) {
var x = drawnPts[pts];
var y = drawnPts[pts + 1];
if (px == x && py == y) {
return;
}
}
drawnPts.push(px);
drawnPts.push(py);
var label = px.toFixed(decimal_places) + ", " + py.toFixed(decimal_places);
var _px = (px - srcLeft) * scale;
var _py = (py - srcTop) * scale;
ctx.beginPath();
ctx.arc(_px, _py, 3, 0, Math.PI*2, true);
ctx.closePath();
if (end) {
ctx.fill();
} else {
ctx.stroke();
}
if (debug_xy) {
ctx.textAlign = "left";
ctx.fillText(label, _px + 5, _py);
}
}
function coordCount(curveType) {
switch (curveType) {
case PATH_LINE:
return 4;
case PATH_QUAD:
return 6;
case PATH_CONIC:
return 6;
case PATH_CUBIC:
return 8;
}
return -1;
}
function drawPoints(ptArray, curveType, drawControls) {
var count = coordCount(curveType);
for (var idx = 0; idx < count; idx += 2) {
if (!drawControls && idx != 0 && idx != count - 2) {
continue;
}
drawPoint(ptArray[idx], ptArray[idx + 1], idx == 0 || idx == count - 2);
}
}
function drawControlLines(curve, curveType, drawEnd) {
if (curveType == PATH_LINE) {
return;
}
ctx.strokeStyle = "rgba(0,0,0, 0.3)";
drawLine(curve[0], curve[1], curve[2], curve[3]);
drawLine(curve[2], curve[3], curve[4], curve[5]);
if (curveType == PATH_CUBIC) {
drawLine(curve[4], curve[5], curve[6], curve[7]);
if (drawEnd > 1) {
drawLine(curve[6], curve[7], curve[0], curve[1]);
if (drawEnd > 2) {
drawLine(curve[0], curve[1], curve[4], curve[5]);
drawLine(curve[6], curve[7], curve[2], curve[3]);
}
}
} else if (drawEnd > 1) {
drawLine(curve[4], curve[5], curve[0], curve[1]);
}
}
function pointAtT(curve, curveType, t) {
var xy = {};
switch (curveType) {
case PATH_LINE:
var a = 1 - t;
var b = t;
xy.x = a * curve[0] + b * curve[2];
xy.y = a * curve[1] + b * curve[3];
break;
case PATH_QUAD:
var one_t = 1 - t;
var a = one_t * one_t;
var b = 2 * one_t * t;
var c = t * t;
xy.x = a * curve[0] + b * curve[2] + c * curve[4];
xy.y = a * curve[1] + b * curve[3] + c * curve[5];
break;
case PATH_CONIC:
var one_t = 1 - t;
var a = one_t * one_t;
var b = 2 * one_t * t;
var c = t * t;
xy.x = a * curve[0] + b * curve[2] * curve[6] + c * curve[4];
xy.y = a * curve[1] + b * curve[3] * curve[6] + c * curve[5];
var d = a + b * curve[6] + c;
xy.x /= d;
xy.y /= d;
break;
case PATH_CUBIC:
var one_t = 1 - t;
var one_t2 = one_t * one_t;
var a = one_t2 * one_t;
var b = 3 * one_t2 * t;
var t2 = t * t;
var c = 3 * one_t * t2;
var d = t2 * t;
xy.x = a * curve[0] + b * curve[2] + c * curve[4] + d * curve[6];
xy.y = a * curve[1] + b * curve[3] + c * curve[5] + d * curve[7];
break;
}
return xy;
}
function drawPointAtT(curve, curveType) {
var x, y;
var xy = pointAtT(curve, curveType, curveT);
drawPoint(xy.x, xy.y, true);
if (!draw_intersectT) {
return;
}
ctx.fillStyle = "red";
drawTAtPointUp(xy.x, xy.y, curveT);
}
function drawTAtPointUp(px, py, t) {
var label = t.toFixed(decimal_places);
var _px = (px - srcLeft)* scale;
var _py = (py - srcTop) * scale;
ctx.fillText(label, _px + 5, _py - 10);
}
function drawTAtPointDown(px, py, t) {
var label = t.toFixed(decimal_places);
var _px = (px - srcLeft)* scale;
var _py = (py - srcTop) * scale;
ctx.fillText(label, _px + 5, _py + 10);
}
function alreadyDrawnLine(x1, y1, x2, y2) {
if (collect_bounds) {
if (focus_enabled) {
focusXmin = Math.min(focusXmin, x1, x2);
focusYmin = Math.min(focusYmin, y1, y2);
focusXmax = Math.max(focusXmax, x1, x2);
focusYmax = Math.max(focusYmax, y1, y2);
}
return true;
}
for (var pts = 0; pts < drawnLines.length; pts += 4) {
if (x1 == drawnLines[pts] && y1 == drawnLines[pts + 1]
&& x2 == drawnLines[pts + 2] && y2 == drawnLines[pts + 3]) {
return true;
}
}
drawnLines.push(x1);
drawnLines.push(y1);
drawnLines.push(x2);
drawnLines.push(y2);
return false;
}
function drawLine(x1, y1, x2, y2) {
if (alreadyDrawnLine(x1, y1, x2, y2)) {
return;
}
ctx.beginPath();
ctx.moveTo((x1 - srcLeft) * scale,
(y1 - srcTop) * scale);
ctx.lineTo((x2 - srcLeft) * scale,
(y2 - srcTop) * scale);
ctx.stroke();
}
function linePartial(x1, y1, x2, y2, t1, t2) {
var dx = x1 - x2;
var dy = y1 - y2;
var array = [
x1 - t1 * dx,
y1 - t1 * dy,
x1 - t2 * dx,
y1 - t2 * dy
];
return array;
}
function drawLinePartial(x1, y1, x2, y2, t1, t2) {
var a = linePartial(x1, y1, x2, y2, t1, t2);
var ax = a[0];
var ay = a[1];
var bx = a[2];
var by = a[3];
if (alreadyDrawnLine(ax, ay, bx, by)) {
return;
}
ctx.beginPath();
ctx.moveTo((ax - srcLeft) * scale,
(ay - srcTop) * scale);
ctx.lineTo((bx - srcLeft) * scale,
(by - srcTop) * scale);
ctx.stroke();
}
function alreadyDrawnQuad(x1, y1, x2, y2, x3, y3) {
if (collect_bounds) {
if (focus_enabled) {
focusXmin = Math.min(focusXmin, x1, x2, x3);
focusYmin = Math.min(focusYmin, y1, y2, y3);
focusXmax = Math.max(focusXmax, x1, x2, x3);
focusYmax = Math.max(focusYmax, y1, y2, y3);
}
return true;
}
for (var pts = 0; pts < drawnQuads.length; pts += 6) {
if (x1 == drawnQuads[pts] && y1 == drawnQuads[pts + 1]
&& x2 == drawnQuads[pts + 2] && y2 == drawnQuads[pts + 3]
&& x3 == drawnQuads[pts + 4] && y3 == drawnQuads[pts + 5]) {
return true;
}
}
drawnQuads.push(x1);
drawnQuads.push(y1);
drawnQuads.push(x2);
drawnQuads.push(y2);
drawnQuads.push(x3);
drawnQuads.push(y3);
return false;
}
function drawQuad(x1, y1, x2, y2, x3, y3) {
if (alreadyDrawnQuad(x1, y1, x2, y2, x3, y3)) {
return;
}
ctx.beginPath();
ctx.moveTo((x1 - srcLeft) * scale,
(y1 - srcTop) * scale);
ctx.quadraticCurveTo((x2 - srcLeft) * scale,
(y2 - srcTop) * scale,
(x3 - srcLeft) * scale,
(y3 - srcTop) * scale);
ctx.stroke();
}
function interp(A, B, t) {
return A + (B - A) * t;
}
function interp_quad_coords(x1, x2, x3, t)
{
var ab = interp(x1, x2, t);
var bc = interp(x2, x3, t);
var abc = interp(ab, bc, t);
return abc;
}
function quadPartial(x1, y1, x2, y2, x3, y3, t1, t2) {
var ax = interp_quad_coords(x1, x2, x3, t1);
var ay = interp_quad_coords(y1, y2, y3, t1);
var dx = interp_quad_coords(x1, x2, x3, (t1 + t2) / 2);
var dy = interp_quad_coords(y1, y2, y3, (t1 + t2) / 2);
var cx = interp_quad_coords(x1, x2, x3, t2);
var cy = interp_quad_coords(y1, y2, y3, t2);
var bx = 2*dx - (ax + cx)/2;
var by = 2*dy - (ay + cy)/2;
var array = [
ax, ay, bx, by, cx, cy
];
return array;
}
function drawQuadPartial(x1, y1, x2, y2, x3, y3, t1, t2) {
var a = quadPartial(x1, y1, x2, y2, x3, y3, t1, t2);
var ax = a[0];
var ay = a[1];
var bx = a[2];
var by = a[3];
var cx = a[4];
var cy = a[5];
if (alreadyDrawnQuad(ax, ay, bx, by, cx, cy)) {
return;
}
ctx.beginPath();
ctx.moveTo((ax - srcLeft) * scale,
(ay - srcTop) * scale);
ctx.quadraticCurveTo((bx - srcLeft) * scale,
(by - srcTop) * scale,
(cx - srcLeft) * scale,
(cy - srcTop) * scale);
ctx.stroke();
}
function alreadyDrawnConic(x1, y1, x2, y2, x3, y3, w) {
if (collect_bounds) {
if (focus_enabled) {
focusXmin = Math.min(focusXmin, x1, x2, x3);
focusYmin = Math.min(focusYmin, y1, y2, y3);
focusXmax = Math.max(focusXmax, x1, x2, x3);
focusYmax = Math.max(focusYmax, y1, y2, y3);
}
return true;
}
for (var pts = 0; pts < drawnConics.length; pts += 8) {
if (x1 == drawnConics[pts] && y1 == drawnCubics[pts + 1]
&& x2 == drawnCubics[pts + 2] && y2 == drawnCubics[pts + 3]
&& x3 == drawnCubics[pts + 4] && y3 == drawnCubics[pts + 5]
&& w == drawnCubics[pts + 6]) {
return true;
}
}
drawnConics.push(x1);
drawnConics.push(y1);
drawnConics.push(x2);
drawnConics.push(y2);
drawnConics.push(x3);
drawnConics.push(y3);
drawnCubics.push(w);
return false;
}
var kMaxConicToQuadPOW2 = 5;
function computeQuadPOW2(curve, tol) {
var a = curve[6] - 1;
var k = a / (4 * (2 + a));
var x = k * (curve[0] - 2 * curve[2] + curve[4]);
var y = k * (curve[1] - 2 * curve[3] + curve[5]);
var error = Math.sqrt(x * x + y * y);
var pow2;
for (pow2 = 0; pow2 < kMaxConicToQuadPOW2; ++pow2) {
if (error <= tol) {
break;
}
error *= 0.25;
}
return pow2;
}
function subdivide_w_value(w) {
return Math.sqrt(0.5 + w * 0.5);
}
function chop(curve, part1, part2) {
var w = curve[6];
var scale = 1 / (1 + w);
part1[0] = curve[0];
part1[1] = curve[1];
part1[2] = (curve[0] + curve[2] * w) * scale;
part1[3] = (curve[1] + curve[3] * w) * scale;
part1[4] = part2[0] = (curve[0] + (curve[2] * w) * 2 + curve[4]) * scale * 0.5;
part1[5] = part2[1] = (curve[1] + (curve[3] * w) * 2 + curve[5]) * scale * 0.5;
part2[2] = (curve[2] * w + curve[4]) * scale;
part2[3] = (curve[3] * w + curve[5]) * scale;
part2[4] = curve[4];
part2[5] = curve[5];
part1[6] = part2[6] = subdivide_w_value(w);
}
function subdivide(curve, level, pts) {
if (0 == level) {
pts.push(curve[2]);
pts.push(curve[3]);
pts.push(curve[4]);
pts.push(curve[5]);
} else {
var part1 = [], part2 = [];
chop(curve, part1, part2);
--level;
subdivide(part1, level, pts);
subdivide(part2, level, pts);
}
}
function chopIntoQuadsPOW2(curve, pow2, pts) {
subdivide(curve, pow2, pts);
return 1 << pow2;
}
function drawConicWithQuads(x1, y1, x2, y2, x3, y3, w) {
if (alreadyDrawnConic(x1, y1, x2, y2, x3, y3, w)) {
return;
}
ctx.beginPath();
ctx.moveTo((x1 - srcLeft) * scale,
(y1 - srcTop) * scale);
var tol = 1 / scale;
var curve = [x1, y1, x2, y2, x3, y3, w];
var pow2 = computeQuadPOW2(curve, tol);
var pts = [];
chopIntoQuadsPOW2(curve, pow2, pts);
for (var i = 0; i < pts.length; i += 4) {
ctx.quadraticCurveTo(
(pts[i + 0] - srcLeft) * scale, (pts[i + 1] - srcTop) * scale,
(pts[i + 2] - srcLeft) * scale, (pts[i + 3] - srcTop) * scale);
}
ctx.stroke();
}
function conic_eval_numerator(x1, x2, x3, w, t) {
var src2w = x2 * w;
var C = x1;
var A = x3 - 2 * src2w + C;
var B = 2 * (src2w - C);
return (A * t + B) * t + C;
}
function conic_eval_denominator(w, t) {
var B = 2 * (w - 1);
var C = 1;
var A = -B;
return (A * t + B) * t + C;
}
function conicPartial(x1, y1, x2, y2, x3, y3, w, t1, t2) {
var ax = conic_eval_numerator(x1, x2, x3, w, t1);
var ay = conic_eval_numerator(y1, y2, y3, w, t1);
var az = conic_eval_denominator(w, t1);
var midT = (t1 + t2) / 2;
var dx = conic_eval_numerator(x1, x2, x3, w, midT);
var dy = conic_eval_numerator(y1, y2, y3, w, midT);
var dz = conic_eval_denominator(w, midT);
var cx = conic_eval_numerator(x1, x2, x3, w, t2);
var cy = conic_eval_numerator(y1, y2, y3, w, t2);
var cz = conic_eval_denominator(w, t2);
var bx = 2 * dx - (ax + cx) / 2;
var by = 2 * dy - (ay + cy) / 2;
var bz = 2 * dz - (az + cz) / 2;
var dt = t2 - t1;
var dt_1 = 1 - dt;
var array = [
ax / az, ay / az, bx / bz, by / bz, cx / cz, cy / cz, 0
];
var dMidAC = { x:(array[0] + array[4]) / 2, y:(array[1] + array[5]) / 2 };
var dMid = { x:dx / dz, y:dy / dz };
var dWNumer = { x:dMidAC.x - dMid.x, y:dMidAC.y - dMid.y };
var dWDenom = { x:dMid.x - array[2], y:dMid.y - array[3] };
var partW = Math.sqrt(dWNumer.x * dWNumer.x + dWNumer.y * dWNumer.y)
/ Math.sqrt(dWDenom.x * dWDenom.x + dWDenom.y * dWDenom.y);
array[6] = partW;
return array;
}
function drawConicPartial(x1, y1, x2, y2, x3, y3, w, t1, t2) {
var a = conicPartial(x1, y1, x2, y2, x3, y3, w, t1, t2);
var ax = a[0];
var ay = a[1];
var bx = a[2];
var by = a[3];
var cx = a[4];
var cy = a[5];
var w_ = a[6];
drawConicWithQuads(ax, ay, bx, by, cx, cy, w_);
}
function alreadyDrawnCubic(x1, y1, x2, y2, x3, y3, x4, y4) {
if (collect_bounds) {
if (focus_enabled) {
focusXmin = Math.min(focusXmin, x1, x2, x3, x4);
focusYmin = Math.min(focusYmin, y1, y2, y3, y4);
focusXmax = Math.max(focusXmax, x1, x2, x3, x4);
focusYmax = Math.max(focusYmax, y1, y2, y3, y4);
}
return true;
}
for (var pts = 0; pts < drawnCubics.length; pts += 8) {
if (x1 == drawnCubics[pts] && y1 == drawnCubics[pts + 1]
&& x2 == drawnCubics[pts + 2] && y2 == drawnCubics[pts + 3]
&& x3 == drawnCubics[pts + 4] && y3 == drawnCubics[pts + 5]
&& x4 == drawnCubics[pts + 6] && y4 == drawnCubics[pts + 7]) {
return true;
}
}
drawnCubics.push(x1);
drawnCubics.push(y1);
drawnCubics.push(x2);
drawnCubics.push(y2);
drawnCubics.push(x3);
drawnCubics.push(y3);
drawnCubics.push(x4);
drawnCubics.push(y4);
return false;
}
function drawCubic(x1, y1, x2, y2, x3, y3, x4, y4) {
if (alreadyDrawnCubic(x1, y1, x2, y2, x3, y3, x4, y4)) {
return;
}
ctx.beginPath();
ctx.moveTo((x1 - srcLeft) * scale,
(y1 - srcTop) * scale);
ctx.bezierCurveTo((x2 - srcLeft) * scale,
(y2 - srcTop) * scale,
(x3 - srcLeft) * scale,
(y3 - srcTop) * scale,
(x4 - srcLeft) * scale,
(y4 - srcTop) * scale);
ctx.stroke();
}
function interp_cubic_coords(x1, x2, x3, x4, t)
{
var ab = interp(x1, x2, t);
var bc = interp(x2, x3, t);
var cd = interp(x3, x4, t);
var abc = interp(ab, bc, t);
var bcd = interp(bc, cd, t);
var abcd = interp(abc, bcd, t);
return abcd;
}
function cubicPartial(x1, y1, x2, y2, x3, y3, x4, y4, t1, t2) {
var ax = interp_cubic_coords(x1, x2, x3, x4, t1);
var ay = interp_cubic_coords(y1, y2, y3, y4, t1);
var ex = interp_cubic_coords(x1, x2, x3, x4, (t1*2+t2)/3);
var ey = interp_cubic_coords(y1, y2, y3, y4, (t1*2+t2)/3);
var fx = interp_cubic_coords(x1, x2, x3, x4, (t1+t2*2)/3);
var fy = interp_cubic_coords(y1, y2, y3, y4, (t1+t2*2)/3);
var dx = interp_cubic_coords(x1, x2, x3, x4, t2);
var dy = interp_cubic_coords(y1, y2, y3, y4, t2);
var mx = ex * 27 - ax * 8 - dx;
var my = ey * 27 - ay * 8 - dy;
var nx = fx * 27 - ax - dx * 8;
var ny = fy * 27 - ay - dy * 8;
var bx = (mx * 2 - nx) / 18;
var by = (my * 2 - ny) / 18;
var cx = (nx * 2 - mx) / 18;
var cy = (ny * 2 - my) / 18;
var array = [
ax, ay, bx, by, cx, cy, dx, dy
];
return array;
}
function drawCubicPartial(x1, y1, x2, y2, x3, y3, x4, y4, t1, t2) {
var a = cubicPartial(x1, y1, x2, y2, x3, y3, x4, y4, t1, t2);
var ax = a[0];
var ay = a[1];
var bx = a[2];
var by = a[3];
var cx = a[4];
var cy = a[5];
var dx = a[6];
var dy = a[7];
if (alreadyDrawnCubic(ax, ay, bx, by, cx, cy, dx, dy)) {
return;
}
ctx.beginPath();
ctx.moveTo((ax - srcLeft) * scale,
(ay - srcTop) * scale);
ctx.bezierCurveTo((bx - srcLeft) * scale,
(by - srcTop) * scale,
(cx - srcLeft) * scale,
(cy - srcTop) * scale,
(dx - srcLeft) * scale,
(dy - srcTop) * scale);
ctx.stroke();
}
function drawCurve(c) {
switch (c.length) {
case 4:
drawLine(c[0], c[1], c[2], c[3]);
break;
case 6:
drawQuad(c[0], c[1], c[2], c[3], c[4], c[5]);
break;
case 7:
drawConicWithQuads(c[0], c[1], c[2], c[3], c[4], c[5], c[6]);
break;
case 8:
drawCubic(c[0], c[1], c[2], c[3], c[4], c[5], c[6], c[7]);
break;
}
}
function boundsWidth(pts) {
var min = pts[0];
var max = pts[0];
var length = pts.length == 7 ? 6 : pts.length;
for (var idx = 2; idx < length; idx += 2) {
min = Math.min(min, pts[idx]);
max = Math.max(max, pts[idx]);
}
return max - min;
}
function boundsHeight(pts) {
var min = pts[1];
var max = pts[1];
var length = pts.length == 7 ? 6 : pts.length;
for (var idx = 3; idx < length; idx += 2) {
min = Math.min(min, pts[idx]);
max = Math.max(max, pts[idx]);
}
return max - min;
}
function tangent(pts) {
var dx = pts[2] - pts[0];
var dy = pts[3] - pts[1];
if (dx == 0 && dy == 0 && pts.length > 4) {
dx = pts[4] - pts[0];
dy = pts[5] - pts[1];
if (dx == 0 && dy == 0 && pts.length == 8) {
dx = pts[6] - pts[0];
dy = pts[7] - pts[1];
}
}
return Math.atan2(-dy, dx);
}
function hodograph(cubic) {
var hodo = [];
hodo[0] = 3 * (cubic[2] - cubic[0]);
hodo[1] = 3 * (cubic[3] - cubic[1]);
hodo[2] = 3 * (cubic[4] - cubic[2]);
hodo[3] = 3 * (cubic[5] - cubic[3]);
hodo[4] = 3 * (cubic[6] - cubic[4]);
hodo[5] = 3 * (cubic[7] - cubic[5]);
return hodo;
}
function hodograph2(cubic) {
var quad = hodograph(cubic);
var hodo = [];
hodo[0] = 2 * (quad[2] - quad[0]);
hodo[1] = 2 * (quad[3] - quad[1]);
hodo[2] = 2 * (quad[4] - quad[2]);
hodo[3] = 2 * (quad[5] - quad[3]);
return hodo;
}
function quadraticRootsReal(A, B, C, s) {
if (A == 0) {
if (B == 0) {
s[0] = 0;
return C == 0;
}
s[0] = -C / B;
return 1;
}
/* normal form: x^2 + px + q = 0 */
var p = B / (2 * A);
var q = C / A;
var p2 = p * p;
if (p2 < q) {
return 0;
}
var sqrt_D = 0;
if (p2 > q) {
sqrt_D = sqrt(p2 - q);
}
s[0] = sqrt_D - p;
s[1] = -sqrt_D - p;
return 1 + s[0] != s[1];
}
function add_valid_ts(s, realRoots, t) {
var foundRoots = 0;
for (var index = 0; index < realRoots; ++index) {
var tValue = s[index];
if (tValue >= 0 && tValue <= 1) {
for (var idx2 = 0; idx2 < foundRoots; ++idx2) {
if (t[idx2] != tValue) {
t[foundRoots++] = tValue;
}
}
}
}
return foundRoots;
}
function quadraticRootsValidT(a, b, c, t) {
var s = [];
var realRoots = quadraticRootsReal(A, B, C, s);
var foundRoots = add_valid_ts(s, realRoots, t);
return foundRoots != 0;
}
function find_cubic_inflections(cubic, tValues) {
var Ax = src[2] - src[0];
var Ay = src[3] - src[1];
var Bx = src[4] - 2 * src[2] + src[0];
var By = src[5] - 2 * src[3] + src[1];
var Cx = src[6] + 3 * (src[2] - src[4]) - src[0];
var Cy = src[7] + 3 * (src[3] - src[5]) - src[1];
return quadraticRootsValidT(Bx * Cy - By * Cx, (Ax * Cy - Ay * Cx),
Ax * By - Ay * Bx, tValues);
}
function dxy_at_t(curve, type, t) {
var dxy = {};
if (type == PATH_QUAD) {
var a = t - 1;
var b = 1 - 2 * t;
var c = t;
dxy.x = a * curve[0] + b * curve[2] + c * curve[4];
dxy.y = a * curve[1] + b * curve[3] + c * curve[5];
} else if (type == PATH_CONIC) {
var p20x = curve[4] - curve[0];
var p20y = curve[5] - curve[1];
var p10xw = (curve[2] - curve[0]) * curve[6];
var p10yw = (curve[3] - curve[1]) * curve[6];
var coeff0x = curve[6] * p20x - p20x;
var coeff0y = curve[6] * p20y - p20y;
var coeff1x = p20x - 2 * p10xw;
var coeff1y = p20y - 2 * p10yw;
dxy.x = t * (t * coeff0x + coeff1x) + p10xw;
dxy.y = t * (t * coeff0y + coeff1y) + p10yw;
} else if (type == PATH_CUBIC) {
var one_t = 1 - t;
var a = curve[0];
var b = curve[2];
var c = curve[4];
var d = curve[6];
dxy.x = 3 * ((b - a) * one_t * one_t + 2 * (c - b) * t * one_t + (d - c) * t * t);
a = curve[1];
b = curve[3];
c = curve[5];
d = curve[7];
dxy.y = 3 * ((b - a) * one_t * one_t + 2 * (c - b) * t * one_t + (d - c) * t * t);
}
return dxy;
}
function drawLabel(num, px, py) {
ctx.beginPath();
ctx.arc(px, py, 8, 0, Math.PI*2, true);
ctx.closePath();
ctx.strokeStyle = "rgba(0,0,0, 0.4)";
ctx.lineWidth = num == 0 || num == 3 ? 2 : 1;
ctx.stroke();
ctx.fillStyle = "black";
ctx.font = "normal 10px Arial";
// ctx.rotate(0.001);
ctx.fillText(num, px - 2, py + 3);
// ctx.rotate(-0.001);
}
function drawLabelX(ymin, num, loc) {
var px = (loc - srcLeft) * scale;
var py = (ymin - srcTop) * scale - 20;
drawLabel(num, px, py);
}
function drawLabelY(xmin, num, loc) {
var px = (xmin - srcLeft) * scale - 20;
var py = (loc - srcTop) * scale;
drawLabel(num, px, py);
}
function drawHodoOrigin(hx, hy, hMinX, hMinY, hMaxX, hMaxY) {
ctx.beginPath();
ctx.moveTo(hx, hy - 100);
ctx.lineTo(hx, hy);
ctx.strokeStyle = hMinY < 0 ? "green" : "blue";
ctx.stroke();
ctx.beginPath();
ctx.moveTo(hx, hy);
ctx.lineTo(hx, hy + 100);
ctx.strokeStyle = hMaxY > 0 ? "green" : "blue";
ctx.stroke();
ctx.beginPath();
ctx.moveTo(hx - 100, hy);
ctx.lineTo(hx, hy);
ctx.strokeStyle = hMinX < 0 ? "green" : "blue";
ctx.stroke();
ctx.beginPath();
ctx.moveTo(hx, hy);
ctx.lineTo(hx + 100, hy);
ctx.strokeStyle = hMaxX > 0 ? "green" : "blue";
ctx.stroke();
}
function scalexy(x, y, mag) {
var length = Math.sqrt(x * x + y * y);
return mag / length;
}
function drawArrow(x, y, dx, dy, s) {
var dscale = scalexy(dx, dy, 1 / scale * 100 * s);
dx *= dscale;
dy *= dscale;
ctx.beginPath();
ctx.moveTo((x - srcLeft) * scale, (y - srcTop) * scale);
x += dx;
y += dy;
ctx.lineTo((x - srcLeft) * scale, (y - srcTop) * scale);
dx /= 10;
dy /= 10;
ctx.lineTo((x - dy - srcLeft) * scale, (y + dx - srcTop) * scale);
ctx.lineTo((x + dx * 2 - srcLeft) * scale, (y + dy * 2 - srcTop) * scale);
ctx.lineTo((x + dy - srcLeft) * scale, (y - dx - srcTop) * scale);
ctx.lineTo((x - srcLeft) * scale, (y - srcTop) * scale);
ctx.strokeStyle = "rgba(0,75,0, 0.4)";
ctx.stroke();
}
function x_at_t(curve, t) {
var one_t = 1 - t;
if (curve.length == 4) {
return one_t * curve[0] + t * curve[2];
}
var one_t2 = one_t * one_t;
var t2 = t * t;
if (curve.length == 6) {
return one_t2 * curve[0] + 2 * one_t * t * curve[2] + t2 * curve[4];
}
if (curve.length == 7) {
return (one_t2 * curve[0] + 2 * one_t * t * curve[2] * curve[6] + t2 * curve[4])
/ (one_t2 +2 * one_t * t * curve[6] + t2);
}
var a = one_t2 * one_t;
var b = 3 * one_t2 * t;
var c = 3 * one_t * t2;
var d = t2 * t;
return a * curve[0] + b * curve[2] + c * curve[4] + d * curve[6];
}
function y_at_t(curve, t) {
var one_t = 1 - t;
if (curve.length == 4) {
return one_t * curve[1] + t * curve[3];
}
var one_t2 = one_t * one_t;
var t2 = t * t;
if (curve.length == 6) {
return one_t2 * curve[1] + 2 * one_t * t * curve[3] + t2 * curve[5];
}
if (curve.length == 7) {
return (one_t2 * curve[1] + 2 * one_t * t * curve[3] * curve[6] + t2 * curve[5])
/ (one_t2 +2 * one_t * t * curve[6] + t2);
}
var a = one_t2 * one_t;
var b = 3 * one_t2 * t;
var c = 3 * one_t * t2;
var d = t2 * t;
return a * curve[1] + b * curve[3] + c * curve[5] + d * curve[7];
}
function drawOrder(curve, label) {
var px = x_at_t(curve, 0.75);
var py = y_at_t(curve, 0.75);
var _px = (px - srcLeft) * scale;
var _py = (py - srcTop) * scale;
ctx.beginPath();
ctx.arc(_px, _py, 15, 0, Math.PI * 2, true);
ctx.closePath();
ctx.fillStyle = "white";
ctx.fill();
if (label == 'L') {
ctx.strokeStyle = "rgba(255,0,0, 1)";
ctx.fillStyle = "rgba(255,0,0, 1)";
} else {
ctx.strokeStyle = "rgba(0,0,255, 1)";
ctx.fillStyle = "rgba(0,0,255, 1)";
}
ctx.stroke();
ctx.font = "normal 16px Arial";
ctx.textAlign = "center";
ctx.fillText(label, _px, _py + 5);
ctx.font = "normal 10px Arial";
}
function drawID(curve, id) {
var px = x_at_t(curve, 0.5);
var py = y_at_t(curve, 0.5);
var _px = (px - srcLeft) * scale;
var _py = (py - srcTop) * scale;
draw_id_at(id, _px, _py);
}
function draw_id_at(id, _px, _py) {
ctx.beginPath();
ctx.arc(_px, _py, 15, 0, Math.PI * 2, true);
ctx.closePath();
ctx.fillStyle = "white";
ctx.fill();
ctx.strokeStyle = "rgba(127,127,0, 1)";
ctx.fillStyle = "rgba(127,127,0, 1)";
ctx.stroke();
ctx.font = "normal 16px Arial";
ctx.textAlign = "center";
ctx.fillText(id, _px, _py + 5);
ctx.font = "normal 10px Arial";
}
function drawLinePartialID(id, x1, y1, x2, y2, t1, t2) {
var curve = [x1, y1, x2, y2];
drawCurvePartialID(id, curve, t1, t2);
}
function drawQuadPartialID(id, x1, y1, x2, y2, x3, y3, t1, t2) {
var curve = [x1, y1, x2, y2, x3, y3];
drawCurvePartialID(id, curve, t1, t2);
}
function drawConicPartialID(id, x1, y1, x2, y2, x3, y3, w, t1, t2) {
var curve = [x1, y1, x2, y2, x3, y3, w];
drawCurvePartialID(id, curve, t1, t2);
}
function drawCubicPartialID(id, x1, y1, x2, y2, x3, y3, x4, y4, t1, t2) {
var curve = [x1, y1, x2, y2, x3, y3, x4, y4];
drawCurvePartialID(id, curve, t1, t2);
}
function drawCurvePartialID(id, curve, t1, t2) {
var px = x_at_t(curve, (t1 + t2) / 2);
var py = y_at_t(curve, (t1 + t2) / 2);
var _px = (px - srcLeft) * scale;
var _py = (py - srcTop) * scale;
draw_id_at(id, _px, _py);
}
function drawCurveSpecials(test, curve, type) {
if (pt_labels) {
drawPoints(curve, type, pt_labels == 2);
}
if (control_lines != 0) {
drawControlLines(curve, type, control_lines);
}
if (curve_t) {
drawPointAtT(curve, type);
}
if (draw_midpoint) {
var mid = pointAtT(curve, type, 0.5);
drawPoint(mid.x, mid.y, true);
}
if (draw_id) {
var id = idByCurve(test, curve, type);
if (id >= 0) {
drawID(curve, id);
}
}
if (type == PATH_LINE) {
return;
}
if (draw_deriviatives > 0) {
var d = dxy_at_t(curve, type, 0);
drawArrow(curve[0], curve[1], d.x, d.y, 1);
if (draw_deriviatives == 2) {
d = dxy_at_t(curve, type, 1);
if (type == PATH_CUBIC) {
drawArrow(curve[6], curve[7], d.x, d.y, 1);
} else {
drawArrow(curve[4], curve[5], d.x, d.y, 1);
}
}
if (draw_midpoint) {
var mid = pointAtT(curve, type, 0.5);
d = dxy_at_t(curve, type, 0.5);
drawArrow(mid.x, mid.y, d.x, d.y, 1);
}
}
if (type != PATH_CUBIC) {
return;
}
if (draw_sequence) {
var ymin = Math.min(curve[1], curve[3], curve[5], curve[7]);
for (var i = 0; i < 8; i+= 2) {
drawLabelX(ymin, i >> 1, curve[i]);
}
var xmin = Math.min(curve[0], curve[2], curve[4], curve[6]);
for (var i = 1; i < 8; i+= 2) {
drawLabelY(xmin, i >> 1, curve[i]);
}
}
}
function logCurves(test) {
for (curves in test) {
var curve = test[curves];
dumpCurve(curve);
}
}
function curveToString(curve) {
var str = "{{";
var length = curve.length == 7 ? 6 : curve.length;
if (curve.length == 7) {
str += "{";
}
for (i = 0; i < length; i += 2) {
str += curve[i].toFixed(decimal_places) + "," + curve[i + 1].toFixed(decimal_places);
if (i < curve.length - 2) {
str += "}, {";
}
}
str += "}";
if (curve.length == 7) {
str += "}, " + curve[6].toFixed(decimal_places);
}
str += "}";
return str;
}
function dumpCurve(curve) {
console.log(curveToString(curve));
}
function draw(test, lines, title) {
ctx.fillStyle = "rgba(0,0,0, 0.1)";
ctx.font = "normal 50px Arial";
ctx.textAlign = "left";
ctx.fillText(title, 50, 50);
ctx.font = "normal 10px Arial";
ctx.lineWidth = "1.001"; "0.999";
var secondPath = test.length;
var closeCount = 0;
logStart = -1;
logRange = 0;
// find last active rec type at this step
var curType = test[0];
var curStep = 0;
var hasOp = false;
var lastActive = 0;
var lastAdd = 0;
var lastCoin = 0;
var lastSect = 0;
var lastSort = 0;
var lastMark = 0;
var lastTop = 0;
activeCount = 0;
addCount = 0;
angleCount = 0;
opCount = 0;
sectCount = 0;
sortCount = 0;
topCount = 0;
markCount = 0;
activeMax = 0;
addMax = 0;
angleMax = 0;
coinMax = 0;
opMax = 0;
sectMax = 0;
sectMax2 = 0;
sortMax = 0;
topMax = 0;
markMax = 0;
lastIndex = test.length - 3;
for (var tIndex = 0; tIndex < test.length; tIndex += 3) {
var recType = test[tIndex];
if (!typeof recType == 'number' || recType < REC_TYPE_UNKNOWN || recType > REC_TYPE_LAST) {
console.log("unknown rec type: " + recType);
throw "stop execution";
}
// if (curType == recType && curType != REC_TYPE_ADD) {
// continue;
// }
var inStepRange = step_limit == 0 || curStep < step_limit;
curType = recType;
if (recType == REC_TYPE_OP) {
hasOp = true;
continue;
}
if (recType == REC_TYPE_UNKNOWN) {
// these types do not advance step
continue;
}
var bumpStep = false;
var records = test[tIndex + 2];
var fragType = records[0];
if (recType == REC_TYPE_ADD) {
if (records.length != 2) {
console.log("expect only two elements: " + records.length);
throw "stop execution";
}
if (fragType == ADD_MOVETO || fragType == ADD_CLOSE) {
continue;
}
++addMax;
if (!draw_add || !inStepRange) {
continue;
}
lastAdd = tIndex;
++addCount;
bumpStep = true;
}
if (recType == REC_TYPE_PATH && hasOp) {
secondPath = tIndex;
}
if (recType == REC_TYPE_PATH2 && hasOp) {
secondPath = tIndex;
}
if (recType == REC_TYPE_ACTIVE) {
++activeMax;
if (!draw_active || !inStepRange) {
continue;
}
lastActive = tIndex;
++activeCount;
bumpStep = true;
}
if (recType == REC_TYPE_ACTIVE_OP) {
++opMax;
if (!draw_op || !inStepRange) {
continue;
}
lastOp = tIndex;
++opCount;
bumpStep = true;
}
if (recType == REC_TYPE_AFTERPART) {
if (draw_angle != 3 || !inStepRange) {
continue;
}
lastAngle = tIndex;
++angleCount;
bumpStep = true;
}
if (recType == REC_TYPE_ANGLE) {
++angleMax;
if (draw_angle == 0 || draw_angle == 3 || !inStepRange) {
continue;
}
lastAngle = tIndex;
++angleCount;
bumpStep = true;
}
if (recType == REC_TYPE_COINCIDENCE) {
++coinMax;
if (!draw_coincidence || !inStepRange) {
continue;
}
lastCoin = tIndex;
++coinCount;
bumpStep = true;
}
if (recType == REC_TYPE_SECT) {
if (records.length != 2) {
console.log("expect only two elements: " + records.length);
throw "stop execution";
}
++sectMax;
var sectBump = 1;
switch (fragType) {
case INTERSECT_LINE:
case INTERSECT_QUAD_LINE:
case INTERSECT_QUAD:
case INTERSECT_CONIC_LINE:
case INTERSECT_CONIC:
case INTERSECT_SELF_CUBIC:
case INTERSECT_CUBIC_LINE:
case INTERSECT_CUBIC_QUAD:
case INTERSECT_CUBIC:
sectBump = 1;
break;
case INTERSECT_LINE_2:
case INTERSECT_QUAD_LINE_2:
case INTERSECT_QUAD_2:
case INTERSECT_CONIC_LINE_2:
case INTERSECT_CONIC_2:
case INTERSECT_CUBIC_LINE_2:
case INTERSECT_CUBIC_QUAD_2:
case INTERSECT_CUBIC_2:
sectBump = 2;
break;
case INTERSECT_LINE_NO:
case INTERSECT_QUAD_LINE_NO:
case INTERSECT_QUAD_NO:
case INTERSECT_CONIC_LINE_NO:
case INTERSECT_CONIC_NO:
case INTERSECT_SELF_CUBIC_NO:
case INTERSECT_CUBIC_LINE_NO:
case INTERSECT_CUBIC_QUAD_NO:
case INTERSECT_CUBIC_NO:
sectBump = 0;
break;
case INTERSECT_CUBIC_LINE_3:
case INTERSECT_CUBIC_QUAD_3:
case INTERSECT_CUBIC_3:
sectBump = 3;
break;
case INTERSECT_CUBIC_QUAD_4:
case INTERSECT_CUBIC_4:
sectBump = 4;
break;
default:
console.log("missing case " + records.length);
throw "stop execution";
}
sectMax2 += sectBump;
if (draw_intersection <= 1 || !inStepRange) {
continue;
}
lastSect = tIndex;
sectCount += sectBump;
bumpStep = true;
}
if (recType == REC_TYPE_SORT) {
++sortMax;
if (!draw_sort || !inStepRange) {
continue;
}
lastSort = tIndex;
++sortCount;
bumpStep = true;
}
if (recType == REC_TYPE_TOP) {
++topMax;
if (!draw_top || !inStepRange) {
continue;
}
lastTop = tIndex;
++topCount;
bumpStep = true;
}
if (recType == REC_TYPE_MARK) {
++markMax;
if (!draw_mark || !inStepRange) {
continue;
}
lastMark = tIndex;
++markCount;
bumpStep = true;
}
if (bumpStep) {
lastIndex = tIndex;
logStart = test[tIndex + 1];
logRange = records.length / 2;
++curStep;
}
}
stepMax = (draw_add ? addMax : 0)
+ (draw_active ? activeMax : 0)
+ (draw_angle ? angleMax : 0)
+ (draw_coincidence ? coinMax : 0)
+ (draw_op ? opMax : 0)
+ (draw_sort ? sortMax : 0)
+ (draw_top ? topMax : 0)
+ (draw_mark ? markMax : 0)
+ (draw_intersection == 2 ? sectMax : draw_intersection == 3 ? sectMax2 : 0);
if (stepMax == 0) {
stepMax = addMax + activeMax + angleMax + coinMax + opMax + sortMax + topMax + markMax;
}
drawnPts = [];
drawnLines = [];
drawnQuads = [];
drawnConics = [];
drawnCubics = [];
focusXmin = focusYmin = Infinity;
focusXmax = focusYmax = -Infinity;
var pathIndex = 0;
var opLetter = 'S';
for (var tIndex = lastIndex; tIndex >= 0; tIndex -= 3) {
var recType = test[tIndex];
var records = test[tIndex + 2];
for (var recordIndex = 0; recordIndex < records.length; recordIndex += 2) {
var fragType = records[recordIndex];
if (!typeof fragType == 'number' || fragType < 1 || fragType > FRAG_TYPE_LAST) {
console.log("unknown in range frag type: " + fragType);
throw "stop execution";
}
var frags = records[recordIndex + 1];
focus_enabled = false;
switch (recType) {
case REC_TYPE_COMPUTED:
if (draw_computed == 0) {
continue;
}
ctx.lineWidth = 1;
ctx.strokeStyle = pathIndex == 0 ? "black" : "red";
ctx.fillStyle = "blue";
var drawThis = false;
switch (fragType) {
case PATH_QUAD:
if ((draw_computed & 0x9) == 1 || ((draw_computed & 8) != 0
&& (draw_computed & 7) == pathIndex)) {
drawQuad(frags[0], frags[1], frags[2], frags[3],
frags[4], frags[5]);
drawThis = true;
}
break;
case PATH_CONIC:
if ((draw_computed & 0xA) == 2 || ((draw_computed & 8) != 0
&& (draw_computed & 7) == pathIndex)) {
drawConicWithQuads(frags[0], frags[1], frags[2], frags[3],
frags[4], frags[5], frags[6]);
drawThis = true;
}
break;
case PATH_CUBIC:
if ((draw_computed & 0xC) == 4 || ((draw_computed & 8) != 0
&& (draw_computed & 7) == pathIndex)) {
drawCubic(frags[0], frags[1], frags[2], frags[3],
frags[4], frags[5], frags[6], frags[7]);
drawThis = true;
}
++pathIndex;
break;
case COMPUTED_SET_1:
pathIndex = 0;
break;
case COMPUTED_SET_2:
pathIndex = 1;
break;
default:
console.log("unknown REC_TYPE_COMPUTED frag type: " + fragType);
throw "stop execution";
}
if (!drawThis || collect_bounds) {
break;
}
drawCurveSpecials(test, frags, fragType);
break;
case REC_TYPE_ALIGNED:
if (draw_path < 4) {
continue;
}
case REC_TYPE_PATH:
case REC_TYPE_PATH2:
if (REC_TYPE_ALIGNED != recType && draw_path >= 4) {
continue;
}
if (!draw_path) {
continue;
}
var firstPath = tIndex < secondPath;
if ((draw_path & (firstPath ? 1 : 2)) == 0) {
continue;
}
ctx.lineWidth = 1;
ctx.strokeStyle = firstPath ? "black" : "red";
ctx.fillStyle = "blue";
var frags2 = [];
switch (fragType) {
case PATH_LINE:
for (var i = 0; i < 4; ++ i) { frags2[i] = frags[i + 1]; }
drawLine(frags2[0], frags2[1], frags2[2], frags2[3]);
break;
case PATH_QUAD:
for (var i = 0; i < 6; ++ i) { frags2[i] = frags[i + 1]; }
drawQuad(frags2[0], frags2[1], frags2[2], frags2[3],
frags2[4], frags2[5]);
break;
case PATH_CONIC:
for (var i = 0; i < 7; ++ i) { frags2[i] = frags[i + 1]; }
drawConicWithQuads(frags2[0], frags2[1], frags2[2], frags2[3],
frags2[4], frags2[5], frags2[6]);
break;
case PATH_CUBIC:
for (var i = 0; i < 8; ++ i) { frags2[i] = frags[i + 1]; }
drawCubic(frags2[0], frags2[1], frags2[2], frags2[3],
frags2[4], frags2[5], frags2[6], frags2[7]);
break;
default:
console.log("unknown " + recType + " frag type: " + fragType);
throw "stop execution";
}
if (collect_bounds) {
break;
}
drawCurveSpecials(test, frags2, fragType);
break;
case REC_TYPE_OP:
switch (fragType) {
case OP_INTERSECT: opLetter = 'I'; break;
case OP_DIFFERENCE: opLetter = 'D'; break;
case OP_UNION: opLetter = 'U'; break;
case OP_XOR: opLetter = 'X'; break;
default:
console.log("unknown REC_TYPE_OP frag type: " + fragType);
throw "stop execution";
}
break;
case REC_TYPE_ACTIVE:
if (!draw_active || (step_limit > 0 && tIndex < lastActive)) {
continue;
}
var x1 = frags[SPAN_X1];
var y1 = frags[SPAN_Y1];
var x2 = frags[SPAN_X2];
var y2 = frags[SPAN_Y2];
var x3, y3, x3, y4, t1, t2, w;
ctx.lineWidth = 3;
ctx.strokeStyle = "rgba(0,0,255, 0.3)";
focus_enabled = true;
switch (fragType) {
case ACTIVE_LINE_SPAN:
t1 = frags[SPAN_L_T];
t2 = frags[SPAN_L_TEND];
drawLinePartial(x1, y1, x2, y2, t1, t2);
if (draw_id) {
drawLinePartialID(frags[0], x1, y1, x2, y2, t1, t2);
}
break;
case ACTIVE_QUAD_SPAN:
x3 = frags[SPAN_X3];
y3 = frags[SPAN_Y3];
t1 = frags[SPAN_Q_T];
t2 = frags[SPAN_Q_TEND];
drawQuadPartial(x1, y1, x2, y2, x3, y3, t1, t2);
if (draw_id) {
drawQuadPartialID(frags[0], x1, y1, x2, y2, x3, y3, t1, t2);
}
break;
case ACTIVE_CONIC_SPAN:
x3 = frags[SPAN_X3];
y3 = frags[SPAN_Y3];
t1 = frags[SPAN_K_T];
t2 = frags[SPAN_K_TEND];
w = frags[SPAN_K_W];
drawConicPartial(x1, y1, x2, y2, x3, y3, w, t1, t2);
if (draw_id) {
drawConicPartialID(frags[0], x1, y1, x2, y2, x3, y3, w, t1, t2);
}
break;
case ACTIVE_CUBIC_SPAN:
x3 = frags[SPAN_X3];
y3 = frags[SPAN_Y3];
x4 = frags[SPAN_X4];
y4 = frags[SPAN_Y4];
t1 = frags[SPAN_C_T];
t2 = frags[SPAN_C_TEND];
drawCubicPartial(x1, y1, x2, y2, x3, y3, x4, y4, t1, t2);
if (draw_id) {
drawCubicPartialID(frags[0], x1, y1, x2, y2, x3, y3, x4, y4, t1, t2);
}
break;
default:
console.log("unknown REC_TYPE_ACTIVE frag type: " + fragType);
throw "stop execution";
}
break;
case REC_TYPE_ACTIVE_OP:
if (!draw_op || (step_limit > 0 && tIndex < lastOp)) {
continue;
}
focus_enabled = true;
ctx.lineWidth = 3;
var activeSpan = frags[7] == "1";
ctx.strokeStyle = activeSpan ? "rgba(45,160,0, 0.3)" : "rgba(255,45,0, 0.5)";
var curve = curvePartialByID(test, frags[0], frags[1], frags[2]);
drawCurve(curve);
if (draw_op > 1) {
drawArc(curve, false, frags[3], frags[4]);
drawArc(curve, true, frags[5], frags[6]);
}
break;
case REC_TYPE_ADD:
if (!draw_add) {
continue;
}
ctx.lineWidth = 3;
ctx.strokeStyle = closeCount == 0 ? "rgba(0,0,255, 0.3)"
: closeCount == 1 ? "rgba(0,127,0, 0.3)"
: closeCount == 2 ? "rgba(0,127,127, 0.3)"
: closeCount == 3 ? "rgba(127,127,0, 0.3)"
: "rgba(127,0,127, 0.3)";
focus_enabled = true;
switch (fragType) {
case ADD_MOVETO:
break;
case ADD_LINETO:
if (step_limit == 0 || tIndex >= lastAdd) {
drawLine(frags[0], frags[1], frags[2], frags[3]);
}
break;
case ADD_QUADTO:
if (step_limit == 0 || tIndex >= lastAdd) {
drawQuad(frags[0], frags[1], frags[2], frags[3], frags[4], frags[5]);
}
break;
case ADD_CONICTO:
if (step_limit == 0 || tIndex >= lastAdd) {
drawConicWithQuads(frags[0], frags[1], frags[2], frags[3],
frags[4], frags[5], frags[6]);
}
break;
case ADD_CUBICTO:
if (step_limit == 0 || tIndex >= lastAdd) {
drawCubic(frags[0], frags[1], frags[2], frags[3],
frags[4], frags[5], frags[6], frags[7]);
}
break;
case ADD_CLOSE:
++closeCount;
break;
case ADD_FILL:
break;
default:
console.log("unknown REC_TYPE_ADD frag type: " + fragType);
throw "stop execution";
}
break;
case REC_TYPE_ANGLE:
angleBetween = frags[18] == "T";
afterIndex = 0;
if (draw_angle == 0 || draw_angle == 3 || (step_limit > 0 && tIndex < lastAngle)) {
continue;
}
focus_enabled = true;
ctx.lineWidth = 3;
ctx.strokeStyle = "rgba(127,45,127, 0.3)";
var leftCurve = curvePartialByID(test, frags[0], frags[4], frags[5]);
var midCurve = curvePartialByID(test, frags[6], frags[10], frags[11]);
var rightCurve = curvePartialByID(test, frags[12], frags[16], frags[17]);
drawCurve(leftCurve);
drawCurve(rightCurve);
ctx.strokeStyle = angleBetween ? "rgba(0,160,45, 0.3)" : "rgba(255,0,45, 0.5)";
drawCurve(midCurve);
if (draw_angle > 1) {
drawOrder(leftCurve, 'L');
drawOrder(rightCurve, 'R');
}
break;
case REC_TYPE_AFTERPART:
if (draw_angle != 3 || (step_limit > 0 && tIndex < lastAngle)) {
continue;
}
ctx.strokeStyle = afterIndex == 0 ? "rgba(255,0,0, 1.0)"
: (afterIndex == 1) == angleBetween ? "rgba(0,128,0, 1.0)"
: "rgba(0,0,255, 1.0)";
switch (fragType) {
case PATH_LINE:
drawLine(frags[0], frags[1], frags[2], frags[3]);
break;
case PATH_QUAD:
drawQuad(frags[0], frags[1], frags[2], frags[3],
frags[4], frags[5]);
break;
case PATH_CONIC:
drawConicWithQuads(frags[0], frags[1], frags[2], frags[3],
frags[4], frags[5], frags[6]);
break;
case PATH_CUBIC:
drawCubic(frags[0], frags[1], frags[2], frags[3],
frags[4], frags[5], frags[6], frags[7]);
break;
default:
console.log("unknown REC_TYPE_AFTERPART frag type: " + fragType);
throw "stop execution";
}
++afterIndex;
break;
case REC_TYPE_COINCIDENCE:
if (!draw_coincidence || (step_limit > 0 && tIndex < lastCoin)) {
continue;
}
focus_enabled = true;
ctx.lineWidth = 3;
ctx.strokeStyle = "rgba(127,45,63, 0.3)";
var curve = curvePartialByID(test, frags[0], frags[1], frags[2]);
drawCurve(curve);
break;
case REC_TYPE_SECT:
if (!draw_intersection) {
continue;
}
if (draw_intersection != 1 && (step_limit > 0 && tIndex < lastSect)) {
continue;
}
// draw_intersection == 1 : show all
// draw_intersection == 2 : step == 0 ? show all : show intersection line #step
// draw_intersection == 3 : step == 0 ? show all : show intersection #step
ctx.lineWidth = 1;
ctx.strokeStyle = "rgba(0,0,255, 0.3)";
ctx.fillStyle = "blue";
focus_enabled = true;
var f = [];
var c1s;
var c1l;
var c2s;
var c2l;
switch (fragType) {
case INTERSECT_LINE:
f.push(5, 6, 0, 7);
c1s = 1; c1l = 4; c2s = 8; c2l = 4;
break;
case INTERSECT_LINE_2:
f.push(5, 6, 0, 10);
f.push(8, 9, 7, 15);
c1s = 1; c1l = 4; c2s = 11; c2l = 4;
break;
case INTERSECT_LINE_NO:
c1s = 0; c1l = 4; c2s = 4; c2l = 4;
break;
case INTERSECT_QUAD_LINE:
f.push(7, 8, 0, 9);
c1s = 1; c1l = 6; c2s = 10; c2l = 4;
break;
case INTERSECT_QUAD_LINE_2:
f.push(7, 8, 0, 12);
f.push(10, 11, 9, 17);
c1s = 1; c1l = 6; c2s = 13; c2l = 4;
break;
case INTERSECT_QUAD_LINE_NO:
c1s = 0; c1l = 6; c2s = 6; c2l = 4;
break;
case INTERSECT_QUAD:
f.push(7, 8, 0, 9);
c1s = 1; c1l = 6; c2s = 10; c2l = 6;
break;
case INTERSECT_QUAD_2:
f.push(7, 8, 0, 12);
f.push(10, 11, 9, 19);
c1s = 1; c1l = 6; c2s = 13; c2l = 6;
break;
case INTERSECT_QUAD_NO:
c1s = 0; c1l = 6; c2s = 6; c2l = 6;
break;
case INTERSECT_CONIC_LINE:
f.push(8, 9, 0, 10);
c1s = 1; c1l = 7; c2s = 11; c2l = 4;
break;
case INTERSECT_CONIC_LINE_2:
f.push(8, 9, 0, 12);
f.push(11, 12, 10, 18);
c1s = 1; c1l = 7; c2s = 14; c2l = 4;
break;
case INTERSECT_CONIC_LINE_NO:
c1s = 0; c1l = 7; c2s = 7; c2l = 4;
break;
case INTERSECT_CONIC:
f.push(8, 9, 0, 10);
c1s = 1; c1l = 7; c2s = 11; c2l = 7;
break;
case INTERSECT_CONIC_2:
f.push(8, 9, 0, 13);
f.push(11, 12, 10, 21);
c1s = 1; c1l = 7; c2s = 14; c2l = 7;
break;
case INTERSECT_CONIC_NO:
c1s = 0; c1l = 7; c2s = 7; c2l = 7;
break;
case INTERSECT_SELF_CUBIC:
f.push(9, 10, 0, 11);
c1s = 1; c1l = 8; c2s = 0; c2l = 0;
break;
case INTERSECT_SELF_CUBIC_NO:
c1s = 0; c1l = 8; c2s = 0; c2l = 0;
break;
case INTERSECT_CUBIC_LINE:
f.push(9, 10, 0, 11);
c1s = 1; c1l = 8; c2s = 12; c2l = 4;
break;
case INTERSECT_CUBIC_LINE_2:
f.push(9, 10, 0, 14);
f.push(12, 13, 11, 19);
c1s = 1; c1l = 8; c2s = 15; c2l = 4;
break;
case INTERSECT_CUBIC_LINE_3:
f.push(9, 10, 0, 17);
f.push(12, 13, 11, 22);
f.push(15, 16, 14, 23);
c1s = 1; c1l = 8; c2s = 18; c2l = 4;
break;
case INTERSECT_CUBIC_QUAD_NO:
c1s = 0; c1l = 8; c2s = 8; c2l = 6;
break;
case INTERSECT_CUBIC_QUAD:
f.push(9, 10, 0, 11);
c1s = 1; c1l = 8; c2s = 12; c2l = 6;
break;
case INTERSECT_CUBIC_QUAD_2:
f.push(9, 10, 0, 14);
f.push(12, 13, 11, 21);
c1s = 1; c1l = 8; c2s = 15; c2l = 6;
break;
case INTERSECT_CUBIC_QUAD_3:
f.push(9, 10, 0, 17);
f.push(12, 13, 11, 24);
f.push(15, 16, 14, 25);
c1s = 1; c1l = 8; c2s = 18; c2l = 6;
break;
case INTERSECT_CUBIC_QUAD_4:
f.push(9, 10, 0, 20);
f.push(12, 13, 11, 27);
f.push(15, 16, 14, 28);
f.push(18, 19, 17, 29);
c1s = 1; c1l = 8; c2s = 21; c2l = 6;
break;
case INTERSECT_CUBIC_LINE_NO:
c1s = 0; c1l = 8; c2s = 8; c2l = 4;
break;
case INTERSECT_CUBIC:
f.push(9, 10, 0, 11);
c1s = 1; c1l = 8; c2s = 12; c2l = 8;
break;
case INTERSECT_CUBIC_2:
f.push(9, 10, 0, 14);
f.push(12, 13, 11, 23);
c1s = 1; c1l = 8; c2s = 15; c2l = 8;
break;
case INTERSECT_CUBIC_3:
f.push(9, 10, 0, 17);
f.push(12, 13, 11, 26);
f.push(15, 16, 14, 27);
c1s = 1; c1l = 8; c2s = 18; c2l = 8;
break;
case INTERSECT_CUBIC_4:
f.push(9, 10, 0, 20);
f.push(12, 13, 11, 29);
f.push(15, 16, 14, 30);
f.push(18, 19, 17, 31);
c1s = 1; c1l = 8; c2s = 21; c2l = 8;
break;
case INTERSECT_CUBIC_NO:
c1s = 0; c1l = 8; c2s = 8; c2l = 8;
break;
default:
console.log("unknown REC_TYPE_SECT frag type: " + fragType);
throw "stop execution";
}
if (draw_intersection != 1) {
var id = -1;
var curve;
switch (c1l) {
case 4:
drawLine(frags[c1s], frags[c1s + 1], frags[c1s + 2], frags[c1s + 3]);
if (draw_id) {
curve = [frags[c1s], frags[c1s + 1], frags[c1s + 2], frags[c1s + 3]];
id = idByCurve(test, curve, PATH_LINE);
}
break;
case 6:
drawQuad(frags[c1s], frags[c1s + 1], frags[c1s + 2], frags[c1s + 3],
frags[c1s + 4], frags[c1s + 5]);
if (draw_id) {
curve = [frags[c1s], frags[c1s + 1], frags[c1s + 2], frags[c1s + 3],
frags[c1s + 4], frags[c1s + 5]];
id = idByCurve(test, curve, PATH_QUAD);
}
break;
case 7:
drawConicWithQuads(frags[c1s], frags[c1s + 1], frags[c1s + 2], frags[c1s + 3],
frags[c1s + 4], frags[c1s + 5], frags[c1s + 6]);
if (draw_id) {
curve = [frags[c1s], frags[c1s + 1], frags[c1s + 2], frags[c1s + 3],
frags[c1s + 4], frags[c1s + 5], frags[c1s + 6]];
id = idByCurve(test, curve, PATH_CONIC);
}
break;
case 8:
drawCubic(frags[c1s], frags[c1s + 1], frags[c1s + 2], frags[c1s + 3],
frags[c1s + 4], frags[c1s + 5], frags[c1s + 6], frags[c1s + 7]);
if (draw_id) {
curve = [frags[c1s], frags[c1s + 1], frags[c1s + 2], frags[c1s + 3],
frags[c1s + 4], frags[c1s + 5], frags[c1s + 6], frags[c1s + 7]];
id = idByCurve(test, curve, PATH_CUBIC);
}
break;
}
if (id >= 0) {
drawID(curve, id);
}
id = -1;
switch (c2l) {
case 0:
break;
case 4:
drawLine(frags[c2s], frags[c2s + 1], frags[c2s + 2], frags[c2s + 3]);
if (draw_id) {
curve = [frags[c2s], frags[c2s + 1], frags[c2s + 2], frags[c2s + 3]];
id = idByCurve(test, curve, PATH_LINE);
}
break;
case 6:
drawQuad(frags[c2s], frags[c2s + 1], frags[c2s + 2], frags[c2s + 3],
frags[c2s + 4], frags[c2s + 5]);
if (draw_id) {
curve = [frags[c2s], frags[c2s + 1], frags[c2s + 2], frags[c2s + 3],
frags[c2s + 4], frags[c2s + 5]];
id = idByCurve(test, curve, PATH_QUAD);
}
break;
case 7:
drawConicWithQuads(frags[c2s], frags[c2s + 1], frags[c2s + 2], frags[c2s + 3],
frags[c2s + 4], frags[c2s + 5], frags[c2s + 6]);
if (draw_id) {
curve = [frags[c2s], frags[c2s + 1], frags[c2s + 2], frags[c2s + 3],
frags[c2s + 4], frags[c2s + 5], frags[c2s + 6]];
id = idByCurve(test, curve, PATH_CONIC);
}
break;
case 8:
drawCubic(frags[c2s], frags[c2s + 1], frags[c2s + 2], frags[c2s + 3],
frags[c2s + 4], frags[c2s + 5], frags[c2s + 6], frags[c2s + 7]);
if (draw_id) {
curve = [frags[c2s], frags[c2s + 1], frags[c2s + 2], frags[c2s + 3],
frags[c2s + 4], frags[c2s + 5], frags[c2s + 6], frags[c2s + 7]];
id = idByCurve(test, curve, PATH_CUBIC);
}
break;
}
if (id >= 0) {
drawID(curve, id);
}
}
if (collect_bounds) {
break;
}
if (draw_intersection != 3 || step_limit == 0 || tIndex >= lastSect) {
for (var idx = 0; idx < f.length; idx += 4) {
drawPoint(frags[f[idx]], frags[f[idx + 1]], true);
}
}
if (!draw_intersectT) {
break;
}
ctx.fillStyle = "red";
if (draw_intersection != 3 || step_limit == 0 || tIndex >= lastSect) {
for (var idx = 0; idx < f.length; idx += 4) {
drawTAtPointUp(frags[f[idx]], frags[f[idx + 1]], frags[f[idx + 2]]);
drawTAtPointDown(frags[f[idx]], frags[f[idx + 1]], frags[f[idx + 3]]);
}
}
break;
case REC_TYPE_SORT:
if (!draw_sort || (step_limit > 0 && tIndex < lastSort)) {
continue;
}
ctx.lineWidth = 3;
ctx.strokeStyle = "rgba(127,127,0, 0.5)";
focus_enabled = true;
switch (fragType) {
case SORT_UNARY:
case SORT_BINARY:
var curve = curvePartialByID(test, frags[0], frags[6], frags[8]);
drawCurve(curve);
break;
default:
console.log("unknown REC_TYPE_SORT frag type: " + fragType);
throw "stop execution";
}
break;
case REC_TYPE_TOP:
if (!draw_top || (step_limit > 0 && tIndex < lastTop)) {
continue;
}
ctx.lineWidth = 3;
ctx.strokeStyle = "rgba(127,127,0, 0.5)";
focus_enabled = true;
{
var curve = curvePartialByID(test, frags[0], frags[1], frags[2]);
drawCurve(curve);
var type = PATH_LINE + (curve.length / 2 - 2);
var mid = pointAtT(curve, type, 0.5);
var d = dxy_at_t(curve, type, 0.5);
drawArrow(mid.x, mid.y, d.x, d.y, 0.3);
}
break;
case REC_TYPE_MARK:
if (!draw_mark || (step_limit > 0 && tIndex < lastMark)) {
continue;
}
ctx.lineWidth = 3;
ctx.strokeStyle = fragType >= MARK_DONE_LINE ?
"rgba(127,0,127, 0.5)" : "rgba(127,127,0, 0.5)";
focus_enabled = true;
switch (fragType) {
case MARK_LINE:
case MARK_DONE_LINE:
case MARK_UNSORTABLE_LINE:
case MARK_SIMPLE_LINE:
case MARK_SIMPLE_DONE_LINE:
case MARK_DONE_UNARY_LINE:
drawLinePartial(frags[1], frags[2], frags[3], frags[4],
frags[5], frags[9]);
if (draw_id) {
drawLinePartialID(frags[0], frags[1], frags[2], frags[3], frags[4],
frags[5], frags[9]);
}
break;
case MARK_QUAD:
case MARK_DONE_QUAD:
case MARK_UNSORTABLE_QUAD:
case MARK_SIMPLE_QUAD:
case MARK_SIMPLE_DONE_QUAD:
case MARK_DONE_UNARY_QUAD:
drawQuadPartial(frags[1], frags[2], frags[3], frags[4],
frags[5], frags[6], frags[7], frags[11]);
if (draw_id) {
drawQuadPartialID(frags[0], frags[1], frags[2], frags[3], frags[4],
frags[5], frags[6], frags[7], frags[11]);
}
break;
case MARK_CUBIC:
case MARK_DONE_CUBIC:
case MARK_UNSORTABLE_CUBIC:
case MARK_SIMPLE_CUBIC:
case MARK_SIMPLE_DONE_CUBIC:
case MARK_DONE_UNARY_CUBIC:
drawCubicPartial(frags[1], frags[2], frags[3], frags[4],
frags[5], frags[6], frags[7], frags[8], frags[9], frags[13]);
if (draw_id) {
drawCubicPartialID(frags[0], frags[1], frags[2], frags[3], frags[4],
frags[5], frags[6], frags[7], frags[8], frags[9], frags[13]);
}
break;
case MARK_ANGLE_LAST:
// FIXME: ignored for now
break;
default:
console.log("unknown REC_TYPE_MARK frag type: " + fragType);
throw "stop execution";
}
break;
default:
continue;
}
}
switch (recType) {
case REC_TYPE_SORT:
if (!draw_sort || (step_limit > 0 && tIndex < lastSort)) {
break;
}
var angles = []; // use tangent lines to describe arcs
var windFrom = [];
var windTo = [];
var opp = [];
var minXY = Number.MAX_VALUE;
var partial;
focus_enabled = true;
var someUnsortable = false;
for (var recordIndex = 0; recordIndex < records.length; recordIndex += 2) {
var fragType = records[recordIndex];
var frags = records[recordIndex + 1];
var unsortable = (fragType == SORT_UNARY && frags[14]) ||
(fragType == SORT_BINARY && frags[16]);
someUnsortable |= unsortable;
switch (fragType) {
case SORT_UNARY:
case SORT_BINARY:
partial = curvePartialByID(test, frags[0], frags[6], frags[8]);
break;
default:
console.log("unknown REC_TYPE_SORT frag type: " + fragType);
throw "stop execution";
}
var dx = boundsWidth(partial);
var dy = boundsHeight(partial);
minXY = Math.min(minXY, dx * dx + dy * dy);
if (collect_bounds) {
continue;
}
angles.push(tangent(partial));
var from = frags[12];
var to = frags[12];
var sgn = frags[10];
if (sgn < 0) {
from -= frags[11];
} else if (sgn > 0) {
to -= frags[11];
}
windFrom.push(from + (unsortable ? "!" : ""));
windTo.push(to + (unsortable ? "!" : ""));
opp.push(fragType == SORT_BINARY);
if (draw_sort == 1) {
drawOrder(partial, frags[12]);
} else {
drawOrder(partial, (recordIndex / 2) + 1);
}
}
var radius = Math.sqrt(minXY) / 2 * scale;
radius = Math.min(50, radius);
var scaledRadius = radius / scale;
var centerX = partial[0];
var centerY = partial[1];
if (collect_bounds) {
if (focus_enabled) {
focusXmin = Math.min(focusXmin, centerX - scaledRadius);
focusYmin = Math.min(focusYmin, centerY - scaledRadius);
focusXmax = Math.max(focusXmax, centerX + scaledRadius);
focusYmax = Math.max(focusYmax, centerY + scaledRadius);
}
break;
}
break;
default:
break;
}
}
if (collect_bounds) {
return;
}
if (draw_log && logStart >= 0) {
ctx.font = "normal 10px Arial";
ctx.textAlign = "left";
ctx.beginPath();
var top = screenHeight - 20 - (logRange + 2) * 10;
ctx.rect(50, top, screenWidth - 100, (logRange + 2) * 10);
ctx.fillStyle = "white";
ctx.fill();
ctx.fillStyle = "rgba(0,0,0, 0.5)";
if (logStart > 0) {
ctx.fillText(lines[logStart - 1], 50, top + 8);
}
ctx.fillStyle = "black";
for (var idx = 0; idx < logRange; ++idx) {
ctx.fillText(lines[logStart + idx], 50, top + 18 + 10 * idx);
}
ctx.fillStyle = "rgba(0,0,0, 0.5)";
if (logStart + logRange < lines.length) {
ctx.fillText(lines[logStart + logRange], 50, top + 18 + 10 * logRange);
}
}
if (draw_legend) {
var pos = 0;
var drawSomething = draw_add | draw_active | draw_angle | draw_coincidence | draw_sort | draw_mark;
// drawBox(pos++, "yellow", "black", opLetter, true, '');
drawBox(pos++, "rgba(0,0,255, 0.3)", "black", draw_intersection > 1 ? sectCount : sectMax2, draw_intersection, intersectionKey);
drawBox(pos++, "rgba(0,0,255, 0.3)", "black", draw_add ? addCount : addMax, draw_add, addKey);
drawBox(pos++, "rgba(0,0,255, 0.3)", "black", draw_active ? activeCount : activeMax, draw_active, activeKey);
drawBox(pos++, "rgba(127,127,0, 0.3)", "black", draw_angle ? angleCount : angleMax, draw_angle, angleKey);
drawBox(pos++, "rgba(127,127,0, 0.3)", "black", draw_coincidence ? coinCount : coinMax, draw_coincidence, coincidenceKey);
drawBox(pos++, "rgba(127,127,0, 0.3)", "black", draw_op ? opCount : opMax, draw_op, opKey);
drawBox(pos++, "rgba(127,127,0, 0.3)", "black", draw_sort ? sortCount : sortMax, draw_sort, sortKey);
drawBox(pos++, "rgba(127,127,0, 0.3)", "black", draw_top ? topCount : topMax, draw_top, topKey);
drawBox(pos++, "rgba(127,0,127, 0.3)", "black", draw_mark ? markCount : markMax, draw_mark, markKey);
drawBox(pos++, "black", "white",
(new Array('P', 'P1', 'P2', 'P', 'p', 'p1', 'p2'))[draw_path], draw_path != 0, pathKey);
drawBox(pos++, "rgba(0,63,0, 0.7)", "white",
(new Array('Q', 'Q', 'C', 'QC', 'Qc', 'Cq'))[draw_computed],
draw_computed != 0, computedKey);
drawBox(pos++, "green", "black", step_limit, drawSomething, '');
drawBox(pos++, "green", "black", stepMax, drawSomething, '');
drawBox(pos++, "rgba(255,0,0, 0.6)", "black", lastIndex, drawSomething & draw_log, '');
drawBox(pos++, "rgba(255,0,0, 0.6)", "black", test.length - 1, drawSomething & draw_log, '');
if (curve_t) {
drawCurveTControl();
}
ctx.font = "normal 20px Arial";
ctx.fillStyle = "rgba(0,0,0, 0.3)";
ctx.textAlign = "right";
ctx.fillText(scale.toFixed(decimal_places) + 'x' , screenWidth - 10, screenHeight - 5);
}
if (draw_hints) {
ctx.font = "normal 10px Arial";
ctx.fillStyle = "rgba(0,0,0, 0.5)";
ctx.textAlign = "right";
var y = 4;
ctx.fillText("control lines : " + controlLinesKey, ctx.screenWidthwidth - 10, pos * 50 + y++ * 10);
ctx.fillText("curve t : " + curveTKey, screenWidth - 10, pos * 50 + y++ * 10);
ctx.fillText("deriviatives : " + deriviativesKey, screenWidth - 10, pos * 50 + y++ * 10);
ctx.fillText("intersect t : " + intersectTKey, screenWidth - 10, pos * 50 + y++ * 10);
ctx.fillText("log : " + logKey, screenWidth - 10, pos * 50 + y++ * 10);
ctx.fillText("log curve : " + logCurvesKey, screenWidth - 10, pos * 50 + y++ * 10);
ctx.fillText("mid point : " + midpointKey, screenWidth - 10, pos * 50 + y++ * 10);
ctx.fillText("points : " + ptsKey, screenWidth - 10, pos * 50 + y++ * 10);
ctx.fillText("sequence : " + sequenceKey, screenWidth - 10, pos * 50 + y++ * 10);
ctx.fillText("xy : " + xyKey, screenWidth - 10, pos * 50 + y++ * 10);
}
}
function drawBox(y, backC, foreC, str, enable, label) {
ctx.beginPath();
ctx.fillStyle = backC;
ctx.rect(screenWidth - 40, y * 50 + 10, 40, 30);
ctx.fill();
ctx.font = "normal 16px Arial";
ctx.fillStyle = foreC;
ctx.textAlign = "center";
ctx.fillText(str, screenWidth - 20, y * 50 + 32);
if (!enable) {
ctx.fillStyle = "rgba(255,255,255, 0.5)";
ctx.fill();
}
if (label != '') {
ctx.font = "normal 9px Arial";
ctx.fillStyle = "black";
ctx.fillText(label, screenWidth - 47, y * 50 + 40);
}
}
function drawCurveTControl() {
ctx.lineWidth = 2;
ctx.strokeStyle = "rgba(0,0,0, 0.3)";
ctx.beginPath();
ctx.rect(screenWidth - 80, 40, 28, screenHeight - 80);
ctx.stroke();
var ty = 40 + curveT * (screenHeight - 80);
ctx.beginPath();
ctx.moveTo(screenWidth - 80, ty);
ctx.lineTo(screenWidth - 85, ty - 5);
ctx.lineTo(screenWidth - 85, ty + 5);
ctx.lineTo(screenWidth - 80, ty);
ctx.fillStyle = "rgba(0,0,0, 0.6)";
ctx.fill();
var num = curveT.toFixed(decimal_places);
ctx.font = "normal 10px Arial";
ctx.textAlign = "left";
ctx.fillText(num, screenWidth - 78, ty);
}
function ptInTControl() {
var e = window.event;
var tgt = e.target || e.srcElement;
var left = tgt.offsetLeft;
var top = tgt.offsetTop;
var x = (e.clientX - left);
var y = (e.clientY - top);
if (x < screenWidth - 80 || x > screenWidth - 50) {
return false;
}
if (y < 40 || y > screenHeight - 80) {
return false;
}
curveT = (y - 40) / (screenHeight - 120);
if (curveT < 0 || curveT > 1) {
throw "stop execution";
}
return true;
}
function drawTop() {
if (tests[testIndex] == null) {
var str = testDivs[testIndex].textContent;
parse_all(str);
var title = testDivs[testIndex].id.toString();
testTitles[testIndex] = title;
}
init(tests[testIndex]);
redraw();
}
function redraw() {
if (focus_on_selection) {
collect_bounds = true;
draw(tests[testIndex], testLines[testIndex], testTitles[testIndex]);
collect_bounds = false;
if (focusXmin < focusXmax && focusYmin < focusYmax) {
setScale(focusXmin, focusXmax, focusYmin, focusYmax);
}
}
ctx.beginPath();
ctx.fillStyle = "white";
ctx.rect(0, 0, screenWidth, screenHeight);
ctx.fill();
draw(tests[testIndex], testLines[testIndex], testTitles[testIndex]);
}
function dumpCurvePartial(test, id, t0, t1) {
var curve = curveByID(test, id);
var name = ["line", "quad", "cubic"][curve.length / 2 - 2];
console.log("id=" + id + " " + name + "=" + curveToString(curve)
+ " t0=" + t0 + " t1=" + t1
+ " partial=" + curveToString(curvePartialByID(test, id, t0, t1)));
}
function dumpAngleTest(test, id, t0, t1) {
var curve = curveByID(test, id);
console.log(" { {" + curveToString(curve) + "}, "
+ curve.length / 2 + ", " + t0 + ", " + t1 + ", {} }, //");
}
function dumpLogToConsole() {
if (logStart < 0) {
return;
}
var test = tests[testIndex];
var recType = REC_TYPE_UNKNOWN;
var records;
for (var index = 0; index < test.length; index += 3) {
var lastLineNo = test[index + 1];
if (lastLineNo >= logStart && lastLineNo < logStart + logRange) {
recType = test[index];
records = test[index + 2];
break;
}
}
if (recType == REC_TYPE_UNKNOWN) {
return;
}
var lines = testLines[testIndex];
for (var idx = 0; idx < logRange; ++idx) {
var line = lines[logStart + idx];
console.log(line);
for (var recordIndex = 0; recordIndex < records.length; recordIndex += 2) {
var fragType = records[recordIndex];
var frags = records[recordIndex + 1];
if (recType == REC_TYPE_ANGLE && fragType == ANGLE_AFTER) {
dumpCurvePartial(test, frags[0], frags[4], frags[5]);
dumpCurvePartial(test, frags[6], frags[10], frags[11]);
dumpCurvePartial(test, frags[12], frags[16], frags[17]);
console.log("\nstatic IntersectData intersectDataSet[] = { //");
dumpAngleTest(test, frags[0], frags[4], frags[5]);
dumpAngleTest(test, frags[6], frags[10], frags[11]);
dumpAngleTest(test, frags[12], frags[16], frags[17]);
console.log("}; //");
}
}
}
}
var activeKey = 'a';
var pathKey = 'b';
var pathBackKey = 'B';
var centerKey = 'c';
var coincidenceKey = 'C';
var addKey = 'd';
var deriviativesKey = 'f';
var angleKey = 'g';
var angleBackKey = 'G';
var intersectionKey = 'i';
var intersectionBackKey = 'I';
var sequenceKey = 'j';
var midpointKey = 'k';
var logKey = 'l';
var logToConsoleKey = 'L';
var markKey = 'm';
var sortKey = 'o';
var opKey = 'p';
var opBackKey = 'P';
var computedKey = 'q';
var computedBackKey = 'Q';
var stepKey = 's';
var stepBackKey = 'S';
var intersectTKey = 't';
var topKey = 'T';
var curveTKey = 'u';
var controlLinesBackKey = 'V';
var controlLinesKey = 'v';
var ptsKey = 'x';
var xyKey = 'y';
var logCurvesKey = 'z';
var focusKey = '`';
var idKey = '.';
var retinaKey = '\\';
function doKeyPress(evt) {
var char = String.fromCharCode(evt.charCode);
var focusWasOn = false;
switch (char) {
case '0':
case '1':
case '2':
case '3':
case '4':
case '5':
case '6':
case '7':
case '8':
case '9':
decimal_places = char - '0';
redraw();
break;
case activeKey:
draw_active ^= true;
redraw();
break;
case addKey:
draw_add ^= true;
redraw();
break;
case angleKey:
draw_angle = (draw_angle + 1) % 4;
redraw();
break;
case angleBackKey:
draw_angle = (draw_angle + 2) % 3;
redraw();
break;
case centerKey:
setScale(xmin, xmax, ymin, ymax);
redraw();
break;
case coincidenceKey:
draw_coincidence ^= true;
redraw();
break;
case controlLinesBackKey:
control_lines = (control_lines + 3) % 4;
redraw();
break;
case controlLinesKey:
control_lines = (control_lines + 1) % 4;
redraw();
break;
case computedBackKey:
draw_computed = (draw_computed + 5) % 6;
redraw();
break;
case computedKey:
draw_computed = (draw_computed + 1) % 6;
redraw();
break;
case curveTKey:
curve_t ^= true;
if (curve_t) {
draw_legend = true;
}
redraw();
break;
case deriviativesKey:
draw_deriviatives = (draw_deriviatives + 1) % 3;
redraw();
break;
case focusKey:
focus_on_selection ^= true;
setScale(xmin, xmax, ymin, ymax);
redraw();
break;
case idKey:
draw_id ^= true;
redraw();
break;
case intersectionBackKey:
draw_intersection = (draw_intersection + 3) % 4;
redraw();
break;
case intersectionKey:
draw_intersection = (draw_intersection + 1) % 4;
redraw();
break;
case intersectTKey:
draw_intersectT ^= true;
redraw();
break;
case logCurvesKey:
logCurves(tests[testIndex]);
break;
case logKey:
draw_log ^= true;
redraw();
break;
case logToConsoleKey:
if (draw_log) {
dumpLogToConsole();
}
break;
case markKey:
draw_mark ^= true;
redraw();
break;
case midpointKey:
draw_midpoint ^= true;
redraw();
break;
case opKey:
draw_op = (draw_op + 1) % 3;
redraw();
break;
case opBackKey:
draw_op = (draw_op + 2) % 3;
redraw();
break;
case pathKey:
draw_path = (draw_path + 1) % (4 + (hasAlignedPath ? 3 : 0));
redraw();
break;
case pathBackKey:
draw_path = (draw_path + 3 + (hasAlignedPath ? 3 : 0)) % (4 + (hasAlignedPath ? 3 : 0));
redraw();
break;
case ptsKey:
pt_labels = (pt_labels + 1) % 3;
redraw();
break;
case retinaKey:
retina_scale ^= true;
drawTop();
break;
case sequenceKey:
draw_sequence ^= true;
redraw();
break;
case sortKey:
draw_sort = (draw_sort + 1) % 3;
drawTop();
break;
case stepKey:
step_limit++;
if (step_limit > stepMax) {
step_limit = stepMax;
}
redraw();
break;
case stepBackKey:
step_limit--;
if (step_limit < 0) {
step_limit = 0;
}
redraw();
break;
case topKey:
draw_top ^= true;
redraw();
break;
case xyKey:
debug_xy = (debug_xy + 1) % 3;
redraw();
break;
case '-':
focusWasOn = focus_on_selection;
if (focusWasOn) {
focus_on_selection = false;
scale /= 1.2;
} else {
scale /= 2;
calcLeftTop();
}
redraw();
focus_on_selection = focusWasOn;
break;
case '=':
case '+':
focusWasOn = focus_on_selection;
if (focusWasOn) {
focus_on_selection = false;
scale *= 1.2;
} else {
scale *= 2;
calcLeftTop();
}
redraw();
focus_on_selection = focusWasOn;
break;
case '?':
draw_hints ^= true;
if (draw_hints && !draw_legend) {
draw_legend = true;
}
redraw();
break;
case '/':
draw_legend ^= true;
redraw();
break;
}
}
function doKeyDown(evt) {
var char = evt.keyCode;
var preventDefault = false;
switch (char) {
case 37: // left arrow
if (evt.shiftKey) {
testIndex -= 9;
}
if (--testIndex < 0)
testIndex = tests.length - 1;
drawTop();
preventDefault = true;
break;
case 39: // right arrow
if (evt.shiftKey) {
testIndex += 9;
}
if (++testIndex >= tests.length)
testIndex = 0;
drawTop();
preventDefault = true;
break;
}
if (preventDefault) {
evt.preventDefault();
return false;
}
return true;
}
(function() {
var hidden = "hidden";
// Standards:
if (hidden in document)
document.addEventListener("visibilitychange", onchange);
else if ((hidden = "mozHidden") in document)
document.addEventListener("mozvisibilitychange", onchange);
else if ((hidden = "webkitHidden") in document)
document.addEventListener("webkitvisibilitychange", onchange);
else if ((hidden = "msHidden") in document)
document.addEventListener("msvisibilitychange", onchange);
// IE 9 and lower:
else if ('onfocusin' in document)
document.onfocusin = document.onfocusout = onchange;
// All others:
else
window.onpageshow = window.onpagehide
= window.onfocus = window.onblur = onchange;
function onchange (evt) {
var v = 'visible', h = 'hidden',
evtMap = {
focus:v, focusin:v, pageshow:v, blur:h, focusout:h, pagehide:h
};
evt = evt || window.event;
if (evt.type in evtMap)
document.body.className = evtMap[evt.type];
else
document.body.className = this[hidden] ? "hidden" : "visible";
}
})();
function calcXY() {
var e = window.event;
var tgt = e.target || e.srcElement;
var left = tgt.offsetLeft;
var top = tgt.offsetTop;
mouseX = (e.clientX - left) / scale + srcLeft;
mouseY = (e.clientY - top) / scale + srcTop;
}
function calcLeftTop() {
srcLeft = mouseX - screenWidth / 2 / scale;
srcTop = mouseY - screenHeight / 2 / scale;
}
var disableClick = false;
function handleMouseClick() {
if (disableClick) {
return;
}
if (!curve_t || !ptInTControl()) {
calcXY();
calcLeftTop();
}
redraw();
// if (!curve_t || !ptInTControl()) {
// mouseX = screenWidth / 2 / scale + srcLeft;
// mouseY = screenHeight / 2 / scale + srcTop;
// }
}
function handleMouseOver() {
calcXY();
if (debug_xy != 2) {
return;
}
var num = mouseX.toFixed(decimal_places) + ", " + mouseY.toFixed(decimal_places);
ctx.beginPath();
ctx.rect(300,100,num.length * 6,10);
ctx.fillStyle="white";
ctx.fill();
ctx.font = "normal 10px Arial";
ctx.fillStyle="black";
ctx.textAlign = "left";
ctx.fillText(num, 300, 108);
}
function start() {
for (var i = 0; i < testDivs.length; ++i) {
tests[i] = null;
}
testIndex = 0;
drawTop();
window.addEventListener('keypress', doKeyPress, true);
window.addEventListener('keydown', doKeyDown, true);
window.onresize = function() {
drawTop();
}
/*
window.onpagehide = function() {
disableClick = true;
}
*/
window.onpageshow = function () {
disableClick = false;
}
}
</script>
</head>
<body onLoad="start();">
<canvas id="canvas" width="750" height="500"
onmousemove="handleMouseOver()"
onclick="handleMouseClick()"
></canvas >
</body>
</html>