summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVincent Sanders <vince@kyllikki.org>2016-08-23 20:13:22 (GMT)
committer Vincent Sanders <vince@kyllikki.org>2016-08-23 20:13:22 (GMT)
commit047d5b9fc7fe4e1bb04ea1e95c754c6981943c71 (patch)
tree1815a87c78acc585cfb7a100c9ecb7bf79da83ac
parent5702c70efacc57fd7d5333e949b853cf5a03b677 (diff)
downloadlibsvgtiny-047d5b9fc7fe4e1bb04ea1e95c754c6981943c71.tar.gz
libsvgtiny-047d5b9fc7fe4e1bb04ea1e95c754c6981943c71.tar.bz2
add file output to test decoder
-rw-r--r--test/data/SpglGrfC.svg12
-rw-r--r--test/decode_svg.c324
-rwxr-xr-xtest/runtest.sh6
3 files changed, 192 insertions, 150 deletions
diff --git a/test/data/SpglGrfC.svg b/test/data/SpglGrfC.svg
new file mode 100644
index 0000000..7b37510
--- a/dev/null
+++ b/test/data/SpglGrfC.svg
@@ -0,0 +1,12 @@
+<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1300 800" version="1.1"><clipPath id="box"><rect x="0" y="0" width="650" height="400" style="fill:none;stroke:none;" /></clipPath><g clip-path="url(#box)"><rect x="0.00" y="0.00" width="650.00" height="400.00" style="fill:#FFFFFF;stroke:none;" />
+<path d="M0.00 400.00 L650.00 400.00 M0.00 360.00 L650.00 360.00 M0.00 320.00 L650.00 320.00 M0.00 280.00 L650.00 280.00 M0.00 240.00 L650.00 240.00 M0.00 200.00 L650.00 200.00 M0.00 160.00 L650.00 160.00 M0.00 120.00 L650.00 120.00 M0.00 80.00 L650.00 80.00 M0.00 40.00 L650.00 40.00 M0.00 0.00 L650.00 0.00 M0.00 0.00 L0.00 400.00 M41.00 0.00 L41.00 400.00 M82.00 0.00 L82.00 400.00 M124.00 0.00 L124.00 400.00 M165.00 0.00 L165.00 400.00 M206.00 0.00 L206.00 400.00 M248.00 0.00 L248.00 400.00 M289.00 0.00 L289.00 400.00 M331.00 0.00 L331.00 400.00 M372.00 0.00 L372.00 400.00 M413.00 0.00 L413.00 400.00 M455.00 0.00 L455.00 400.00 M496.00 0.00 L496.00 400.00 M537.00 0.00 L537.00 400.00 M579.00 0.00 L579.00 400.00 M620.00 0.00 L620.00 400.00 " style="fill:none;stroke:#D0D0D0;stroke-width:1;" />
+<path d="M0.00 0.00 L0.00 400.00 " style="fill:none;stroke:#000000;stroke-width:1;" />
+<path d="M-6.50 400.00 L6.50 400.00 M-6.50 360.00 L6.50 360.00 M-6.50 320.00 L6.50 320.00 M-6.50 280.00 L6.50 280.00 M-6.50 240.00 L6.50 240.00 M-6.50 200.00 L6.50 200.00 M-6.50 160.00 L6.50 160.00 M-6.50 120.00 L6.50 120.00 M-6.50 80.00 L6.50 80.00 M-6.50 40.00 L6.50 40.00 M-6.50 0.00 L6.50 0.00 " style="fill:none;stroke:#000000;stroke-width:1;" />
+<path d="M0.00 400.00 L650.00 400.00 " style="fill:none;stroke:#000000;stroke-width:1;" />
+<path d="M0.00 393.50 L0.00 406.50 M41.38 393.50 L41.38 406.50 M82.76 393.50 L82.76 406.50 M124.14 393.50 L124.14 406.50 M165.52 393.50 L165.52 406.50 M206.90 393.50 L206.90 406.50 M248.28 393.50 L248.28 406.50 M289.66 393.50 L289.66 406.50 M331.04 393.50 L331.04 406.50 M372.42 393.50 L372.42 406.50 M413.80 393.50 L413.80 406.50 M455.18 393.50 L455.18 406.50 M496.56 393.50 L496.56 406.50 M537.94 393.50 L537.94 406.50 M579.32 393.50 L579.32 406.50 M620.70 393.50 L620.70 406.50 " style="fill:none;stroke:#000000;stroke-width:1;" /><text x="8.125" y="362.5" text-anchor="start" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">0.2</text><text x="8.125" y="322.5" text-anchor="start" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">0.4</text><text x="8.125" y="282.5" text-anchor="start" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">0.6</text><text x="8.125" y="242.5" text-anchor="start" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">0.8</text><text x="8.125" y="202.5" text-anchor="start" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">1</text><text x="8.125" y="162.5" text-anchor="start" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">1.2</text><text x="8.125" y="122.50000000000001" text-anchor="start" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">1.4</text><text x="8.125" y="82.50000000000003" text-anchor="start" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">1.6</text><text x="8.125" y="42.500000000000036" text-anchor="start" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">1.8</text><text x="41.380188439011974" y="389.625" text-anchor="middle" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">0.1</text><text x="82.76037687802395" y="389.625" text-anchor="middle" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">0.2</text><text x="124.14056531703592" y="389.625" text-anchor="middle" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">0.3</text><text x="165.5207537560479" y="389.625" text-anchor="middle" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">0.4</text><text x="206.90094219505986" y="389.625" text-anchor="middle" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">0.5</text><text x="248.2811306340718" y="389.625" text-anchor="middle" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">0.6</text><text x="289.66131907308375" y="389.625" text-anchor="middle" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">0.7</text><text x="331.04150751209573" y="389.625" text-anchor="middle" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">0.8</text><text x="372.42169595110767" y="389.625" text-anchor="middle" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">0.9</text><text x="413.80188439011965" y="389.625" text-anchor="middle" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">1</text><text x="455.18207282913164" y="389.625" text-anchor="middle" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">1.1</text><text x="496.5622612681436" y="389.625" text-anchor="middle" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">1.2</text><text x="537.9424497071557" y="389.625" text-anchor="middle" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">1.3</text><text x="579.3226381461676" y="389.625" text-anchor="middle" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">1.4</text><text x="620.7028265851797" y="389.625" text-anchor="middle" style="font:10px Droid Sans,Trebuchet MS,Arial,Helvetica,sans-serif;stroke:none;fill:#000000">1.5</text>
+<path d="M-10.00 200.00 L-0.25 400.00 L0.75 400.00 L2.75 399.99 L4.75 399.97 L6.75 399.95 L8.75 399.91 L10.75 399.87 L12.75 399.81 L14.75 399.75 L16.75 399.67 L18.75 399.59 L20.75 399.50 L22.75 399.40 L24.75 399.29 L26.75 399.17 L28.75 399.04 L30.75 398.90 L32.75 398.75 L34.75 398.59 L36.75 398.43 L38.75 398.25 L40.75 398.07 L42.75 397.87 L44.75 397.67 L46.75 397.46 L48.75 397.24 L50.75 397.01 L52.75 396.77 L54.75 396.52 L56.75 396.26 L58.75 396.00 L60.75 395.72 L62.75 395.44 L64.75 395.14 L66.75 394.84 L68.75 394.53 L70.75 394.21 L72.75 393.88 L74.75 393.54 L76.75 393.20 L78.75 392.84 L80.75 392.48 L82.75 392.11 L84.75 391.73 L86.75 391.34 L88.75 390.94 L90.75 390.53 L92.75 390.12 L94.75 389.70 L96.75 389.26 L98.75 388.82 L100.75 388.38 L102.75 387.92 L104.75 387.46 L106.75 386.98 L108.75 386.50 L110.75 386.01 L112.75 385.52 L114.75 385.01 L116.75 384.50 L118.75 383.98 L120.75 383.45 L122.75 382.91 L124.75 382.37 L126.75 381.81 L128.75 381.26 L130.75 380.69 L132.75 380.11 L134.75 379.53 L136.75 378.94 L138.75 378.34 L140.75 377.74 L142.75 377.13 L144.75 376.51 L146.75 375.88 L148.75 375.25 L150.75 374.61 L152.75 373.96 L154.75 373.31 L156.75 372.65 L158.75 371.98 L160.75 371.31 L162.75 370.62 L164.75 369.94 L166.75 369.24 L168.75 368.54 L170.75 367.84 L172.75 367.12 L174.75 366.40 L176.75 365.68 L178.75 364.94 L180.75 364.21 L182.75 363.46 L184.75 362.71 L186.75 361.96 L188.75 361.19 L190.75 360.43 L192.75 359.65 L194.75 358.88 L196.75 358.09 L198.75 357.30 L200.75 356.51 L202.75 355.71 L204.75 354.90 L206.75 354.09 L208.75 353.28 L210.75 352.46 L212.75 351.63 L214.75 350.80 L216.75 349.96 L218.75 349.13 L220.75 348.28 L222.75 347.43 L224.75 346.58 L226.75 345.72 L228.75 344.86 L230.75 343.99 L232.75 343.12 L234.75 342.25 L236.75 341.37 L238.75 340.49 L240.75 339.60 L242.75 338.71 L244.75 337.82 L246.75 336.92 L248.75 336.02 L250.75 335.12 L252.75 334.21 L254.75 333.30 L256.75 332.39 L258.75 331.48 L260.75 330.56 L262.75 329.63 L264.75 328.71 L266.75 327.78 L268.75 326.85 L270.75 325.92 L272.75 324.99 L274.75 324.05 L276.75 323.11 L278.75 322.17 L280.75 321.22 L282.75 320.28 L284.75 319.33 L286.75 318.38 L288.75 317.43 L290.75 316.48 L292.75 315.52 L294.75 314.57 L296.75 313.61 L298.75 312.65 L300.75 311.69 L302.75 310.73 L304.75 309.77 L306.75 308.81 L308.75 307.85 L310.75 306.88 L312.75 305.92 L314.75 304.95 L316.75 303.99 L318.75 303.02 L320.75 302.05 L322.75 301.09 L324.75 300.12 L326.75 299.15 L328.75 298.19 L330.75 297.22 L332.75 296.25 L334.75 295.29 L336.75 294.32 L338.75 293.36 L340.75 292.39 L342.75 291.43 L344.75 290.47 L346.75 289.51 L348.75 288.55 L350.75 287.59 L352.75 286.63 L354.75 285.67 L356.75 284.71 L358.75 283.76 L360.75 282.81 L362.75 281.86 L364.75 280.91 L366.75 279.96 L368.75 279.01 L370.75 278.07 L372.75 277.13 L374.75 276.19 L376.75 275.25 L378.75 274.31 L380.75 273.38 L382.75 272.45 L384.75 271.52 L386.75 270.60 L388.75 269.67 L390.75 268.75 L392.75 267.84 L394.75 266.92 L396.75 266.01 L398.75 265.10 L400.75 264.20 L402.75 263.30 L404.75 262.40 L406.75 261.51 L408.75 260.62 L410.75 259.73 L412.75 258.85 L414.75 257.97 L416.75 257.09 L418.75 256.22 L420.75 255.36 L422.75 254.49 L424.75 253.63 L426.75 252.78 L428.75 251.93 L430.75 251.08 L432.75 250.24 L434.75 249.41 L436.75 248.58 L438.75 247.75 L440.75 246.93 L442.75 246.11 L444.75 245.30 L446.75 244.49 L448.75 243.69 L450.75 242.90 L452.75 242.10 L454.75 241.32 L456.75 240.54 L458.75 239.76 L460.75 239.00 L462.75 238.23 L464.75 237.48 L466.75 236.72 L468.75 235.98 L470.75 235.24 L472.75 234.51 L474.75 233.78 L476.75 233.06 L478.75 232.34 L480.75 231.63 L482.75 230.93 L484.75 230.23 L486.75 229.55 L488.75 228.86 L490.75 228.19 L492.75 227.52 L494.75 226.86 L496.75 226.20 L498.75 225.55 L500.75 224.91 L502.75 224.27 L504.75 223.65 L506.75 223.03 L508.75 222.41 L510.75 221.81 L512.75 221.21 L514.75 220.62 L516.75 220.03 L518.75 219.45 L520.75 218.89 L522.75 218.32 L524.75 217.77 L526.75 217.22 L528.75 216.69 L530.75 216.15 L532.75 215.63 L534.75 215.12 L536.75 214.61 L538.75 214.11 L540.75 213.62 L542.75 213.14 L544.75 212.66 L546.75 212.19 L548.75 211.74 L550.75 211.29 L552.75 210.84 L554.75 210.41 L556.75 209.99 L558.75 209.57 L560.75 209.16 L562.75 208.76 L564.75 208.37 L566.75 207.99 L568.75 207.61 L570.75 207.25 L572.75 206.89 L574.75 206.54 L576.75 206.20 L578.75 205.87 L580.75 205.55 L582.75 205.24 L584.75 204.93 L586.75 204.64 L588.75 204.35 L590.75 204.07 L592.75 203.80 L594.75 203.54 L596.75 203.29 L598.75 203.05 L600.75 202.82 L602.75 202.60 L604.75 202.38 L606.75 202.18 L608.75 201.98 L610.75 201.79 L612.75 201.62 L614.75 201.45 L616.75 201.29 L618.75 201.14 L620.75 201.00 L622.75 200.87 L624.75 200.74 L626.75 200.63 L628.75 200.53 L630.75 200.43 L632.75 200.35 L634.75 200.27 L636.75 200.20 L638.75 200.15 L640.75 200.10 L642.75 200.06 L644.75 200.03 L646.75 200.01 L648.75 200.00 " style="fill:none;stroke:blue;stroke-width:1;" />
+<path d="M-0.00 400.00 L-0.00 400.00 L2.00 399.16 L4.00 398.31 L6.00 397.45 L8.00 396.59 L10.00 395.72 L12.00 394.84 L14.00 393.95 L16.00 393.06 L18.00 392.15 L20.00 391.24 L22.00 390.33 L24.00 389.40 L26.00 388.47 L28.00 387.53 L30.00 386.58 L32.00 385.63 L34.00 384.67 L36.00 383.70 L38.00 382.72 L40.00 381.74 L42.00 380.75 L44.00 379.75 L46.00 378.75 L47.99 377.74 L49.97 376.73 L51.93 375.73 L53.89 374.72 L55.82 373.71 L57.75 372.71 L59.66 371.70 L61.57 370.70 L63.46 369.69 L65.34 368.68 L67.21 367.68 L69.07 366.67 L70.91 365.67 L72.75 364.66 L74.58 363.66 L76.40 362.65 L78.21 361.65 L80.01 360.64 L81.80 359.64 L83.58 358.63 L85.35 357.63 L87.12 356.62 L88.88 355.62 L90.63 354.61 L92.37 353.61 L94.10 352.60 L95.83 351.60 L97.55 350.60 L99.26 349.59 L100.96 348.59 L102.66 347.58 L104.35 346.58 L106.03 345.58 L107.71 344.57 L109.38 343.57 L111.05 342.57 L112.71 341.56 L114.36 340.56 L116.01 339.55 L117.65 338.55 L119.29 337.55 L120.92 336.54 L122.54 335.54 L124.17 334.54 L125.78 333.54 L127.39 332.53 L129.00 331.53 L130.60 330.53 L132.19 329.52 L133.79 328.52 L135.37 327.52 L136.96 326.52 L138.53 325.51 L140.11 324.51 L141.68 323.51 L143.25 322.50 L144.81 321.50 L146.37 320.50 L147.92 319.50 L149.47 318.50 L151.02 317.49 L152.56 316.49 L154.10 315.49 L155.64 314.49 L157.17 313.48 L158.71 312.48 L160.23 311.48 L161.76 310.48 L163.28 309.48 L164.80 308.47 L166.31 307.47 L167.83 306.47 L169.34 305.47 L170.84 304.47 L172.35 303.47 L173.85 302.46 L175.35 301.46 L176.85 300.46 L178.35 299.46 L179.84 298.46 L181.33 297.46 L182.82 296.46 L184.31 295.45 L185.79 294.45 L187.27 293.45 L188.75 292.45 L190.23 291.45 L191.71 290.45 L193.19 289.45 L194.66 288.45 L196.13 287.44 L197.60 286.44 L199.07 285.44 L200.54 284.44 L202.01 283.44 L203.47 282.44 L204.94 281.44 L206.40 280.44 L207.86 279.44 L209.32 278.44 L210.78 277.44 L212.24 276.44 L213.70 275.43 L215.15 274.43 L216.61 273.43 L218.07 272.43 L219.52 271.43 L220.97 270.43 L222.43 269.43 L223.88 268.43 L225.33 267.43 L226.78 266.43 L228.23 265.43 L229.68 264.43 L231.13 263.43 L232.58 262.43 L234.03 261.43 L235.48 260.43 L236.93 259.43 L238.38 258.43 L239.83 257.43 L241.28 256.43 L242.73 255.43 L244.18 254.43 L245.63 253.43 L247.08 252.43 L248.53 251.43 L249.98 250.43 L251.43 249.43 L252.89 248.43 L254.34 247.43 L255.79 246.43 L257.24 245.43 L258.70 244.43 L260.15 243.43 L261.61 242.43 L263.07 241.44 L264.52 240.44 L265.98 239.44 L267.44 238.44 L268.90 237.44 L270.36 236.44 L271.82 235.44 L273.29 234.44 L274.75 233.44 L276.22 232.44 L277.69 231.44 L279.16 230.44 L280.63 229.45 L282.10 228.45 L283.57 227.45 L285.05 226.45 L286.53 225.45 L288.00 224.45 L289.49 223.45 L290.97 222.45 L292.45 221.46 L293.94 220.46 L295.43 219.46 L296.92 218.46 L298.42 217.46 L299.91 216.46 L301.41 215.46 L302.91 214.47 L304.41 213.47 L305.92 212.47 L307.43 211.47 L308.94 210.47 L310.46 209.48 L311.97 208.48 L313.49 207.48 L315.02 206.48 L316.55 205.48 L318.08 204.49 L319.61 203.49 L321.15 202.49 L322.69 201.49 L324.23 200.50 L325.78 199.50 L327.33 198.50 L328.89 197.50 L330.45 196.51 L332.01 195.51 L333.58 194.51 L335.15 193.51 L336.73 192.52 L338.31 191.52 L339.89 190.52 L341.48 189.53 L343.08 188.53 L344.68 187.53 L346.29 186.54 L347.90 185.54 L349.51 184.54 L351.14 183.55 L352.76 182.55 L354.40 181.55 L356.04 180.56 L357.68 179.56 L359.33 178.56 L360.99 177.57 L362.66 176.57 L364.33 175.58 L366.01 174.58 L367.69 173.58 L369.38 172.59 L371.08 171.59 L372.79 170.60 L374.51 169.60 L376.23 168.61 L377.96 167.61 L379.70 166.62 L381.45 165.62 L383.20 164.63 L384.97 163.63 L386.75 162.64 L388.53 161.64 L390.33 160.65 L392.13 159.65 L393.95 158.66 L395.78 157.67 L397.61 156.67 L399.46 155.68 L401.32 154.69 L403.20 153.69 L405.08 152.70 L406.98 151.71 L408.89 150.71 L410.81 149.72 L412.75 148.73 L414.71 147.74 L416.67 146.74 L418.66 145.75 L420.66 144.76 L422.66 143.78 L424.66 142.80 L426.66 141.83 L428.66 140.87 L430.66 139.92 L432.66 138.98 L434.66 138.05 L436.66 137.13 L438.66 136.21 L440.66 135.30 L442.66 134.41 L444.66 133.52 L446.66 132.64 L448.66 131.77 L450.66 130.91 L452.66 130.06 L454.66 129.22 L456.66 128.39 L458.66 127.56 L460.66 126.75 L462.66 125.95 L464.66 125.16 L466.66 124.37 L468.66 123.60 L470.66 122.83 L472.66 122.08 L474.66 121.34 L476.66 120.60 L478.66 119.88 L480.66 119.17 L482.66 118.46 L484.66 117.77 L486.66 117.09 L488.66 116.42 L490.66 115.76 L492.66 115.11 L494.66 114.47 L496.66 113.84 L498.66 113.22 L500.66 112.61 L502.66 112.01 L504.66 111.43 L506.66 110.85 L508.66 110.29 L510.66 109.73 L512.66 109.19 L514.66 108.66 L516.66 108.14 L518.66 107.63 L520.66 107.13 L522.66 106.65 L524.66 106.17 L526.66 105.71 L528.66 105.25 L530.66 104.81 L532.66 104.38 L534.66 103.97 L536.66 103.56 L538.66 103.16 L540.66 102.78 L542.66 102.41 L544.66 102.05 L546.66 101.70 L548.66 101.36 L550.66 101.04 L552.66 100.72 L554.66 100.42 L556.66 100.13 L558.66 99.85 L560.66 99.59 L562.66 99.33 L564.66 99.09 L566.66 98.86 L568.66 98.64 L570.66 98.44 L572.66 98.24 L574.66 98.06 L576.66 97.89 L578.66 97.73 L580.66 97.58 L582.66 97.45 L584.66 97.33 L586.66 97.22 L588.66 97.12 L590.66 97.03 L592.66 96.96 L594.66 96.90 L596.66 96.85 L598.66 96.81 L600.66 96.79 L602.66 96.77 L604.66 96.77 L606.66 96.78 L608.66 96.81 L610.66 96.84 L612.66 96.89 L614.66 96.95 L616.66 97.02 L618.66 97.10 L620.66 97.20 L622.66 97.31 L624.66 97.43 L626.66 97.56 L628.66 97.71 L630.66 97.86 L632.66 98.03 L634.66 98.21 L636.66 98.41 L638.66 98.61 L640.66 98.83 L642.66 99.06 L644.66 99.30 L646.66 99.55 L648.66 99.82 " style="fill:none;stroke:purple;stroke-width:1;" />
+<path d="M-0.00 400.00 L-0.00 400.00 L2.00 399.16 L4.00 398.30 L6.00 397.44 L8.00 396.56 L10.00 395.68 L12.00 394.78 L14.00 393.87 L16.00 392.96 L18.00 392.03 L20.00 391.09 L22.00 390.14 L24.00 389.18 L26.00 388.21 L28.00 387.23 L30.00 386.23 L32.00 385.23 L34.00 384.22 L35.97 383.21 L37.93 382.20 L39.86 381.19 L41.78 380.18 L43.68 379.17 L45.56 378.16 L47.43 377.15 L49.28 376.15 L51.11 375.14 L52.93 374.13 L54.73 373.12 L56.52 372.11 L58.29 371.11 L60.05 370.10 L61.80 369.09 L63.54 368.08 L65.26 367.08 L66.97 366.07 L68.67 365.06 L70.36 364.06 L72.03 363.05 L73.70 362.04 L75.35 361.04 L76.99 360.03 L78.63 359.02 L80.25 358.02 L81.86 357.01 L83.47 356.01 L85.06 355.00 L86.65 353.99 L88.22 352.99 L89.79 351.98 L91.35 350.98 L92.90 349.97 L94.44 348.97 L95.98 347.96 L97.50 346.96 L99.02 345.95 L100.53 344.95 L102.04 343.94 L103.54 342.94 L105.03 341.93 L106.51 340.93 L107.99 339.92 L109.46 338.92 L110.92 337.92 L112.38 336.91 L113.83 335.91 L115.28 334.90 L116.71 333.90 L118.15 332.89 L119.57 331.89 L121.00 330.89 L122.41 329.88 L123.82 328.88 L125.23 327.88 L126.63 326.87 L128.02 325.87 L129.42 324.86 L130.80 323.86 L132.18 322.86 L133.56 321.85 L134.93 320.85 L136.29 319.85 L137.66 318.84 L139.01 317.84 L140.37 316.84 L141.71 315.83 L143.06 314.83 L144.40 313.83 L145.74 312.83 L147.07 311.82 L148.40 310.82 L149.72 309.82 L151.04 308.81 L152.36 307.81 L153.67 306.81 L154.98 305.81 L156.29 304.80 L157.59 303.80 L158.89 302.80 L160.19 301.80 L161.48 300.79 L162.77 299.79 L164.06 298.79 L165.34 297.79 L166.62 296.78 L167.90 295.78 L169.17 294.78 L170.44 293.78 L171.71 292.77 L172.98 291.77 L174.24 290.77 L175.50 289.77 L176.76 288.77 L178.01 287.76 L179.26 286.76 L180.51 285.76 L181.76 284.76 L183.01 283.76 L184.25 282.75 L185.49 281.75 L186.73 280.75 L187.96 279.75 L189.20 278.75 L190.43 277.74 L191.66 276.74 L192.88 275.74 L194.11 274.74 L195.33 273.74 L196.55 272.74 L197.77 271.74 L198.99 270.73 L200.21 269.73 L201.42 268.73 L202.63 267.73 L203.84 266.73 L205.05 265.73 L206.26 264.73 L207.46 263.72 L208.66 262.72 L209.86 261.72 L211.07 260.72 L212.26 259.72 L213.46 258.72 L214.66 257.72 L215.85 256.71 L217.04 255.71 L218.24 254.71 L219.43 253.71 L220.61 252.71 L221.80 251.71 L222.99 250.71 L224.17 249.71 L225.36 248.71 L226.54 247.71 L227.72 246.70 L228.90 245.70 L230.08 244.70 L231.26 243.70 L232.44 242.70 L233.62 241.70 L234.79 240.70 L235.97 239.70 L237.14 238.70 L238.31 237.70 L239.48 236.70 L240.66 235.70 L241.83 234.70 L243.00 233.69 L244.17 232.69 L245.33 231.69 L246.50 230.69 L247.67 229.69 L248.84 228.69 L250.00 227.69 L251.17 226.69 L252.33 225.69 L253.50 224.69 L254.66 223.69 L255.83 222.69 L256.99 221.69 L258.15 220.69 L259.31 219.69 L260.48 218.69 L261.64 217.69 L262.80 216.69 L263.96 215.69 L265.12 214.69 L266.28 213.69 L267.44 212.69 L268.60 211.69 L269.76 210.69 L270.92 209.69 L272.08 208.69 L273.24 207.69 L274.40 206.69 L275.56 205.69 L276.72 204.69 L277.88 203.69 L279.04 202.69 L280.20 201.69 L281.36 200.69 L282.52 199.69 L283.68 198.69 L284.85 197.69 L286.01 196.69 L287.17 195.69 L288.33 194.69 L289.49 193.69 L290.65 192.69 L291.82 191.69 L292.98 190.69 L294.14 189.69 L295.31 188.69 L296.47 187.69 L297.64 186.69 L298.80 185.69 L299.97 184.69 L301.13 183.69 L302.30 182.69 L303.47 181.69 L304.64 180.69 L305.81 179.70 L306.98 178.70 L308.15 177.70 L309.32 176.70 L310.49 175.70 L311.66 174.70 L312.84 173.70 L314.01 172.70 L315.19 171.70 L316.36 170.70 L317.54 169.70 L318.72 168.70 L319.90 167.70 L321.08 166.71 L322.26 165.71 L323.45 164.71 L324.63 163.71 L325.82 162.71 L327.00 161.71 L328.19 160.71 L329.38 159.71 L330.57 158.71 L331.76 157.72 L332.95 156.72 L334.15 155.72 L335.35 154.72 L336.54 153.72 L337.74 152.72 L338.94 151.72 L340.15 150.72 L341.35 149.73 L342.55 148.73 L343.76 147.73 L344.97 146.73 L346.18 145.73 L347.39 144.73 L348.61 143.73 L349.83 142.74 L351.04 141.74 L352.27 140.74 L353.49 139.74 L354.71 138.74 L355.94 137.74 L357.17 136.75 L358.40 135.75 L359.63 134.75 L360.87 133.75 L362.11 132.75 L363.35 131.76 L364.59 130.76 L365.83 129.76 L367.08 128.76 L368.33 127.76 L369.58 126.77 L370.84 125.77 L372.10 124.77 L373.36 123.77 L374.62 122.78 L375.89 121.78 L377.16 120.78 L378.43 119.78 L379.71 118.78 L380.99 117.79 L382.27 116.79 L383.55 115.79 L384.84 114.79 L386.14 113.80 L387.43 112.80 L388.73 111.80 L390.03 110.81 L391.34 109.81 L392.65 108.81 L393.96 107.81 L395.28 106.82 L396.60 105.82 L397.93 104.82 L399.25 103.83 L400.59 102.83 L401.93 101.83 L403.27 100.84 L404.61 99.84 L405.96 98.84 L407.32 97.85 L408.68 96.85 L410.04 95.85 L411.41 94.86 L412.79 93.86 L414.17 92.86 L415.55 91.87 L416.94 90.87 L418.34 89.88 L419.74 88.88 L421.15 87.88 L422.56 86.89 L423.98 85.89 L425.40 84.90 L426.83 83.90 L428.26 82.90 L429.71 81.91 L431.16 80.91 L432.61 79.92 L434.07 78.92 L435.54 77.93 L437.02 76.93 L438.50 75.94 L439.99 74.94 L441.49 73.95 L443.00 72.95 L444.51 71.96 L446.03 70.96 L447.56 69.97 L449.10 68.97 L450.65 67.98 L452.20 66.99 L453.77 65.99 L455.34 65.00 L456.93 64.00 L458.52 63.01 L460.12 62.02 L461.74 61.02 L463.36 60.03 L465.00 59.04 L466.65 58.04 L468.30 57.05 L469.98 56.06 L471.66 55.07 L473.35 54.07 L475.06 53.08 L476.78 52.09 L478.52 51.10 L480.27 50.11 L482.03 49.11 L483.81 48.12 L485.60 47.13 L487.41 46.14 L489.24 45.15 L491.09 44.16 L492.95 43.17 L494.83 42.18 L496.73 41.19 L498.65 40.20 L500.59 39.21 L502.55 38.22 L504.53 37.23 L506.53 36.25 L508.53 35.28 L510.53 34.31 L512.53 33.37 L514.53 32.43 L516.53 31.50 L518.53 30.59 L520.53 29.69 L522.53 28.80 L524.53 27.93 L526.53 27.06 L528.53 26.21 L530.53 25.38 L532.53 24.55 L534.53 23.74 L536.53 22.94 L538.53 22.15 L540.53 21.38 L542.53 20.62 L544.53 19.87 L546.53 19.14 L548.53 18.42 L550.53 17.71 L552.53 17.01 L554.53 16.33 L556.53 15.66 L558.53 15.01 L560.53 14.37 L562.53 13.74 L564.53 13.13 L566.53 12.53 L568.53 11.94 L570.53 11.36 L572.53 10.80 L574.53 10.26 L576.53 9.73 L578.53 9.21 L580.53 8.70 L582.53 8.21 L584.53 7.74 L586.53 7.27 L588.53 6.83 L590.53 6.39 L592.53 5.97 L594.53 5.56 L596.53 5.17 L598.53 4.79 L600.53 4.43 L602.53 4.08 L604.53 3.74 L606.53 3.42 L608.53 3.12 L610.53 2.82 L612.53 2.55 L614.53 2.28 L616.53 2.03 L618.53 1.80 L620.53 1.58 L622.53 1.37 L624.53 1.18 L626.53 1.00 L628.53 0.84 L630.53 0.69 L632.53 0.55 L634.53 0.43 L636.53 0.33 L638.53 0.24 L640.53 0.16 L642.53 0.10 L644.53 0.05 L646.53 0.02 L648.53 0.00 " style="fill:none;stroke:red;stroke-width:1;" />
+<path d="M-0.00 400.00 L-0.00 400.00 L2.00 399.03 L4.00 398.07 L6.00 397.10 L8.00 396.13 L10.00 395.17 L12.00 394.20 L14.00 393.23 L16.00 392.27 L18.00 391.30 L20.00 390.34 L22.00 389.37 L24.00 388.41 L26.00 387.44 L28.00 386.48 L30.00 385.51 L32.00 384.55 L34.00 383.59 L36.00 382.62 L38.00 381.66 L40.00 380.70 L42.00 379.74 L44.00 378.77 L46.00 377.81 L48.00 376.85 L50.00 375.89 L52.00 374.93 L54.00 373.97 L56.00 373.02 L58.00 372.06 L60.00 371.10 L62.00 370.15 L64.00 369.19 L66.00 368.24 L68.00 367.28 L70.00 366.33 L72.00 365.38 L74.00 364.42 L76.00 363.47 L78.00 362.52 L80.00 361.57 L82.00 360.63 L84.00 359.68 L86.00 358.73 L88.00 357.79 L90.00 356.84 L92.00 355.90 L94.00 354.96 L96.00 354.02 L98.00 353.08 L100.00 352.14 L102.00 351.20 L104.00 350.26 L106.00 349.33 L108.00 348.39 L110.00 347.46 L112.00 346.53 L114.00 345.60 L116.00 344.67 L118.00 343.74 L120.00 342.81 L122.00 341.89 L124.00 340.96 L126.00 340.04 L128.00 339.12 L130.00 338.20 L132.00 337.28 L134.00 336.36 L136.00 335.45 L138.00 334.53 L140.00 333.62 L142.00 332.71 L144.00 331.80 L146.00 330.89 L148.00 329.98 L150.00 329.08 L152.00 328.18 L154.00 327.27 L156.00 326.37 L158.00 325.48 L160.00 324.58 L162.00 323.69 L164.00 322.79 L166.00 321.90 L168.00 321.01 L170.00 320.13 L172.00 319.24 L174.00 318.36 L176.00 317.48 L178.00 316.60 L180.00 315.72 L182.00 314.84 L184.00 313.97 L186.00 313.10 L188.00 312.23 L190.00 311.36 L192.00 310.50 L194.00 309.63 L196.00 308.77 L198.00 307.91 L200.00 307.06 L202.00 306.20 L204.00 305.35 L206.00 304.50 L208.00 303.65 L210.00 302.80 L212.00 301.96 L214.00 301.12 L216.00 300.28 L218.00 299.44 L220.00 298.61 L222.00 297.78 L224.00 296.95 L226.00 296.12 L228.00 295.29 L230.00 294.47 L232.00 293.65 L234.00 292.83 L236.00 292.02 L238.00 291.21 L240.00 290.40 L242.00 289.59 L244.00 288.79 L246.00 287.98 L248.00 287.18 L250.00 286.39 L252.00 285.59 L254.00 284.80 L256.00 284.01 L258.00 283.23 L260.00 282.44 L262.00 281.66 L264.00 280.88 L266.00 280.11 L268.00 279.34 L270.00 278.57 L272.00 277.80 L274.00 277.04 L276.00 276.28 L278.00 275.52 L280.00 274.76 L282.00 274.01 L284.00 273.26 L286.00 272.51 L288.00 271.77 L290.00 271.03 L292.00 270.29 L294.00 269.56 L296.00 268.83 L298.00 268.10 L300.00 267.38 L302.00 266.65 L304.00 265.93 L306.00 265.22 L308.00 264.51 L310.00 263.80 L312.00 263.09 L314.00 262.39 L316.00 261.69 L318.00 260.99 L320.00 260.30 L322.00 259.61 L324.00 258.92 L326.00 258.24 L328.00 257.56 L330.00 256.88 L332.00 256.21 L334.00 255.54 L336.00 254.87 L338.00 254.21 L340.00 253.55 L342.00 252.89 L344.00 252.24 L346.00 251.59 L348.00 250.94 L350.00 250.30 L352.00 249.66 L354.00 249.02 L356.00 248.39 L358.00 247.76 L360.00 247.14 L362.00 246.52 L364.00 245.90 L366.00 245.28 L368.00 244.67 L370.00 244.06 L372.00 243.46 L374.00 242.86 L376.00 242.27 L378.00 241.67 L380.00 241.08 L382.00 240.50 L384.00 239.92 L386.00 239.34 L388.00 238.77 L390.00 238.20 L392.00 237.63 L394.00 237.07 L396.00 236.51 L398.00 235.95 L400.00 235.40 L402.00 234.86 L404.00 234.31 L406.00 233.77 L408.00 233.24 L410.00 232.71 L412.00 232.18 L414.00 231.65 L416.00 231.13 L418.00 230.62 L420.00 230.11 L422.00 229.60 L424.00 229.09 L426.00 228.59 L428.00 228.10 L430.00 227.61 L432.00 227.12 L434.00 226.63 L436.00 226.15 L438.00 225.68 L440.00 225.21 L442.00 224.74 L444.00 224.27 L446.00 223.82 L448.00 223.36 L450.00 222.91 L452.00 222.46 L454.00 222.02 L456.00 221.58 L458.00 221.14 L460.00 220.71 L462.00 220.29 L464.00 219.87 L466.00 219.45 L468.00 219.03 L470.00 218.62 L472.00 218.22 L474.00 217.82 L476.00 217.42 L478.00 217.03 L480.00 216.64 L482.00 216.26 L484.00 215.88 L486.00 215.50 L488.00 215.13 L490.00 214.76 L492.00 214.40 L494.00 214.04 L496.00 213.69 L498.00 213.34 L500.00 213.00 L502.00 212.66 L504.00 212.32 L506.00 211.99 L508.00 211.66 L510.00 211.34 L512.00 211.02 L514.00 210.70 L516.00 210.39 L518.00 210.09 L520.00 209.79 L522.00 209.49 L524.00 209.20 L526.00 208.91 L528.00 208.63 L530.00 208.35 L532.00 208.08 L534.00 207.81 L536.00 207.54 L538.00 207.28 L540.00 207.02 L542.00 206.77 L544.00 206.53 L546.00 206.28 L548.00 206.05 L550.00 205.81 L552.00 205.58 L554.00 205.36 L556.00 205.14 L558.00 204.92 L560.00 204.71 L562.00 204.51 L564.00 204.30 L566.00 204.11 L568.00 203.91 L570.00 203.73 L572.00 203.54 L574.00 203.36 L576.00 203.19 L578.00 203.02 L580.00 202.85 L582.00 202.69 L584.00 202.54 L586.00 202.39 L588.00 202.24 L590.00 202.10 L592.00 201.96 L594.00 201.83 L596.00 201.70 L598.00 201.58 L600.00 201.46 L602.00 201.34 L604.00 201.23 L606.00 201.13 L608.00 201.03 L610.00 200.93 L612.00 200.84 L614.00 200.76 L616.00 200.67 L618.00 200.60 L620.00 200.53 L622.00 200.46 L624.00 200.39 L626.00 200.34 L628.00 200.28 L630.00 200.23 L632.00 200.19 L634.00 200.15 L636.00 200.11 L638.00 200.08 L640.00 200.06 L642.00 200.04 L644.00 200.02 L646.00 200.01 L648.00 200.00 " style="fill:none;stroke:#000000;stroke-width:1;" />
+<path d="M-0.00 400.00 L-0.00 400.00 L1.38 399.00 L2.76 398.00 L4.14 397.00 L5.52 396.00 L6.90 395.00 L8.28 394.00 L9.66 393.00 L11.04 392.00 L12.42 391.00 L13.80 390.00 L15.18 389.00 L16.56 388.00 L17.94 387.00 L19.32 386.00 L20.70 385.00 L22.08 384.00 L23.46 383.00 L24.84 382.00 L26.22 381.00 L27.60 380.00 L28.99 379.00 L30.37 378.00 L31.75 377.00 L33.14 376.00 L34.52 375.00 L35.90 374.00 L37.29 373.00 L38.67 372.00 L40.06 371.00 L41.44 370.00 L42.83 369.01 L44.22 368.01 L45.60 367.01 L46.99 366.01 L48.38 365.01 L49.77 364.01 L51.16 363.01 L52.55 362.01 L53.94 361.01 L55.33 360.01 L56.72 359.01 L58.11 358.01 L59.50 357.01 L60.90 356.01 L62.29 355.01 L63.68 354.01 L65.08 353.01 L66.48 352.01 L67.87 351.01 L69.27 350.01 L70.67 349.01 L72.07 348.01 L73.47 347.02 L74.87 346.02 L76.27 345.02 L77.67 344.02 L79.08 343.02 L80.48 342.02 L81.89 341.02 L83.29 340.02 L84.70 339.02 L86.11 338.02 L87.52 337.02 L88.93 336.02 L90.34 335.02 L91.75 334.02 L93.17 333.03 L94.58 332.03 L96.00 331.03 L97.41 330.03 L98.83 329.03 L100.25 328.03 L101.67 327.03 L103.09 326.03 L104.51 325.03 L105.94 324.03 L107.36 323.03 L108.79 322.03 L110.22 321.04 L111.65 320.04 L113.08 319.04 L114.51 318.04 L115.94 317.04 L117.38 316.04 L118.81 315.04 L120.25 314.04 L121.69 313.04 L123.13 312.04 L124.57 311.05 L126.02 310.05 L127.46 309.05 L128.91 308.05 L130.36 307.05 L131.81 306.05 L133.26 305.05 L134.71 304.05 L136.16 303.05 L137.62 302.06 L139.08 301.06 L140.54 300.06 L142.00 299.06 L143.47 298.06 L144.93 297.06 L146.40 296.06 L147.87 295.06 L149.34 294.07 L150.81 293.07 L152.29 292.07 L153.77 291.07 L155.25 290.07 L156.73 289.07 L158.21 288.07 L159.70 287.08 L161.18 286.08 L162.67 285.08 L164.17 284.08 L165.66 283.08 L167.16 282.08 L168.66 281.08 L170.16 280.09 L171.66 279.09 L173.17 278.09 L174.67 277.09 L176.19 276.09 L177.70 275.09 L179.21 274.10 L180.73 273.10 L182.25 272.10 L183.78 271.10 L185.30 270.10 L186.83 269.10 L188.36 268.11 L189.90 267.11 L191.44 266.11 L192.98 265.11 L194.52 264.11 L196.06 263.12 L197.61 262.12 L199.16 261.12 L200.72 260.12 L202.28 259.12 L203.84 258.13 L205.40 257.13 L206.97 256.13 L208.54 255.13 L210.11 254.13 L211.69 253.14 L213.27 252.14 L214.85 251.14 L216.44 250.14 L218.03 249.14 L219.62 248.15 L221.22 247.15 L222.82 246.15 L224.43 245.15 L226.04 244.16 L227.65 243.16 L229.26 242.16 L230.88 241.16 L232.51 240.17 L234.14 239.17 L235.77 238.17 L237.40 237.17 L239.04 236.18 L240.69 235.18 L242.34 234.18 L243.99 233.18 L245.65 232.19 L247.31 231.19 L248.98 230.19 L250.65 229.19 L252.32 228.20 L254.00 227.20 L255.69 226.20 L257.38 225.21 L259.07 224.21 L260.77 223.21 L262.48 222.21 L264.19 221.22 L265.90 220.22 L267.62 219.22 L269.35 218.23 L271.08 217.23 L272.82 216.23 L274.56 215.24 L276.31 214.24 L278.06 213.24 L279.82 212.25 L281.58 211.25 L283.36 210.25 L285.13 209.26 L286.92 208.26 L288.71 207.26 L290.50 206.27 L292.31 205.27 L294.12 204.28 L295.93 203.28 L297.76 202.28 L299.59 201.29 L301.43 200.29 L303.27 199.29 L305.12 198.30 L306.98 197.30 L308.85 196.31 L310.72 195.31 L312.61 194.31 L314.50 193.32 L316.40 192.32 L318.30 191.33 L320.22 190.33 L322.14 189.34 L324.08 188.34 L326.02 187.35 L327.97 186.35 L329.93 185.36 L331.90 184.36 L333.88 183.37 L335.87 182.37 L337.87 181.38 L339.87 180.39 L341.87 179.40 L343.87 178.42 L345.87 177.45 L347.87 176.48 L349.87 175.51 L351.87 174.55 L353.87 173.60 L355.87 172.65 L357.87 171.71 L359.87 170.77 L361.87 169.83 L363.87 168.91 L365.87 167.99 L367.87 167.07 L369.87 166.16 L371.87 165.25 L373.87 164.35 L375.87 163.46 L377.87 162.57 L379.87 161.69 L381.87 160.81 L383.87 159.94 L385.87 159.07 L387.87 158.21 L389.87 157.35 L391.87 156.50 L393.87 155.66 L395.87 154.82 L397.87 153.99 L399.87 153.16 L401.87 152.34 L403.87 151.52 L405.87 150.71 L407.87 149.91 L409.87 149.11 L411.87 148.32 L413.87 147.53 L415.87 146.75 L417.87 145.98 L419.87 145.21 L421.87 144.45 L423.87 143.69 L425.87 142.94 L427.87 142.20 L429.87 141.46 L431.87 140.73 L433.87 140.00 L435.87 139.28 L437.87 138.56 L439.87 137.86 L441.87 137.15 L443.87 136.46 L445.87 135.77 L447.87 135.09 L449.87 134.41 L451.87 133.74 L453.87 133.07 L455.87 132.41 L457.87 131.76 L459.87 131.11 L461.87 130.47 L463.87 129.84 L465.87 129.21 L467.87 128.59 L469.87 127.98 L471.87 127.37 L473.87 126.77 L475.87 126.17 L477.87 125.58 L479.87 125.00 L481.87 124.42 L483.87 123.85 L485.87 123.29 L487.87 122.73 L489.87 122.18 L491.87 121.64 L493.87 121.10 L495.87 120.57 L497.87 120.05 L499.87 119.53 L501.87 119.02 L503.87 118.51 L505.87 118.02 L507.87 117.52 L509.87 117.04 L511.87 116.56 L513.87 116.09 L515.87 115.62 L517.87 115.16 L519.87 114.71 L521.87 114.27 L523.87 113.83 L525.87 113.40 L527.87 112.97 L529.87 112.55 L531.87 112.14 L533.87 111.74 L535.87 111.34 L537.87 110.95 L539.87 110.56 L541.87 110.18 L543.87 109.81 L545.87 109.45 L547.87 109.09 L549.87 108.74 L551.87 108.40 L553.87 108.06 L555.87 107.73 L557.87 107.41 L559.87 107.09 L561.87 106.78 L563.87 106.48 L565.87 106.18 L567.87 105.89 L569.87 105.61 L571.87 105.33 L573.87 105.06 L575.87 104.80 L577.87 104.55 L579.87 104.30 L581.87 104.06 L583.87 103.82 L585.87 103.60 L587.87 103.38 L589.87 103.16 L591.87 102.96 L593.87 102.76 L595.87 102.56 L597.87 102.38 L599.87 102.20 L601.87 102.03 L603.87 101.86 L605.87 101.70 L607.87 101.55 L609.87 101.41 L611.87 101.27 L613.87 101.14 L615.87 101.02 L617.87 100.90 L619.87 100.80 L621.87 100.69 L623.87 100.60 L625.87 100.51 L627.87 100.43 L629.87 100.35 L631.87 100.29 L633.87 100.23 L635.87 100.17 L637.87 100.13 L639.87 100.09 L641.87 100.06 L643.87 100.03 L645.87 100.01 L647.87 100.00 L649.87 100.00 " style="fill:none;stroke:#000000;stroke-width:1;" />
+<path d="M-0.00 400.00 L-0.00 400.00 L1.03 399.00 L2.07 398.00 L3.10 397.00 L4.14 396.00 L5.17 395.00 L6.21 394.00 L7.24 393.00 L8.28 392.00 L9.31 391.00 L10.35 390.00 L11.38 389.00 L12.42 388.00 L13.45 387.00 L14.49 386.00 L15.52 385.00 L16.56 384.00 L17.59 383.00 L18.63 382.00 L19.66 381.00 L20.70 380.00 L21.73 379.00 L22.77 378.00 L23.81 377.00 L24.84 376.00 L25.88 375.00 L26.91 374.00 L27.95 373.00 L28.99 372.00 L30.02 371.00 L31.06 370.00 L32.10 369.00 L33.14 368.00 L34.17 367.00 L35.21 366.00 L36.25 365.00 L37.29 364.00 L38.33 363.00 L39.37 362.00 L40.41 361.00 L41.44 360.00 L42.48 359.01 L43.52 358.01 L44.56 357.01 L45.60 356.01 L46.64 355.01 L47.69 354.01 L48.73 353.01 L49.77 352.01 L50.81 351.01 L51.85 350.01 L52.90 349.01 L53.94 348.01 L54.98 347.01 L56.02 346.01 L57.07 345.01 L58.11 344.01 L59.16 343.01 L60.20 342.01 L61.25 341.01 L62.29 340.01 L63.34 339.01 L64.39 338.01 L65.43 337.01 L66.48 336.01 L67.53 335.01 L68.58 334.01 L69.63 333.01 L70.67 332.01 L71.72 331.01 L72.77 330.02 L73.82 329.02 L74.88 328.02 L75.93 327.02 L76.98 326.02 L78.03 325.02 L79.08 324.02 L80.14 323.02 L81.19 322.02 L82.25 321.02 L83.30 320.02 L84.36 319.02 L85.41 318.02 L86.47 317.02 L87.53 316.02 L88.58 315.02 L89.64 314.02 L90.70 313.02 L91.76 312.02 L92.82 311.03 L93.88 310.03 L94.94 309.03 L96.01 308.03 L97.07 307.03 L98.13 306.03 L99.20 305.03 L100.26 304.03 L101.33 303.03 L102.39 302.03 L103.46 301.03 L104.53 300.03 L105.59 299.03 L106.66 298.03 L107.73 297.03 L108.80 296.03 L109.87 295.04 L110.94 294.04 L112.02 293.04 L113.09 292.04 L114.16 291.04 L115.24 290.04 L116.31 289.04 L117.39 288.04 L118.47 287.04 L119.55 286.04 L120.62 285.04 L121.70 284.04 L122.79 283.04 L123.87 282.05 L124.95 281.05 L126.03 280.05 L127.12 279.05 L128.20 278.05 L129.29 277.05 L130.37 276.05 L131.46 275.05 L132.55 274.05 L133.64 273.05 L134.73 272.05 L135.82 271.05 L136.91 270.06 L138.01 269.06 L139.10 268.06 L140.20 267.06 L141.29 266.06 L142.39 265.06 L143.49 264.06 L144.59 263.06 L145.69 262.06 L146.79 261.06 L147.89 260.06 L149.00 259.07 L150.10 258.07 L151.21 257.07 L152.31 256.07 L153.42 255.07 L154.53 254.07 L155.64 253.07 L156.75 252.07 L157.87 251.07 L158.98 250.08 L160.10 249.08 L161.21 248.08 L162.33 247.08 L163.45 246.08 L164.57 245.08 L165.69 244.08 L166.81 243.08 L167.94 242.08 L169.06 241.09 L170.19 240.09 L171.32 239.09 L172.45 238.09 L173.58 237.09 L174.71 236.09 L175.84 235.09 L176.98 234.09 L178.11 233.09 L179.25 232.10 L180.39 231.10 L181.53 230.10 L182.67 229.10 L183.82 228.10 L184.96 227.10 L186.11 226.10 L187.26 225.11 L188.40 224.11 L189.56 223.11 L190.71 222.11 L191.86 221.11 L193.02 220.11 L194.18 219.11 L195.33 218.12 L196.50 217.12 L197.66 216.12 L198.82 215.12 L199.99 214.12 L201.16 213.12 L202.32 212.12 L203.50 211.13 L204.67 210.13 L205.84 209.13 L207.02 208.13 L208.20 207.13 L209.38 206.13 L210.56 205.13 L211.74 204.14 L212.93 203.14 L214.12 202.14 L215.30 201.14 L216.50 200.14 L217.69 199.14 L218.88 198.15 L220.08 197.15 L221.28 196.15 L222.48 195.15 L223.69 194.15 L224.89 193.15 L226.10 192.16 L227.31 191.16 L228.52 190.16 L229.73 189.16 L230.95 188.16 L232.17 187.17 L233.39 186.17 L234.61 185.17 L235.84 184.17 L237.07 183.17 L238.30 182.17 L239.53 181.18 L240.76 180.18 L242.00 179.18 L243.24 178.18 L244.48 177.18 L245.72 176.19 L246.97 175.19 L248.22 174.19 L249.47 173.19 L250.73 172.19 L251.99 171.20 L253.25 170.20 L254.51 169.20 L255.77 168.20 L257.04 167.21 L258.31 166.21 L259.59 165.21 L260.86 164.21 L262.14 163.21 L263.42 162.22 L264.71 161.22 L266.00 160.22 L267.29 159.22 L268.58 158.23 L269.88 157.23 L271.18 156.23 L272.48 155.23 L273.79 154.24 L275.10 153.24 L276.41 152.24 L277.73 151.24 L279.05 150.25 L280.37 149.25 L281.69 148.25 L283.02 147.25 L284.36 146.26 L285.69 145.26 L287.03 144.26 L288.38 143.26 L289.72 142.27 L291.07 141.27 L292.43 140.27 L293.79 139.27 L295.15 138.28 L296.52 137.28 L297.89 136.28 L299.26 135.29 L300.64 134.29 L302.02 133.29 L303.41 132.30 L304.80 131.30 L306.19 130.30 L307.59 129.30 L308.99 128.31 L310.40 127.31 L311.81 126.31 L313.23 125.32 L314.65 124.32 L316.07 123.32 L317.50 122.33 L318.94 121.33 L320.38 120.33 L321.82 119.34 L323.27 118.34 L324.73 117.34 L326.19 116.35 L327.65 115.35 L329.12 114.35 L330.60 113.36 L332.08 112.36 L333.56 111.37 L335.05 110.37 L336.55 109.37 L338.05 108.38 L339.56 107.38 L341.08 106.38 L342.60 105.39 L344.12 104.39 L345.66 103.40 L347.19 102.40 L348.74 101.40 L350.29 100.41 L351.85 99.41 L353.41 98.42 L354.98 97.42 L356.56 96.43 L358.15 95.43 L359.74 94.44 L361.34 93.44 L362.95 92.44 L364.56 91.45 L366.18 90.45 L367.81 89.46 L369.45 88.46 L371.09 87.47 L372.75 86.47 L374.41 85.48 L376.08 84.48 L377.76 83.49 L379.45 82.49 L381.14 81.50 L382.85 80.50 L384.56 79.51 L386.29 78.52 L388.02 77.52 L389.76 76.53 L391.52 75.53 L393.28 74.54 L395.06 73.54 L396.84 72.55 L398.64 71.56 L400.44 70.56 L402.26 69.57 L404.09 68.58 L405.93 67.58 L407.79 66.59 L409.65 65.60 L411.53 64.60 L413.42 63.61 L415.33 62.62 L417.25 61.62 L419.18 60.63 L421.13 59.64 L423.09 58.65 L425.07 57.65 L427.06 56.66 L429.06 55.67 L431.06 54.69 L433.06 53.72 L435.06 52.76 L437.06 51.80 L439.06 50.86 L441.06 49.92 L443.06 48.99 L445.06 48.06 L447.06 47.15 L449.06 46.24 L451.06 45.34 L453.06 44.45 L455.06 43.57 L457.06 42.70 L459.06 41.83 L461.06 40.98 L463.06 40.13 L465.06 39.29 L467.06 38.46 L469.06 37.63 L471.06 36.82 L473.06 36.01 L475.06 35.22 L477.06 34.43 L479.06 33.65 L481.06 32.88 L483.06 32.11 L485.06 31.36 L487.06 30.61 L489.06 29.87 L491.06 29.15 L493.06 28.43 L495.06 27.71 L497.06 27.01 L499.06 26.32 L501.06 25.63 L503.06 24.96 L505.06 24.29 L507.06 23.63 L509.06 22.98 L511.06 22.34 L513.06 21.70 L515.06 21.08 L517.06 20.47 L519.06 19.86 L521.06 19.26 L523.06 18.67 L525.06 18.09 L527.06 17.52 L529.06 16.96 L531.06 16.41 L533.06 15.87 L535.06 15.33 L537.06 14.81 L539.06 14.29 L541.06 13.78 L543.06 13.28 L545.06 12.79 L547.06 12.31 L549.06 11.84 L551.06 11.38 L553.06 10.93 L555.06 10.48 L557.06 10.05 L559.06 9.62 L561.06 9.20 L563.06 8.80 L565.06 8.40 L567.06 8.01 L569.06 7.63 L571.06 7.26 L573.06 6.89 L575.06 6.54 L577.06 6.20 L579.06 5.86 L581.06 5.54 L583.06 5.22 L585.06 4.92 L587.06 4.62 L589.06 4.33 L591.06 4.05 L593.06 3.78 L595.06 3.52 L597.06 3.27 L599.06 3.03 L601.06 2.79 L603.06 2.57 L605.06 2.36 L607.06 2.15 L609.06 1.96 L611.06 1.77 L613.06 1.59 L615.06 1.43 L617.06 1.27 L619.06 1.12 L621.06 0.98 L623.06 0.85 L625.06 0.73 L627.06 0.61 L629.06 0.51 L631.06 0.42 L633.06 0.34 L635.06 0.26 L637.06 0.20 L639.06 0.14 L641.06 0.09 L643.06 0.06 L645.06 0.03 L647.06 0.01 L649.06 0.00 " style="fill:none;stroke:#000000;stroke-width:1;" /></g></svg> \ No newline at end of file
diff --git a/test/decode_svg.c b/test/decode_svg.c
index 1b507fd..b723e9e 100644
--- a/test/decode_svg.c
+++ b/test/decode_svg.c
@@ -13,154 +13,182 @@
#include "svgtiny.h"
-int main(int argc, char *argv[])
+static void write_mvg(FILE *fh, float scale, struct svgtiny_diagram *diagram)
{
- FILE *fd;
- float scale = 1.0;
- struct stat sb;
- char *buffer;
- size_t size;
- size_t n;
- struct svgtiny_diagram *diagram;
- svgtiny_code code;
-
- if (argc != 2 && argc != 3) {
- fprintf(stderr, "Usage: %s FILE [SCALE]\n", argv[0]);
- return 1;
- }
-
- /* load file into memory buffer */
- fd = fopen(argv[1], "rb");
- if (!fd) {
- perror(argv[1]);
- return 1;
- }
-
- if (stat(argv[1], &sb)) {
- perror(argv[1]);
- return 1;
- }
- size = sb.st_size;
-
- buffer = malloc(size);
- if (!buffer) {
- fprintf(stderr, "Unable to allocate %lld bytes\n",
- (long long) size);
- return 1;
- }
-
- n = fread(buffer, 1, size, fd);
- if (n != size) {
- perror(argv[1]);
- return 1;
- }
-
- fclose(fd);
-
- /* read scale argument */
- if (argc == 3) {
- scale = atof(argv[2]);
- if (scale == 0)
- scale = 1.0;
- }
-
- /* create svgtiny object */
- diagram = svgtiny_create();
- if (!diagram) {
- fprintf(stderr, "svgtiny_create failed\n");
- return 1;
- }
-
- /* parse */
- code = svgtiny_parse(diagram, buffer, size, argv[1], 1000, 1000);
- if (code != svgtiny_OK) {
- fprintf(stderr, "svgtiny_parse failed: ");
- switch (code) {
- case svgtiny_OUT_OF_MEMORY:
- fprintf(stderr, "svgtiny_OUT_OF_MEMORY");
- break;
- case svgtiny_LIBDOM_ERROR:
- fprintf(stderr, "svgtiny_LIBDOM_ERROR");
- break;
- case svgtiny_NOT_SVG:
- fprintf(stderr, "svgtiny_NOT_SVG");
- break;
- case svgtiny_SVG_ERROR:
- fprintf(stderr, "svgtiny_SVG_ERROR: line %i: %s",
- diagram->error_line,
- diagram->error_message);
- break;
- default:
- fprintf(stderr, "unknown svgtiny_code %i", code);
- break;
- }
- fprintf(stderr, "\n");
- }
-
- free(buffer);
-
- printf("viewbox 0 0 %g %g\n",
- scale * diagram->width, scale * diagram->height);
-
- for (unsigned int i = 0; i != diagram->shape_count; i++) {
- if (diagram->shape[i].fill == svgtiny_TRANSPARENT)
- printf("fill none ");
- else
- printf("fill #%.6x ", diagram->shape[i].fill);
- if (diagram->shape[i].stroke == svgtiny_TRANSPARENT)
- printf("stroke none ");
- else
- printf("stroke #%.6x ", diagram->shape[i].stroke);
- printf("stroke-width %g ",
- scale * diagram->shape[i].stroke_width);
- if (diagram->shape[i].path) {
- printf("path '");
- for (unsigned int j = 0;
- j != diagram->shape[i].path_length; ) {
- switch ((int) diagram->shape[i].path[j]) {
- case svgtiny_PATH_MOVE:
- printf("M %g %g ",
- scale * diagram->shape[i].path[j + 1],
- scale * diagram->shape[i].path[j + 2]);
- j += 3;
- break;
- case svgtiny_PATH_CLOSE:
- printf("Z ");
- j += 1;
- break;
- case svgtiny_PATH_LINE:
- printf("L %g %g ",
- scale * diagram->shape[i].path[j + 1],
- scale * diagram->shape[i].path[j + 2]);
- j += 3;
- break;
- case svgtiny_PATH_BEZIER:
- printf("C %g %g %g %g %g %g ",
- scale * diagram->shape[i].path[j + 1],
- scale * diagram->shape[i].path[j + 2],
- scale * diagram->shape[i].path[j + 3],
- scale * diagram->shape[i].path[j + 4],
- scale * diagram->shape[i].path[j + 5],
- scale * diagram->shape[i].path[j + 6]);
- j += 7;
- break;
- default:
- printf("error ");
- j += 1;
- }
- }
- printf("' ");
- } else if (diagram->shape[i].text) {
- printf("text %g %g '%s' ",
- scale * diagram->shape[i].text_x,
- scale * diagram->shape[i].text_y,
- diagram->shape[i].text);
- }
- printf("\n");
- }
-
- svgtiny_free(diagram);
-
- return 0;
+ unsigned int i;
+
+ fprintf(fh, "viewbox 0 0 %g %g\n",
+ scale * diagram->width, scale * diagram->height);
+
+ for (i = 0; i != diagram->shape_count; i++) {
+ if (diagram->shape[i].fill == svgtiny_TRANSPARENT) {
+ fprintf(fh, "fill none ");
+ } else {
+ fprintf(fh, "fill #%.6x ", diagram->shape[i].fill);
+ }
+
+ if (diagram->shape[i].stroke == svgtiny_TRANSPARENT) {
+ fprintf(fh, "stroke none ");
+ } else {
+ fprintf(fh, "stroke #%.6x ", diagram->shape[i].stroke);
+ }
+ fprintf(fh, "stroke-width %g ",
+ scale * diagram->shape[i].stroke_width);
+
+ if (diagram->shape[i].path) {
+ unsigned int j;
+ fprintf(fh, "path '");
+ for (j = 0; j != diagram->shape[i].path_length; ) {
+ switch ((int) diagram->shape[i].path[j]) {
+ case svgtiny_PATH_MOVE:
+ fprintf(fh, "M %g %g ",
+ scale * diagram->shape[i].path[j + 1],
+ scale * diagram->shape[i].path[j + 2]);
+ j += 3;
+ break;
+
+ case svgtiny_PATH_CLOSE:
+ fprintf(fh, "Z ");
+ j += 1;
+ break;
+
+ case svgtiny_PATH_LINE:
+ fprintf(fh, "L %g %g ",
+ scale * diagram->shape[i].path[j + 1],
+ scale * diagram->shape[i].path[j + 2]);
+ j += 3;
+ break;
+
+ case svgtiny_PATH_BEZIER:
+ fprintf(fh, "C %g %g %g %g %g %g ",
+ scale * diagram->shape[i].path[j + 1],
+ scale * diagram->shape[i].path[j + 2],
+ scale * diagram->shape[i].path[j + 3],
+ scale * diagram->shape[i].path[j + 4],
+ scale * diagram->shape[i].path[j + 5],
+ scale * diagram->shape[i].path[j + 6]);
+ j += 7;
+ break;
+
+ default:
+ fprintf(fh, "error ");
+ j += 1;
+ }
+ }
+ fprintf(fh, "' ");
+ } else if (diagram->shape[i].text) {
+ fprintf(fh, "text %g %g '%s' ",
+ scale * diagram->shape[i].text_x,
+ scale * diagram->shape[i].text_y,
+ diagram->shape[i].text);
+ }
+ fprintf(fh, "\n");
+ }
}
+int main(int argc, char *argv[])
+{
+ FILE *fd;
+ float scale = 1.0;
+ struct stat sb;
+ char *buffer;
+ size_t size;
+ size_t n;
+ struct svgtiny_diagram *diagram;
+ svgtiny_code code;
+ FILE *outf = stdout;
+
+ if (argc < 2 || argc > 4) {
+ fprintf(stderr, "Usage: %s FILE [SCALE] [out]\n", argv[0]);
+ return 1;
+ }
+
+ /* load file into memory buffer */
+ fd = fopen(argv[1], "rb");
+ if (!fd) {
+ perror(argv[1]);
+ return 1;
+ }
+
+ if (stat(argv[1], &sb)) {
+ perror(argv[1]);
+ return 1;
+ }
+ size = sb.st_size;
+
+ buffer = malloc(size);
+ if (!buffer) {
+ fprintf(stderr, "Unable to allocate %lld bytes\n",
+ (long long) size);
+ return 1;
+ }
+
+ n = fread(buffer, 1, size, fd);
+ if (n != size) {
+ perror(argv[1]);
+ return 1;
+ }
+
+ fclose(fd);
+
+ /* read scale argument */
+ if (argc > 2) {
+ scale = atof(argv[2]);
+ if (scale == 0)
+ scale = 1.0;
+ }
+
+ /* output file */
+ if (argc > 3) {
+ outf = fopen(argv[3], "w+");
+ if (outf == NULL) {
+ fprintf(stderr, "Unable to open %s for writing\n", argv[3]);
+ return 2;
+ }
+ }
+
+ /* create svgtiny object */
+ diagram = svgtiny_create();
+ if (!diagram) {
+ fprintf(stderr, "svgtiny_create failed\n");
+ return 1;
+ }
+
+ /* parse */
+ code = svgtiny_parse(diagram, buffer, size, argv[1], 1000, 1000);
+ if (code != svgtiny_OK) {
+ fprintf(stderr, "svgtiny_parse failed: ");
+ switch (code) {
+ case svgtiny_OUT_OF_MEMORY:
+ fprintf(stderr, "svgtiny_OUT_OF_MEMORY");
+ break;
+ case svgtiny_LIBDOM_ERROR:
+ fprintf(stderr, "svgtiny_LIBDOM_ERROR");
+ break;
+ case svgtiny_NOT_SVG:
+ fprintf(stderr, "svgtiny_NOT_SVG");
+ break;
+ case svgtiny_SVG_ERROR:
+ fprintf(stderr, "svgtiny_SVG_ERROR: line %i: %s",
+ diagram->error_line,
+ diagram->error_message);
+ break;
+ default:
+ fprintf(stderr, "unknown svgtiny_code %i", code);
+ break;
+ }
+ fprintf(stderr, "\n");
+ }
+
+ free(buffer);
+
+ write_mvg(outf, scale, diagram);
+
+ if (argc > 3) {
+ fclose(outf);
+ }
+
+ svgtiny_free(diagram);
+
+ return 0;
+}
diff --git a/test/runtest.sh b/test/runtest.sh
index f1c33ea..3cd5e8c 100755
--- a/test/runtest.sh
+++ b/test/runtest.sh
@@ -1,14 +1,16 @@
#!/bin/sh
TEST_PATH=$1
-TEST_OUT=${TEST_PATH}/svg
+TEST_OUT=${TEST_PATH}/test
mkdir -p ${TEST_OUT}
svgdecode()
{
OUTF=$(basename ${1} .svg)
- ${TEST_PATH}/test_decode_svg ${1} > ${TEST_OUT}/${OUTF}.svg
+ echo "TEST: ${OUTF}"
+ ${TEST_PATH}/test_decode_svg ${1} > ${TEST_OUT}/${OUTF}.mvg
+ #convert mvg:${TEST_OUT}/${OUTF}.mvg png:${TEST_OUT}/${OUTF}.png
}