Skip to content

Instantly share code, notes, and snippets.

@sfpgmr
Last active October 23, 2016 09:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sfpgmr/9d6cbae6f65de393196f to your computer and use it in GitHub Desktop.
Save sfpgmr/9d6cbae6f65de393196f to your computer and use it in GitHub Desktop.
three.jsのPathのシリアライズ

three.jsのPathのシリアライズ(2)

エドワード・マイブリッジの「Horse in motion」をInkscapeでトレースし、各馬をセル化したものをthree.jsのshapeに変換し表示しています。

今回はシリアライズ・デシリアライズのコードを最適化してみました。 http://bl.ocks.org/sfpgmr/cee0c48acb0854e2055c#pathSerializer.js

下記のURLから動くデモが見れます。Windows 10 Tech Preview 9926 のIE11では動作しませんでした。ひょっとするとIE11ではそもそも動作しないのかもしれません。原因は不明ですが。。

http://bl.ocks.org/sfpgmr/cee0c48acb0854e2055c

Display the source blob
Display the rendered blob
Raw
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
version="1.1"
id="svg2"
viewBox="0 0 1536 952"
height="952"
width="1536">
<defs
id="defs4" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
id="layer7"
style="display:inline">
<path
id="horse00"
style="display:inline;opacity:1;fill:#000000"
d="m 223.44064,240.57693 c 0,-0.50063 -0.8449,-5.5769 -1.87756,-5.5769 -3.07569,0 -4.61651,-2.62022 -3.27378,-5.56719 0.62848,-1.37937 1.42261,-4.88952 1.76471,-7.80031 0.72252,-6.14752 1.56126,-5.53989 -14.61337,-10.5867 -21.09535,-6.58217 -22.06188,-7.08971 -18.74441,-9.84296 2.73207,-2.26741 6.27447,-2.3796 8.19315,-0.25948 1.02368,1.13115 2.42056,2.05664 3.10417,2.05664 0.68362,0 3.20138,1.11347 5.59502,2.47439 4.80234,2.73039 11.4698,4.08935 15.32107,3.12275 1.37204,-0.34436 3.13061,-1.85709 3.90794,-3.36163 2.65236,-5.13373 5.62306,-15.55837 5.62306,-19.73221 l 0,-4.16638 -11.76704,-1.15148 c -13.02172,-1.27425 -25.22128,-4.52666 -34.31761,-9.14908 -8.39372,-4.26538 -13.01336,-4.13224 -17.25456,0.49728 -2.66482,2.90881 -4.64506,3.87925 -11.19901,5.48819 -4.37898,1.07501 -9.14418,1.95987 -10.58934,1.96636 -3.25169,0.0146 -5.24714,2.25586 -4.39602,4.93751 0.35291,1.11193 3.56373,4.65896 7.13515,7.8823 6.30415,5.68972 6.52054,6.04769 7.42086,12.27631 1.83421,12.6895 0.96098,14.50867 -4.19323,8.73558 -3.32055,-3.71925 -3.31589,-3.69431 -1.2428,-6.65405 1.4906,-2.12813 1.4557,-2.42453 -0.52656,-4.47251 -1.16763,-1.20633 -6.24097,-6.91833 -11.27409,-12.69333 -5.03312,-5.775 -9.76779,-10.64966 -10.52148,-10.83258 -3.01669,-0.73213 -3.98207,1.86951 -4.66905,12.5828 -0.61966,9.66349 -0.9377,10.98124 -3.14727,13.04025 -1.35187,1.25976 -2.45795,2.66884 -2.45795,3.13128 0,0.68287 -7.34805,3.07825 -9.44282,3.07825 -0.30645,0 -0.55718,-1.02487 -0.55718,-2.27749 0,-3.61542 2.7469,-6.72251 5.9432,-6.72251 3.71755,0 4.33074,-2.58197 4.63107,-19.5 0.12693,-7.15 0.27464,-13.5625 0.32826,-14.25 0.0711,-0.91128 2.87501,-1.25415 10.34747,-1.26531 5.6375,-0.008 10.82994,-0.38326 11.53875,-0.83297 1.57107,-0.99677 0.55236,-4.08667 -3.14228,-9.53102 -3.41313,-5.02953 -4.26994,-11.19276 -2.23357,-16.06648 2.97682,-7.12454 1.35661,-7.60666 -3.54611,-1.0552 -1.85173,2.47447 -4.49179,4.78631 -5.86679,5.13743 -1.375,0.35112 -4.39823,2.17 -6.71829,4.04194 -2.32006,1.87195 -5.69506,3.89744 -7.5,4.5011 -1.80494,0.60366 -4.18171,1.8602 -5.28171,2.79232 -3.10127,2.62796 -10.603295,5.03318 -15.533436,4.98016 -5.651263,-0.0608 -11.431784,-2.78956 -11.568333,-5.46101 -0.05597,-1.09503 -1.068472,-3.88553 -2.25,-6.20112 -2.399475,-4.70255 -2.791081,-8.30438 -0.898234,-8.26157 0.6875,0.0156 3.95,1.83147 7.25,4.03539 3.877699,2.58973 6.707434,3.82257 8,3.48538 1.1,-0.28695 3.0125,-0.52788 4.25,-0.53539 2.32956,-0.0141 3.303196,-2.98335 1,-3.04961 -3.166466,-0.0911 5.07727,-4.89014 9.428153,-5.48854 2.65027,-0.36451 6.41437,-1.74561 8.36467,-3.06912 1.9503,-1.32351 4.3472,-2.40638 5.32644,-2.40638 0.97924,0 5.12175,-1.13975 9.20559,-2.53278 4.08383,-1.39303 10.12515,-2.96048 13.42515,-3.48323 3.3,-0.52275 8.46057,-1.633 11.46793,-2.46722 7.34436,-2.03728 14.47316,-1.90985 27.03207,0.48323 13.24355,2.52353 22.4846,2.70524 21.60956,0.4249 -0.46801,-1.21959 0.0157,-1.53423 2.14301,-1.39403 6.8584,0.45197 6.86933,0.44283 6.91285,-5.78087 0.0522,-7.46069 0.62773,-11.23832 2.12306,-13.93426 0.66633,-1.20134 1.21152,-3.24369 1.21152,-4.538561 0,-5.319465 8.10263,-17.05132 14.63902,-21.195929 4.61044,-2.923402 5.82986,-5.591098 3.78701,-8.284778 -0.74933,-0.988062 -1.37673,-3.731938 -1.39423,-6.097503 -0.0294,-3.974206 0.23171,-4.411129 3.43608,-5.75 6.09152,-2.5452 8.05839,-1.986345 9.85809,2.801027 0.87872,2.3375 1.46402,5.375 1.30066,6.75 -0.3561,2.997285 -2.71028,6.999937 -4.11718,7.000161 -0.59996,9.5e-5 -1.02757,3.595323 -1.05411,8.862813 -0.0246,4.874458 -0.64495,10.68151 -1.37862,12.904558 -1.32738,4.022002 -1.31562,4.060242 2.3876,7.763462 3.63961,3.6396 8.08559,5.3957 13.78568,5.44515 1.78838,0.0155 2.75,-0.50066 2.75,-1.47614 0,-0.825 0.68625,-1.5 1.525,-1.5 0.88503,0 1.76999,-1.22493 2.10878,-2.91889 0.41797,-2.08985 1.33396,-3.10241 3.225,-3.56499 3.7794,-0.92452 12.14122,-9.392883 12.14122,-12.29592 0,-2.747269 0.34297,-2.691557 12,1.949259 8.8595,3.527081 12.76091,5.516612 24.91383,12.704841 9.7966,5.79449 10.83518,7.52675 7.53369,12.56545 -1.44377,2.20346 -2.10947,2.3523 -9.50616,2.12533 -4.37452,-0.13424 -8.25091,-0.54129 -8.61419,-0.90457 -1.26021,-1.26022 -12.43672,-0.65522 -15.30596,0.82852 -2.94072,1.52071 -4.65073,4.68337 -3.52077,6.51168 0.34624,0.56023 -0.29971,2.19994 -1.43546,3.6438 -1.13574,1.44387 -2.06498,3.43182 -2.06498,4.41769 0,2.6282 -6.64985,14.95758 -9.94443,18.4378 -3.88945,4.10862 -6.50508,9.78399 -8.06527,17.5 -1.09987,5.43949 -1.95589,7.10098 -5.24666,10.1835 -2.1628,2.02592 -6.16808,4.48746 -8.90064,5.47007 -4.15972,1.49582 -5.82098,2.93066 -10.2077,8.8165 -3.60217,4.83317 -5.97152,9.37358 -7.58222,14.52993 -1.28854,4.125 -2.71288,8.625 -3.16518,10 -0.45231,1.375 -0.94962,4.7403 -1.10514,7.47845 -0.27469,4.83632 -0.18857,5.0095 3.01648,6.0664 1.87464,0.61818 6.13237,6.41017 7.17939,8.17962 2.17043,3.18244 11.55251,2.29918 -11.97863,1.85247 z m 20,-120.01348 c 0.825,-0.32957 1.97817,-1.62719 2.56261,-2.8836 1.37457,-2.95505 -0.47532,-4.36943 -10.54948,-8.06589 l -7.48686,-2.74712 -1.76314,2.17738 c -2.38811,2.9492 -2.39637,10.46193 -0.0131,11.94664 1.73997,1.08397 14.24205,0.7742 17.25,-0.42741 z" />
<rect
style="display:inline;opacity:0.38000039;fill:none;stroke:#000000;stroke-width:1.00782073;stroke-opacity:1"
id="frame00"
width="358.99219"
height="238.99217"
x="22.490698"
y="29.846764" />
</g>
<g
id="layer8"
style="display:inline">
<rect
style="display:inline;opacity:0.38000039;fill:none;stroke:#000000;stroke-width:1.00782073;stroke-opacity:1"
id="frame01"
width="358.99219"
height="238.99217"
x="398.17059"
y="31.170578" />
<path
id="horse01"
style="display:inline;opacity:1;fill:#000000"
d="m 616.5824,117.97734 c 4.77322,-1.32582 6.7241,-3.55485 4.77234,-5.45277 -1.44795,-1.40799 -12.33376,-5.52454 -14.60912,-5.52454 -1.36237,0 -5.30498,6.97621 -5.30498,9.38684 0,2.51856 8.56245,3.41794 15.14176,1.59047 z m -74.64176,66.43936 0,-6.91667 -3.92576,0.31521 c -7.29199,0.58549 -12.20546,4.51436 -9.58877,7.66728 1.49984,1.8072 11.15193,6.54707 12.51453,6.14553 0.55,-0.16208 1,-3.40719 1,-7.21135 z m 84.34609,15.15211 c 3.49036,-0.74853 6.79455,-1.80942 7.34265,-2.35752 2.06349,-2.06349 -2.07987,-6.75505 -9.94315,-11.25868 -4.43725,-2.54139 -4.89203,-2.61196 -7.82372,-1.21393 -3.54658,1.69125 -9.13337,10.96484 -8.1498,13.52797 0.56645,1.47615 3.43117,2.22361 9.72793,2.53821 1.375,0.0687 5.35574,-0.48752 8.84609,-1.23605 z m -39.67836,9.40135 c 4.06857,-1.13004 9.83227,-6.96036 9.83227,-9.94591 0,-1.0484 0.38728,-2.14554 0.86061,-2.43807 0.47334,-0.29254 1.61749,-3.22938 2.54256,-6.52631 0.92507,-3.29693 2.1128,-6.26069 2.63939,-6.58614 1.57989,-0.97643 1.08087,-4.21236 -0.75844,-4.91817 -0.94374,-0.36214 -6.44499,-1.57107 -12.22501,-2.6865 -5.78001,-1.11542 -14.44817,-3.56727 -19.26258,-5.44854 -4.81441,-1.88127 -9.12897,-3.42049 -9.58791,-3.42049 -0.45894,0 -2.05804,1.27717 -3.55356,2.83815 -3.21411,3.35481 -7.23305,16.72284 -6.22955,20.7211 0.69225,2.75813 7.06938,6.17812 17.07449,9.15688 3.45384,1.02829 6.30903,2.84851 9.23318,5.88625 4.71452,4.89767 4.3696,4.77454 9.43455,3.36775 z m -30.06386,7.19597 c -1.13841,-0.78667 -0.91607,-1.44481 1.20455,-3.56543 2.68937,-2.68937 5.5825,-3.2646 8.51796,-1.69359 1.93552,1.03586 7.17362,0.29875 7.17362,-1.00947 0,-2.74583 -15.47111,-9.80076 -21.63337,-9.86496 -3.27477,-0.0341 -4.32226,1.59427 -4.35298,6.76701 -0.0163,2.74297 -2.67777,8.20034 -3.99919,8.20034 -0.5138,0 -1.4731,-1.79877 -2.13179,-3.99726 -1.04475,-3.48708 -0.97058,-4.24812 0.58114,-5.96276 1.85392,-2.04855 1.48712,-5.03998 -0.61797,-5.03998 -0.66932,0 -2.14594,-0.84313 -3.28139,-1.87363 -2.40613,-2.18374 -17.35353,-10.12637 -19.05701,-10.12637 -0.63735,0 -2.21126,-1.12028 -3.4976,-2.48952 -2.31061,-2.45954 -2.31573,-2.51499 -0.42553,-4.60364 1.05229,-1.16277 3.82597,-3.23505 6.16373,-4.60507 4.00456,-2.34683 8.25196,-6.99361 8.25196,-9.02788 0,-0.50456 -2.1506,-1.88933 -4.77912,-3.07727 -2.62852,-1.18794 -6.53169,-3.95469 -8.67373,-6.14833 -4.19374,-4.29479 -4.71722,-6.73024 -3.18073,-14.79829 0.76538,-4.019 0.68231,-4.24996 -1.52852,-4.24921 -3.86541,0.001 -15.05672,5.84673 -19.5068,10.18876 -2.29289,2.23722 -5.32773,4.19488 -6.74409,4.35036 -2.42261,0.26593 -6.77202,3.19016 -14.37181,9.66257 -5.19899,4.42776 -14.09218,3.4213 -17.38737,-1.96776 -0.9197,-1.50409 -3.07595,-4.74285 -4.79167,-7.19724 -2.94499,-4.21288 -3.011,-4.50264 -1.18015,-5.17992 1.06663,-0.39457 2.23694,-1.19894 2.60068,-1.78748 0.76283,-1.23428 5.54331,-1.46796 5.54331,-0.27097 0,1.07552 6.04111,3.20089 9.09814,3.20089 1.35087,0 3.97944,-1.39132 5.84126,-3.09183 4.69271,-4.28613 16.16061,-9.67067 23.45781,-11.01418 18.81679,-3.46442 25.21929,-5.78339 33.60279,-12.17089 6.84,-5.21148 11.48112,-5.68186 26.28841,-2.66433 12.49223,2.54576 19.68316,2.74342 20.89699,0.57441 0.67884,-1.21302 1.4392,-1.34621 3.40925,-0.59719 2.81123,1.06882 7.74999,1.28603 8.65536,0.38066 0.32085,-0.32084 -0.002,-1.97616 -0.71806,-3.67849 -1.11684,-2.65619 -1.04585,-3.83793 0.50058,-8.33272 0.9911,-2.88067 1.54605,-5.49353 1.23322,-5.80636 -0.31283,-0.31283 0.6244,-1.76196 2.08273,-3.22029 1.73891,-1.738912 2.65152,-3.728555 2.65152,-5.780759 0,-5.900914 8.19375,-17.125745 15.05716,-20.627194 4.46281,-2.276756 4.83464,-3.428116 1.87984,-5.820768 -1.22787,-0.99427 -2.28774,-3.346142 -2.61819,-5.809799 -0.48034,-3.581238 -0.23592,-4.345087 1.813,-5.665803 1.3025,-0.839585 3.9553,-1.816055 5.8951,-2.169933 3.30422,-0.60279 3.69883,-0.38081 6.25,3.515767 3.53181,5.394405 3.61271,10.250717 0.22309,13.392115 -2.11659,1.961587 -2.50223,3.219524 -2.51455,8.202251 -0.0159,6.447213 -2.02434,13.348011 -4.97738,17.1022 -2.34081,2.975857 -1.96236,3.911993 3.28934,8.136463 3.87458,3.11671 4.58128,3.32349 10.01513,2.93044 6.25251,-0.45226 7.65164,-1.52033 6.93085,-5.29088 -0.37952,-1.98534 0.18185,-2.646584 3.40103,-4.006077 l 3.85558,-1.62825 -3,-2.443059 c -3.39587,-2.765439 -3.19309,-3.07724 4.25,-6.53482 2.3375,-1.085852 4.25351,-2.290719 4.2578,-2.677482 0.01,-0.864525 4.9031,-3.203206 6.70246,-3.203206 3.49162,0 14.70124,6.356249 24.78974,14.056654 3.3,2.518843 8.61993,6.25169 11.82206,8.29521 5.55955,3.54796 5.79125,3.86051 5.13871,6.93181 -0.37585,1.76898 -1.37802,4.00383 -2.22705,4.96633 -1.78351,2.02186 -5.87038,2.33692 -6.48592,0.5 -0.27965,-0.83456 -2.38454,-1.20286 -6.33333,-1.10818 -3.25296,0.078 -6.18886,-0.29644 -6.52423,-0.83211 -0.33538,-0.53566 -3.28685,-1.21668 -6.55883,-1.51338 -5.74381,-0.52083 -6.04191,-0.42909 -8.64024,2.65884 -2.83534,3.36962 -3.4992,6.04483 -1.50004,6.04483 0.65512,0 0.4059,0.57417 -0.55382,1.27594 -0.95973,0.70177 -2.78971,4.26584 -4.06663,7.92017 -1.27692,3.65432 -4.4027,10.46191 -6.94618,15.12798 -2.97454,5.45688 -4.6245,9.71867 -4.6245,11.94498 0,1.94702 -0.87495,4.57353 -2,6.0038 -1.1,1.39842 -2,3.23745 -2,4.08672 0,0.84927 -1.575,3.07376 -3.5,4.94329 -1.925,1.86954 -3.5,3.85325 -3.5,4.40826 0,0.55501 1.4625,2.62281 3.25,4.59512 9.08542,10.02478 10.98163,13.50343 9.04781,16.59852 -1.23022,1.96896 -16.76888,6.03112 -24.31681,6.35696 -3.69914,0.1597 -6.90658,-0.38546 -9.72703,-1.65325 -5.00167,-2.24826 -6.06014,-1.67969 -9.16343,4.92227 -1.51909,3.23173 -2.8264,4.59579 -4.83619,5.04615 -1.51489,0.33945 -4.32935,1.04297 -6.25435,1.56337 -5.1009,1.37895 -29.22594,2.17996 -30.89613,1.02582 z" />
</g>
<g
id="layer9"
style="display:inline">
<rect
style="display:inline;opacity:0.38000039;fill:none;stroke:#000000;stroke-width:1.00782073;stroke-opacity:1"
id="frame02"
width="358.99219"
height="238.99217"
x="771.50391"
y="31.003906" />
<path
id="horse02"
style="display:inline;opacity:1;fill:#000000"
d="m 996.83877,115.32648 2.47907,-2.67356 -6.1886,-3.2883 c -8.86631,-4.71109 -10.6886,-4.30388 -10.6886,2.38848 0,4.05442 2.67251,6.24695 7.61452,6.24695 3.3812,0 4.83631,-0.57349 6.78361,-2.67357 z m -62.39813,70.80843 c 0,-3.06985 -3.34752,-8.13486 -5.37641,-8.13486 -0.67719,0 -2.75866,1.57588 -4.62548,3.50195 -3.81449,3.93556 -3.39827,5.1891 2.15924,6.50304 6.60235,1.56096 7.84265,1.2652 7.84265,-1.87013 z m 48.8,16.66514 c 1.45277,-1.45277 1.64309,-17.50439 0.25095,-21.16599 -0.76973,-2.02455 -1.85614,-2.61997 -5.75,-3.15134 -7.48245,-1.0211 -18.53549,-4.26102 -25.84823,-7.57678 -3.6676,-1.66297 -6.88481,-2.80714 -7.14934,-2.5426 -1.44481,1.4448 -2.14443,8.96908 -1.31044,14.09334 0.94944,5.8336 2.3353,8.53884 4.3795,8.54895 0.62016,0.003 2.86105,0.48691 4.97976,1.07522 3.29076,0.91375 3.78709,1.4102 3.40551,3.40631 -0.40537,2.12057 -0.15941,2.29006 2.65942,1.83263 2.31112,-0.37505 3.59068,0.0314 4.99947,1.5881 1.04136,1.15069 2.63363,2.09216 3.53839,2.09216 0.90475,0 2.07251,0.40632 2.59501,0.90294 2.20998,2.10049 11.42283,2.72423 13.25,0.89706 z m -15.44989,6.21494 c -2.26629,-2.13245 -17.64752,-7.0255 -22.06531,-7.01939 -2.08603,0.003 -4.36882,-0.98451 -6.5,-2.81151 -3.50977,-3.00883 -16.83771,-7.18404 -22.93259,-7.18404 -1.87396,0 -4.39087,-0.68899 -5.59313,-1.53109 -1.86705,-1.30773 -2.03567,-1.92773 -1.1559,-4.25 0.56653,-1.4954 1.96121,-3.713 3.0993,-4.92799 1.1381,-1.215 2.68278,-4.57426 3.43264,-7.46504 1.63665,-6.30945 1.32725,-6.72102 -6.92163,-9.20712 -6.56387,-1.97826 -12.37152,-6.55607 -14.36245,-11.32102 -0.74307,-1.77843 -1.35104,-5.72296 -1.35104,-8.76562 0,-3.69584 -0.41491,-5.57145 -1.25,-5.6506 -2.4948,-0.23647 -4.28013,0.30529 -5.75,1.74484 -1.33026,1.30283 -1.22268,1.67931 0.95071,3.32705 1.9962,1.5134 2.22491,2.13006 1.23317,3.32502 -1.5961,1.92319 -12.85607,3.23852 -14.69051,1.71607 -0.74374,-0.61726 -2.74169,-1.29812 -4.43988,-1.51304 -3.32011,-0.42019 -10.00021,3.33345 -15.37875,8.64153 -4.9452,4.8804 -11.82657,8.87701 -15.28447,8.87701 -4.1065,0 -9.79888,-4.77161 -8.79944,-7.37609 0.40891,-1.06561 0.0169,-2.19023 -1.03025,-2.95596 -1.55452,-1.13669 -1.48811,-1.4541 0.82682,-3.95195 3.12047,-3.36704 4.64508,-3.401 8.46292,-0.1885 l 3.00376,2.52751 2.43913,-2.27751 c 12.42207,-11.59896 19.07921,-14.57904 38.41342,-17.19584 8.64243,-1.16971 10.94122,-1.88551 15,-4.67068 16.41929,-11.26709 16.47534,-11.29652 22.31524,-11.71894 3.12092,-0.22575 9.45524,0.29237 14.07627,1.15138 13.30204,2.47273 17.91301,2.89222 19.28402,1.75438 0.8754,-0.72651 3.13206,-0.69483 7.42928,0.10433 3.39458,0.63129 6.4738,0.84596 6.8427,0.47706 0.36891,-0.36891 0.14764,-1.81881 -0.4917,-3.22202 -0.63934,-1.4032 -1.16244,-4.13083 -1.16244,-6.0614 0,-4.19123 1.89485,-12.392555 3.26883,-14.148255 0.5391,-0.688865 0.71036,-2.601558 0.38059,-4.250429 -0.86244,-4.312179 0.3461,-6.66255 7.30984,-14.216187 4.63717,-5.029992 7.07498,-6.884302 9.69739,-7.376268 3.88556,-0.728937 5.22589,-2.761816 3.56958,-5.413993 -0.59918,-0.959434 -1.39126,-3.353425 -1.76019,-5.319978 -0.61647,-3.286063 -0.39936,-3.741026 2.68159,-5.61937 5.37724,-3.278309 9.13577,-2.747 12.01673,1.698706 4.2626,6.577826 3.1482,12.530785 -2.89586,15.468951 -2.30724,1.121602 -2.71584,1.884502 -2.45245,4.578948 0.32102,3.283974 -2.72748,12.818251 -5.43485,16.997684 -1.94426,3.001405 -1.26529,4.816992 3.72264,9.954421 3.81786,3.93226 4.51732,4.25 9.35622,4.25 3.9434,0 5.671,-0.48736 7.0229,-1.98124 1.46,-1.6133 1.5609,-2.26094 0.5431,-3.48727 -1.8368,-2.21329 -0.5684,-4.333153 3.1769,-5.30903 2.7685,-0.721389 3.3028,-1.327952 3.3334,-3.784092 0.026,-2.102809 0.5883,-3.02521 2,-3.281514 2.3765,-0.431484 6.4636,-4.041256 6.4636,-5.708727 0,-0.661783 0.6129,-1.711886 1.362,-2.333562 1.0395,-0.862786 2.7555,-0.512979 7.25,1.477916 12.0196,5.324351 16.5901,8.059466 23.651,14.153383 3.9804,3.435226 7.6045,6.247726 8.0537,6.250006 0.4492,0.002 2.2846,1.1237 4.0786,2.49207 2.6625,2.03076 3.1827,3.027 2.8313,5.42149 -0.2368,1.61345 -1.4867,3.92573 -2.7775,5.1384 -2.46,2.31099 -4.1623,2.28998 -10.09,-0.12456 -2.7201,-1.10799 -4.1268,-0.98717 -10.5,0.90184 -4.0475,1.19967 -8.0217,2.1798 -8.8316,2.17806 -2.7007,-0.006 2.2472,-2.67808 6.3528,-3.43103 5.3227,-0.97618 3.2669,-2.84801 -3.2591,-2.96748 -3.9634,-0.0726 -5.4982,0.40093 -7.551,2.32939 -1.4171,1.33126 -2.4806,2.9032 -2.3635,3.49321 0.1171,0.59001 -0.2917,1.98129 -0.9084,3.09173 -0.6168,1.11045 -2.0905,4.89573 -3.275,8.41174 -1.1844,3.51601 -3.2947,8.64477 -4.6895,11.39724 -1.5627,3.08392 -2.6732,7.18615 -2.8935,10.68928 -0.2163,3.43998 -1.3248,7.59304 -2.8071,10.51729 -2.2685,4.47498 -2.3329,4.98742 -0.8704,6.92622 0.8686,1.15154 4.8773,4.2654 8.9082,6.91968 9.8266,6.47059 9.765,7.19409 -1.5627,18.35713 l -8.8917,8.76243 -8.1724,-0.29148 c -7.7856,-0.27768 -8.1576,-0.39602 -7.8583,-2.5 0.4249,-2.98751 6.3611,-6.00838 8.8062,-4.4814 1.3245,0.82719 2.8155,0.66885 6.1291,-0.65089 5.082,-2.02405 7.546,-4.03202 9.4383,-7.69134 2.8565,-5.52381 -2.6004,-7.76193 -19.1184,-7.84134 -5.821,-0.028 -9.60806,0.40322 -10.59553,1.20645 -1.61626,1.3147 -5.24869,13.1088 -6.39071,20.75 -1.04718,7.00656 -2.10384,7.66596 -12.36144,7.71407 -7.11628,0.0334 -9.26281,-0.30611 -10.74327,-1.69913 z" />
</g>
<g
id="layer10"
style="display:inline">
<rect
style="display:inline;opacity:0.38000039;fill:none;stroke:#000000;stroke-width:1.00782073;stroke-opacity:1"
id="frame03"
width="358.99219"
height="238.99217"
x="1145.5039"
y="30.503914" />
<path
style="display:inline;opacity:1;fill:#000000"
d="m 1342.0059,239.03316 c 0,0 -2.6766,0.88564 -5.2983,0.90907 0,0 -4.6373,-0.52548 -1.267,-2.9422 l 0,-2.46482 c 0,-2.43858 -2.448,-4.53518 -5.2954,-4.53518 -1.2048,0 -14.5387,-12.53535 -19.8209,-18.63388 -0.889,-1.02637 -3.1856,-3.07024 -5.1036,-4.54194 -2.9826,-2.28854 -3.5779,-3.44638 -4.1132,-8 -0.9399,-7.9952 -3.4084,-15.36353 -6.2972,-18.79663 -1.4195,-1.68702 -5.7959,-5.12676 -9.7253,-7.64389 -14.3924,-9.21956 -20.2276,-17.49098 -19.4877,-27.62402 0.2706,-3.70617 0.033,-4.29952 -1.8263,-4.56654 -2.4397,-0.35032 -5.3304,3.08208 -5.3304,6.32941 0,4.6284 -4.4409,5.6621 -12.5287,2.91624 -4.3709,-1.48398 -4.7724,-1.45866 -8.1117,0.51157 -1.9322,1.14005 -3.8632,1.85648 -4.291,1.59207 -0.4278,-0.26441 -1.8217,0.63038 -3.0976,1.98843 -1.2758,1.35805 -2.6712,2.46918 -3.1009,2.46918 -1.1046,0 -6.6337,3.84394 -14.2746,9.92404 -7.8896,6.27787 -10.8754,6.50964 -13.8621,1.07596 -1.0581,-1.925 -2.8484,-4.50076 -3.9784,-5.7239 -1.8102,-1.9594 -1.8633,-2.29732 -0.446,-2.84117 0.8847,-0.33949 3.2823,-0.0649 5.328,0.61029 3.6952,1.21951 3.7447,1.19883 7.5666,-3.15884 2.1158,-2.41251 4.5057,-5.59199 5.3107,-7.06551 0.8051,-1.47352 2.3125,-2.94852 3.3499,-3.27778 1.0374,-0.32926 3.4343,-2.10219 5.3265,-3.93985 3.7683,-3.65973 5.9181,-4.12303 32.4034,-6.9833 11.1463,-1.20374 12.5178,-1.58677 17.5,-4.88734 14.7379,-9.7634 19.5315,-10.7746 37.6428,-7.94066 10.9592,1.71482 12.4612,1.75759 14.3857,0.4096 1.7204,-1.20502 2.7699,-1.28332 5.2632,-0.39271 1.7128,0.61184 4.9702,1.40362 7.2386,1.75952 5.5966,0.87808 6.4563,-0.85814 2.4643,-4.97688 -3.6937,-3.81085 -4.2727,-8.4011 -1.69,-13.39565 0.9374,-1.81268 1.4435,-4.1175 1.1248,-5.12183 -0.4062,-1.27985 0.027,-1.984703 1.4485,-2.35641 1.5262,-0.399109 2.0289,-1.357734 2.0317,-3.873964 0,-4.281457 2.6114,-8.502166 9.7668,-15.814553 4.1714,-4.263008 6.908,-6.167485 10.0631,-7.003237 3.5178,-0.931848 4.1903,-1.465832 3.5726,-2.836875 -0.4185,-0.928925 -0.9473,-3.793586 -1.1752,-6.365913 -0.3901,-4.405563 -0.2315,-4.771416 2.7336,-6.304751 4.4126,-2.281821 11.3939,-1.704915 11.88,0.981709 0.199,1.1 0.9494,2.675 1.6676,3.5 1.6367,1.880188 1.0147,7.760311 -1.0638,10.057003 -0.8528,0.942394 -2.8155,1.966411 -4.3614,2.275594 -2.6922,0.538444 -2.8315,0.85304 -3.3043,7.460195 -0.3644,5.093672 -1.2392,8.224465 -3.344,11.968895 l -2.8505,5.07085 2.8193,5.572277 c 3.1973,6.31927 7.5773,9.61354 12.7105,9.55975 l 3.382,-0.0354 -2.5,-1.39225 c -2.3374,-1.30173 -2.3749,-1.44075 -0.5764,-2.13817 1.058,-0.41026 2.7455,-1.5678 3.75,-2.57232 1.0045,-1.00451 3.0639,-1.8364 4.5764,-1.84863 l 2.75,-0.0222 -2.5,-1.95559 -2.5,-1.95553 3.45,-0.0222 c 2.6833,-0.0173 3.1833,-0.288911 2.25,-1.222244 -1.8974,-1.897391 -1.4467,-2.531142 2.3,-3.234022 2.0951,-0.393039 3.5,-1.240526 3.5,-2.111291 0,-0.800108 -0.45,-1.454717 -1,-1.454717 -0.55,0 -1,-0.45 -1,-1 0,-0.55 1.3409,-1 2.9798,-1 1.6388,0 4.7643,-0.714055 6.9455,-1.58679 3.5995,-1.440224 4.4557,-1.443434 9.2702,-0.03476 6.1366,1.795499 14.0386,6.650811 18.9486,11.642804 1.8819,1.9133 6.712,6.50503 10.7336,10.20384 7.2214,6.64177 7.2959,6.7615 6.0116,9.66279 -0.7152,1.61573 -2.7508,3.62938 -4.5237,4.47479 -2.9743,1.41837 -3.4038,1.39511 -5.5602,-0.3011 -2.6513,-2.08554 -8.9671,-4.04771 -13.0554,-4.056 -1.5125,-0.003 -2.75,-0.40831 -2.75,-0.90054 0,-1.24563 -8.0101,-1.95759 -10.7756,-0.95777 -1.2516,0.45249 -2.5789,1.61697 -2.9496,2.58772 -0.3707,0.97076 -1.0475,2.21501 -1.5041,2.76501 -0.4566,0.55 -2.8689,5.24892 -5.3607,10.44204 -3.0521,6.36113 -4.3422,10.19209 -3.9535,11.74074 0.8324,3.3164 -1.3459,11.2974 -4.0941,15.0005 -1.2993,1.7508 -2.3624,3.62107 -2.3624,4.15616 0,0.98429 3.6605,1.58168 16.6628,2.71932 11.1928,0.97932 11.0843,0.74715 12.3621,26.44124 0.2554,5.13575 -1.445,16 -2.5043,16 -3.5116,0 -5.8637,-6.64043 -3.1499,-8.89269 1.032,-0.85652 1.281,-3.41925 1.0076,-10.37245 -0.5845,-14.86248 -1.011,-15.69375 -8.065,-15.71955 -4.6108,-0.0169 -20.1518,3.42316 -21.4842,4.75558 -0.8745,0.87449 0.6854,2.8139 6.0217,7.48682 1.7321,1.51675 3.1492,3.55412 3.1492,4.5275 0,2.96436 -2.8237,6.01772 -6.2512,6.7597 -1.7869,0.38681 -5.8235,1.99744 -8.9703,3.57919 -3.1468,1.58174 -6.408,2.8759 -7.2471,2.8759 -3.6157,0 -13.8613,-12.06004 -11.4904,-13.52531 2.7703,-1.71215 10.3106,2.44539 9.2846,5.11927 -1.3441,3.50256 14.883,0.11356 17.1694,-3.58579 1.2485,-2.02016 -1.5524,-3.65047 -12.495,-7.27307 -8.6169,-2.85265 -12.6521,-3.59664 -22.5,-4.14843 -14.8788,-0.83368 -24.1074,-2.21526 -31.2791,-4.68271 -8.4121,-2.89416 -8.425,-2.88684 -7.654,4.34604 0.3664,3.4375 1.1762,6.77077 1.7996,7.40726 1.5504,1.58296 9.1365,4.01977 18.4072,5.91277 4.2495,0.8677 8.6263,2.13345 9.7263,2.81277 1.1,0.67933 4.101,2.01938 6.6689,2.9779 4.3939,1.64014 8.4706,5.66649 7.1124,7.02468 -0.3381,0.33804 -2.7593,0.61462 -5.3806,0.61462 -3.6724,0 -4.8942,-0.40413 -5.325,-1.76137 -0.3445,-1.08564 -2.3845,-2.22493 -5.3173,-2.96972 -2.6171,-0.6646 -8.1334,-2.13998 -12.2584,-3.27862 -4.125,-1.13865 -10.3125,-2.34235 -13.75,-2.67488 -7.0128,-0.67842 -7.4556,-0.1366 -4.8955,5.99064 1.1428,2.73511 17.2862,18.69395 18.9101,18.69395 0.2945,0 2.1132,1.57781 4.0417,3.50625 1.9284,1.92844 4.8911,3.78323 6.5837,4.12175 1.6927,0.33853 2.8566,0.97296 2.5866,1.40984 -0.27,0.43688 -0.027,2.0137 0.5393,3.50404 l 1.0303,2.70972 c 3.573,3.31768 3.1172,2.16608 -1.3249,2.61527 -2.0085,1.96855 -4.2822,1.6232 -4.156,-0.83373 z"
id="horse03" />
</g>
<g
id="layer11"
style="display:inline">
<rect
style="display:inline;opacity:0.38000039;fill:none;stroke:#000000;stroke-width:1.00782073;stroke-opacity:1"
id="frame04"
width="358.99219"
height="238.99217"
x="26.003906"
y="274.00391" />
<path
id="horse04"
style="display:inline;opacity:1;fill:#000000"
d="m 242.44064,363.82542 c 5.26461,-1.60502 5.84885,-2.67876 2.20576,-4.05388 -1.76591,-0.66655 -3.43919,-1.93167 -3.71839,-2.81136 -0.56323,-1.77452 -6.55922,-4.96015 -9.33608,-4.96015 -1.8927,0 -5.15129,5.66947 -5.15129,8.9625 0,1.04205 0.74738,2.64203 1.66085,3.55549 1.77255,1.77255 7.09685,1.5154 14.33915,-0.69255 z m -84,120.24501 c -3.575,-0.39889 -3.37917,-1.13625 -2.41667,-1.23118 2.26903,-0.22379 -0.11634,-2.17795 -2.4934,-6.70312 -1.05053,-1.99988 -3.61605,-7.46115 -5.70114,-12.13615 -2.0851,-4.675 -4.60057,-9.69447 -5.58994,-11.15437 -0.98937,-1.45985 -1.79885,-3.13217 -1.79885,-3.71621 0,-0.58404 1.7967,-3.84174 3.99267,-7.23933 3.77086,-5.83424 5.98922,-11.37948 6.00175,-15.00254 0.003,-0.88687 -1.40842,-3.36187 -3.13664,-5.5 -4.45972,-5.51751 -11.85902,-21.43985 -11.85162,-25.5032 0.003,-1.86137 0.69472,-4.70471 1.53629,-6.31855 2.50927,-4.81191 1.4047,-5.73242 -4.74571,-3.95495 -3.40241,0.98329 -6.4816,2.75718 -8.60972,4.95998 -3.55264,3.67729 -5.65556,4.11246 -10.83044,2.2412 -4.35013,-1.57303 -6.05508,-0.60676 -17.640967,9.99796 -5.068589,4.63935 -10.642381,9.04614 -12.386206,9.79286 -1.743824,0.74673 -5.246687,2.75882 -7.78414,4.47133 -4.301427,2.903 -7.54527,3.32558 -7.54527,0.98293 0,-0.55313 1.291705,-1.67367 2.870455,-2.49007 2.926955,-1.51359 6.034571,-6.92425 7.933516,-13.81302 0.865873,-3.14112 0.767017,-3.89468 -0.612182,-4.66652 -1.388176,-0.77686 -1.11348,-1.20654 1.760604,-2.75396 1.872975,-1.00842 4.925375,-3.30646 6.783111,-5.10676 1.857736,-1.8003 5.231544,-4.5003 7.497352,-6 4.021102,-2.6615 4.577101,-2.74145 23.242677,-3.34191 l 19.12302,-0.61518 11.45072,-5.60395 c 13.40893,-6.56229 16.26941,-6.91901 33.83324,-4.21921 9.32979,1.43412 11.80715,1.52238 13.73719,0.48946 1.83598,-0.98259 3.20913,-1.00419 6.23351,-0.0981 5.50526,1.64942 12.14679,1.5225 12.14679,-0.23211 0,-0.76684 -1.39359,-2.88609 -3.09686,-4.70945 -4.32772,-4.63284 -4.76741,-8.6559 -1.57104,-14.37482 1.41535,-2.53234 2.32149,-5.26064 2.01365,-6.06288 -0.30785,-0.8022 -0.0826,-1.45858 0.50047,-1.45858 0.5831,0 1.94931,-2.01 3.03601,-4.46666 3.70443,-8.37448 7.64929,-13.00499 13.93224,-16.35377 3.28102,-1.74876 6.88844,-3.17957 8.01649,-3.17957 3.04263,0 3.64052,-1.86161 1.38874,-4.32403 -1.0944,-1.19678 -2.26655,-3.18847 -2.60476,-4.42597 -0.33822,-1.2375 -0.87261,-3.15738 -1.18753,-4.26639 -0.46363,-1.6327 0.24994,-2.38967 3.75,-3.97804 4.32751,-1.96388 9.8193,-2.6656 9.82633,-1.25557 0.002,0.4125 0.97869,2.325 2.17029,4.25 3.03293,4.89958 3.3156,9.09732 0.79483,11.80305 -1.12572,1.20832 -2.46341,2.19695 -2.97263,2.19695 -1.6534,0 -3.1629,4.07742 -3.1629,8.54355 0,3.47775 -0.79512,5.47399 -3.91666,9.83318 -2.15417,3.00825 -3.91667,5.74736 -3.91667,6.08691 0,1.61327 4.94279,7.02187 8.80013,9.62945 5.01675,3.39135 8.09751,3.67525 10.42202,0.96043 0.91664,-1.07057 3.47265,-2.43279 5.68002,-3.02718 4.79872,-1.29216 5.923,-2.70248 3.54217,-4.44338 -1.53795,-1.12458 -1.08487,-1.38753 3.64987,-2.11827 4.00545,-0.61819 4.69342,-0.93316 2.65579,-1.21592 -1.5125,-0.20989 -2.75,-0.74713 -2.75,-1.19387 0,-0.89619 3.9187,-2.54482 8.37859,-3.52494 1.58322,-0.34794 4.45219,-1.7019 6.37549,-3.00882 3.93412,-2.6733 5.23182,-2.44886 13.17835,2.27922 5.72934,3.4089 29.06757,26.78273 29.06757,29.11192 0,1.83196 -3.45915,5.48456 -6,6.33554 -0.825,0.27631 -3.01496,-0.41054 -4.86659,-1.52633 -2.11903,-1.27694 -6.93644,-2.48486 -13,-3.25963 -5.29837,-0.677 -7.85591,-1.28288 -5.68341,-1.34639 5.65421,-0.16529 3.11514,-2.27252 -2.84683,-2.36265 -5.05067,-0.0763 -6.87121,0.83357 -4.57421,2.28624 1.13827,0.71986 0.9055,0.93724 -1.02896,0.96094 -3.55579,0.0436 -4.39449,0.82019 -7.55951,7 -1.54927,3.025 -3.85717,7.06696 -5.12867,8.98213 -1.73116,2.60752 -2.31182,4.89929 -2.31182,9.12428 0,3.10317 -0.68372,7.58 -1.51937,9.94849 -0.83565,2.3685 -1.17315,4.61389 -0.75,4.98977 1.41992,1.26127 10.10736,2.95533 15.15549,2.95533 4.00717,0 5.30432,0.4338 6.53009,2.18383 0.84129,1.20111 1.31842,3.11361 1.06028,4.25 -0.35772,1.57483 0.54049,2.73168 3.77709,4.86473 3.96791,2.615 16.32147,12.46772 17.99863,14.35499 2.7612,3.10714 9.74779,13.32258 9.74779,14.25274 0,0.72741 -0.9826,0.89692 -2.75,0.47443 -4.52787,-1.08238 -6.25,-2.33504 -6.25,-4.54618 0,-2.36349 -12.17637,-14.86553 -16.68097,-17.12712 -1.55047,-0.77842 -5.06246,-1.9642 -7.80442,-2.63504 -4.89942,-1.19869 -5.02451,-1.17103 -7.25354,1.60395 -1.24748,1.55302 -3.57845,5.52367 -5.17994,8.82367 -2.85572,5.88446 -3.05303,6.05329 -10.24646,8.76722 -10.27041,3.87481 -10.92496,3.73067 -8.77211,-1.93177 1.41577,-3.72376 2.76476,-4.46317 6.93744,-3.80259 2.75456,0.43608 3.71298,0.156 4.5,-1.31504 0.55,-1.02803 2.4625,-4.06069 4.25,-6.73926 1.7875,-2.67857 3.25,-5.1962 3.25,-5.59475 0,-1.00532 -10.99068,-2.08159 -20,-1.9585 -24.88446,0.33997 -50.31887,-0.12344 -55.5,-1.01119 -3.3,-0.56544 -7.75028,-1.2951 -9.8895,-1.62147 l -3.8895,-0.59341 0.72299,3.85387 c 0.9577,5.10498 3.72117,10.32946 7.21443,13.63919 4.25943,4.03566 25.13692,13.71678 31.97672,14.82795 3.57811,0.58129 6.37085,1.64038 7.16258,2.71627 1.13531,1.54278 0.94758,1.91427 -1.5,2.96838 -4.03993,1.73988 -7.44399,1.52241 -10.2801,-0.65672 -1.78021,-1.36784 -2.83744,-1.61268 -3.73763,-0.86558 -0.90962,0.75491 -2.56659,0.201 -6.01762,-2.01162 -2.6193,-1.67935 -10.068,-5.60359 -16.55266,-8.72052 l -11.7903,-5.66714 -2.98903,-5.92124 c -3.1715,-6.28269 -9.37395,-13.86208 -11.34379,-13.86208 -2.0541,0 -8.30454,7.34914 -9.53383,11.2097 -0.64969,2.04033 -2.95248,6.31533 -5.1173,9.5 -6.71956,9.88515 -6.95015,13.48 -1.52604,23.7903 0.86804,1.65 1.58103,3.3984 1.58442,3.88533 0.0166,2.38343 5.27355,5.61467 9.1346,5.61467 3.14846,0 4.6857,0.66029 7.0563,3.03089 0.96495,3.23635 0.98193,3.27287 0.98193,3.27287 -7.15,0.27057 -11.925,0.49891 -15.5,0.10002 z" />
</g>
<g
id="layer12"
style="display:inline">
<rect
style="display:inline;opacity:0.38000039;fill:none;stroke:#000000;stroke-width:1.00782073;stroke-opacity:1"
id="frame05"
width="358.99219"
height="238.99217"
x="398.50391"
y="274.50391" />
<path
id="horse05"
style="display:inline;opacity:1;fill:#000000"
d="m 612.44064,367.81397 c 5.02741,-1.05225 11,-3.82473 11,-5.10621 0,-0.82009 -14.35425,-7.84283 -18.70292,-9.15029 -1.84242,-0.55394 -2.53792,-0.006 -4.25,3.35028 -1.12589,2.20693 -2.04708,4.378 -2.04708,4.8246 0,0.44659 1.40504,2.51655 3.12231,4.59989 2.19187,2.65912 3.60735,3.58462 4.75,3.10574 0.89523,-0.37518 3.65269,-1.10599 6.12769,-1.62401 z m 56.83288,60.25602 c 0.88275,-6.02868 -2.03906,-8.8425 -7.85535,-7.56502 -4.05778,0.89123 -3.7416,2.68519 1.22209,6.93393 4.60347,3.9404 6.12746,4.0854 6.63326,0.63109 z m -182.76354,60.51359 c -0.93282,-1.12398 -0.80325,-1.51942 0.62756,-1.91518 0.9917,-0.2743 -0.93711,-0.46566 -4.28625,-0.42525 -7.68345,0.0927 -10.86606,-1.52585 -4.41065,-2.24312 3.64772,-0.4053 4.55794,-0.90643 4.80591,-2.64594 0.24694,-1.7322 -0.57247,-2.48139 -4.25,-3.88586 -4.65538,-1.7779 -5.1861,-2.35098 -3.72119,-4.0182 0.97509,-1.10976 4.64594,-10.48371 4.68015,-11.95131 0.0128,-0.55072 0.80225,-2.11335 1.75424,-3.47251 0.95199,-1.35915 1.73089,-2.99463 1.73089,-3.63438 0,-0.63975 0.67223,-2.45212 1.49384,-4.02749 0.82161,-1.57537 1.49661,-4.0158 1.5,-5.42318 0.008,-3.22868 1.47233,-5.07899 6.50616,-8.21985 2.2,-1.37269 6.12511,-4.55208 8.72246,-7.06532 l 4.72245,-4.56953 -0.5765,-14.29321 -0.5765,-14.29322 2.63704,-3.489 c 1.45037,-1.91895 2.1722,-3.64395 1.60407,-3.83333 -0.56813,-0.18937 -4.97048,0.56417 -9.78299,1.67455 -4.81252,1.11037 -11.00003,2.29336 -13.75003,2.62886 -2.75,0.3355 -8.825,2.052 -13.5,3.81446 -7.86881,2.9665 -9.15412,3.87278 -17.30878,12.20446 -4.84483,4.95 -9.71963,10.0652 -10.83289,11.36711 -2.94817,3.44774 -4.57278,1.46087 -3.02623,-3.70103 0.64234,-2.14397 1.1679,-4.91613 1.1679,-6.16037 0,-2.85492 5.51618,-12.60607 7.57899,-13.39765 2.53293,-0.97197 0.5644,-2.60806 -3.13801,-2.60806 -3.57264,0 -4.61133,-1.33692 -1.85919,-2.39301 0.86998,-0.33385 3.68248,-0.60758 6.25,-0.6083 3.81413,-10e-4 5.71728,-0.72952 10.40218,-3.98156 7.50047,-5.20648 12.74906,-6.45978 23.7748,-5.67715 11.11003,0.78861 22.8983,-0.6636 32.23543,-3.97111 19.79302,-7.01132 19.73759,-7.00245 31.05764,-4.97472 19.24219,3.4468 18.83814,3.40463 19.36896,2.02134 0.38278,-0.9975 2.8826,-1.15877 10.91286,-0.70402 6.7349,0.38139 10.41634,0.23295 10.41634,-0.42001 0,-0.55543 -1.80331,-3.05855 -4.00736,-5.56248 -5.22171,-5.93217 -5.84696,-9.18283 -2.85283,-14.83158 1.28197,-2.41857 2.34935,-4.8474 2.37195,-5.3974 0.0226,-0.55 0.39575,-1.56653 0.82922,-2.25895 0.43346,-0.69242 0.51088,-2.13243 0.17204,-3.20002 -0.89335,-2.8147 1.7838,-7.3024 7.61196,-12.75994 6.51434,-6.10009 9.46922,-8.05171 14.12502,-9.32922 3.71458,-1.01924 4.90596,-3.30212 2.87129,-5.50187 -0.48329,-0.5225 -1.17471,-2.61636 -1.5365,-4.65303 -0.57484,-3.23606 -0.33611,-3.91381 1.89314,-5.37446 1.40301,-0.91929 4.54031,-1.89567 6.97179,-2.16973 4.32488,-0.48748 4.45483,-0.417 5.98557,3.24659 0.86059,2.05968 1.56471,5.16479 1.56471,6.90025 0,3.40049 -2.36966,7.59084 -4.3067,7.61569 -2.62863,0.0337 -4.064,2.04045 -4.75491,6.6476 -0.39896,2.6604 -1.83821,7.87271 -3.19831,11.58291 l -2.47293,6.74583 6.86501,5.61648 c 6.28855,5.14485 7.30599,5.62804 12.11643,5.75417 4.46781,0.11715 5.20817,-0.12081 4.9616,-1.59475 -0.2111,-1.26194 1.41845,-2.52661 6,-4.65653 3.4594,-1.60824 7.75231,-3.22689 9.53981,-3.597 2.22346,-0.46038 3.25,-1.24531 3.25,-2.48507 0,-1.09895 0.98389,-2.05908 2.5,-2.43959 1.375,-0.34511 2.5,-1.06889 2.5,-1.60841 0,-0.53952 1.36412,-0.98095 3.03138,-0.98095 1.81689,0 3.26993,-0.62164 3.6268,-1.55161 0.81112,-2.11376 5.32732,-1.05413 11.37987,2.67004 2.57573,1.58486 5.14115,2.88157 5.70094,2.88157 0.55978,0 2.78655,2.3625 4.94838,5.25 2.16182,2.8875 5.92904,7.9072 8.3716,11.15488 6.19749,8.24031 9.94103,13.57676 9.94103,14.17103 0,0.27779 -0.98463,1.83685 -2.18806,3.46458 -2.7563,3.7281 -8.42111,4.15384 -11.40459,0.85713 -2.52535,-2.79048 -6.73131,-4.89762 -9.7759,-4.89762 -3.76058,0 -6.10664,-1.08829 -4.49426,-2.08479 2.22074,-1.37249 0.17966,-2.17359 -5.85224,-2.29693 -4.14311,-0.0847 -5.714,0.23648 -5.53495,1.13172 0.1375,0.6875 -0.61901,1.25 -1.68112,1.25 -1.27645,0 -3.83088,2.69576 -7.53491,7.9518 -8.1674,11.58958 -9.46155,15.05937 -8.81867,23.64406 l 0.53138,7.09586 7.62666,1.16075 c 4.19466,0.63841 8.84299,1.15777 10.32961,1.15414 3.92448,-0.01 7.768,2.02166 8.35371,4.41483 0.27979,1.14321 0.0831,5.00356 -0.43701,8.57856 -0.79713,5.4787 -0.67072,7.04993 0.80447,10 3.47882,6.95685 21.35408,16.98287 30.3364,17.01531 2.33171,0.008 4.90658,0.43713 5.72192,0.95267 1.23792,0.78275 1.00089,1.43998 -1.4371,3.98469 -3.44659,3.59747 -3.94014,3.66854 -7.27247,1.04733 -1.50802,-1.18621 -4.05678,-2 -6.26393,-2 -2.67605,0 -4.95551,-0.93859 -8.11514,-3.3415 -7.09817,-5.39817 -12.99084,-8.83524 -14.29172,-8.33605 -0.6665,0.25576 -1.82788,2.42534 -2.58083,4.82129 -1.86888,5.94689 -2.6796,6.65717 -4.92786,4.31737 -3.29361,-3.42772 -3.51119,-6.14125 -0.64312,-8.02048 3.33797,-2.18712 3.21729,-3.41561 -0.70027,-7.12852 -4.36202,-4.13416 -23.83798,-14.31211 -27.38686,-14.31211 -1.55872,0 -7.77103,0.72401 -13.80514,1.60892 -8.06769,1.18313 -15.4815,1.48619 -28.01455,1.14517 -15.39173,-0.41881 -18.2064,-0.78454 -29.04345,-3.77385 -6.6,-1.82055 -13.575,-3.34838 -15.5,-3.39517 l -3.5,-0.0851 0.12563,15.5 c 0.13982,17.24981 0.75406,20.5778 4.96749,26.91435 1.59879,2.40439 3.40679,5.22415 4.01778,6.26612 2.39333,4.08151 5.80538,6.81953 8.49831,6.81953 4.6789,0 7.82783,1.80012 9.58135,5.47728 0.92392,1.9375 2.04652,3.52272 2.49465,3.52272 0.44814,0 0.81479,0.4663 0.81479,1.03621 0,0.66284 -3.4574,0.93309 -9.59527,0.75 L 559.2501,486.5 l -1.36829,-3.98677 c -0.75256,-2.19272 -2.05969,-4.49233 -2.90473,-5.11024 -0.84504,-0.61788 -1.53644,-1.59376 -1.53644,-2.16859 0,-0.57483 -1.575,-2.9303 -3.5,-5.23437 -1.925,-2.30407 -3.5,-4.59665 -3.5,-5.09461 0,-0.49797 -0.79358,-1.69897 -1.76351,-2.6689 -4.68736,-4.68736 -6.02526,-7.80452 -6.755,-15.73839 -0.83195,-9.04512 -3.95812,-16.45384 -8.08337,-19.15681 -2.43374,-1.59465 -2.77271,-1.59297 -5.74227,0.0286 -10.43113,5.69596 -33.42078,24.81375 -34.3331,28.55078 -0.34632,1.41864 -1.4598,4.14615 -2.47439,6.06112 -3.77612,7.12721 -3.30248,13.01821 1.04668,13.01821 0.90758,0 2.53998,1.65441 3.62756,3.67648 1.08757,2.02206 2.55874,4.25876 3.26927,4.97044 1.05625,1.05796 0.82826,1.41032 -1.25,1.93193 -1.6018,0.40202 -2.54187,1.33754 -2.54187,2.52956 0,2.26083 -3.19329,2.56855 -4.93066,0.47514 z" />
</g>
<g
id="layer13"
style="display:inline">
<rect
style="display:inline;opacity:0.38000039;fill:none;stroke:#000000;stroke-width:1.00782073;stroke-opacity:1"
id="frame06"
width="358.99219"
height="238.99217"
x="770.00391"
y="273.50391" />
<path
id="horse06"
style="display:inline;opacity:1;fill:#000000"
d="m 998.78304,364.23183 c 3.76326,-1.29247 7.29756,-2.80508 7.85376,-3.36136 1.2317,-1.23164 -3.2903,-3.45061 -11.19616,-5.49408 -3.025,-0.78188 -6.25129,-1.74567 -7.16954,-2.14176 -1.3051,-0.56296 -2.12188,0.30244 -3.7418,3.96454 -1.24265,2.80921 -1.83197,5.64208 -1.47205,7.07611 0.51454,2.0501 1.19132,2.38536 4.7418,2.34896 2.27787,-0.0233 7.22067,-1.09994 10.98399,-2.39241 z M 869.83075,482.38968 c 5.26635,1.10932 -0.72607,4.8182 1.11356,-5.71589 0.39141,-2.24128 -1.16689,-3.0972 -0.40388,-3.56876 0.60084,-0.37135 0.88538,-2.08438 0.6323,-3.80675 -0.25308,-1.72237 6e-5,-4.14225 0.56255,-5.37752 0.79332,-1.74221 0.641,-2.6677 -0.67915,-4.12644 -1.42635,-1.57611 -1.46971,-1.96958 -0.26788,-2.43077 1.03786,-0.39827 1.53645,-2.80705 1.80498,-8.7203 0.40477,-8.9131 -0.10512,-8.07322 9.31232,-15.33902 10.68531,-8.24399 -8.50093,-3.21786 -20.66323,5.41304 -9.59819,6.81131 -19.55358,14.64408 -23.09064,18.16741 -0.98392,0.98011 -2.33392,1.79031 -3,1.80045 -0.66607,0.0101 -5.01419,0.69091 -9.66249,1.51284 -7.61025,1.34567 -8.60557,1.33908 -10,-0.0661 -1.39916,-1.41 -1.30737,-1.75326 0.95145,-3.55802 3.47623,-2.77746 6.43271,-3.86822 8.80395,-3.24813 2.74447,0.7177 14.56092,-5.0114 20.48385,-9.93142 2.63329,-2.1874 6.16367,-5.97685 7.84529,-8.421 2.44061,-3.5473 4.58196,-5.13863 10.6134,-7.88724 6.6819,-3.04504 15.3237,-9.48766 17.52532,-13.06544 0.4245,-0.68984 1.23991,-4.98736 1.81202,-9.55005 0.57211,-4.56269 1.9123,-10.26731 2.97819,-12.67694 1.06589,-2.40962 1.93798,-5.02925 1.93798,-5.8214 0,-1.7312 -0.93945,-1.48504 -14,3.66831 -10.94415,4.31828 -27.89271,9.76591 -33,10.6069 -1.925,0.31699 -7.68773,1.97312 -12.80606,3.68031 -8.71762,2.90771 -9.4764,3.00597 -12,1.55404 -1.48167,-0.85247 -3.2152,-1.36084 -3.8523,-1.12971 -0.6371,0.23113 -1.45892,-0.0661 -1.82628,-0.66049 -0.82682,-1.33782 3.34206,-4.94632 5.76676,-4.99158 3.18575,-0.0595 8.71788,-2.89169 8.71788,-4.46319 0,-0.84619 1.23103,-1.82445 2.75,-2.18534 1.5125,-0.35935 3.43594,-1.24575 4.2743,-1.96978 1.33906,-1.15645 4.92044,-2.03294 16.4757,-4.03219 1.65,-0.28548 3.9,-0.91489 5,-1.3987 1.1,-0.48381 4.025,-1.09563 6.5,-1.35962 3.90777,-0.4168 19.15031,-4.25915 29.9934,-7.56075 1.92137,-0.58503 5.49801,-1.0637 7.9481,-1.0637 2.45009,0 8.07806,-0.5082 12.5066,-1.12934 7.1516,-1.00307 9.33774,-0.88023 19.5519,1.09864 16.03375,3.10636 22.01985,3.61662 23.04119,1.96406 0.52341,-0.84691 2.38128,-1.24044 5.09901,-1.08009 6.02889,0.35574 11.8598,-0.7893 11.8598,-2.32896 0,-0.71494 -1.575,-3.58953 -3.5,-6.38799 -3.8324,-5.57133 -4.25355,-8.39707 -2.04079,-13.69294 0.80257,-1.92082 1.21767,-4.12185 0.92244,-4.89119 -0.30181,-0.78651 0.37264,-1.88551 1.54079,-2.51068 1.34376,-0.71916 2.07756,-2.1005 2.07756,-3.91091 0,-2.771 6.60604,-13.34849 9.88694,-15.83082 0.88718,-0.67124 4.42556,-2.57864 7.86306,-4.23866 6.41598,-3.09838 7.22259,-4.24091 4.92944,-6.98238 -2.19599,-2.62531 -3.65466,-8.85824 -2.32489,-9.93424 1.1949,-0.96687 10.07465,-4.1445 11.58161,-4.1445 1.2211,0 5.1978,6.97415 4.5627,8.00183 -0.2884,0.46657 0.01,2.01147 0.6534,3.43313 1.025,2.24959 0.8744,2.90777 -1.1616,5.07493 -1.2866,1.36956 -2.9359,2.49011 -3.665,2.49011 -1.5549,0 -1.5253,-0.11301 -1.85466,7.08895 -0.1778,3.88925 -1.2232,7.53868 -3.43743,12 l -3.18189,6.41105 2.09684,1.5 c 1.15326,0.825 3.72448,2.73826 5.71374,4.25169 5.6757,4.31793 10.3622,5.35577 15.2869,3.38531 2.2502,-0.90035 5.5447,-1.64389 7.321,-1.65231 4.7305,-0.0224 6.2271,-1.21551 4.6641,-3.71821 -0.6874,-1.10085 -0.968,-2.73616 -0.6235,-3.63401 0.5188,-1.35196 2.2642,-1.63247 10.1578,-1.63247 8.8647,0 9.5314,-0.13989 9.5314,-2 0,-1.9724 0.569,-2.2 5.5,-2.2 1.375,0 3.436,0.045 4.58,0.1 3.1236,0.15017 15.2498,13.03179 25.8192,27.42766 4.3891,5.97817 4.7381,8.1612 1.8942,11.85011 -1.1992,1.5556 -3.8706,2.20299 -7.976,1.93292 -0.9254,-0.0609 -1.9425,-0.92952 -2.2602,-1.93031 -0.6901,-2.17441 -6.5999,-5.18038 -10.1847,-5.18038 -1.6642,0 -2.7317,-0.65769 -3.0513,-1.87976 -0.7519,-2.87529 -13.7457,-4.86399 -13.8533,-2.12024 -0.032,0.825 -0.5761,1.39575 -1.2083,1.26834 -0.6323,-0.12741 -2.1647,1.22259 -3.4055,3 -1.2408,1.77741 -4.6051,6.02796 -7.4763,9.44567 -2.8711,3.41771 -5.445,7.01771 -5.7197,8 -0.4128,1.47554 -1.826,15.41498 -1.8278,18.02806 -8e-4,1.18877 18.1484,7.99261 23.324,8.74377 3.4955,0.50732 5.947,1.77896 9.8465,5.10751 2.8557,2.43759 8.3158,6.28769 12.1335,8.55577 3.8178,2.26807 7.3666,4.91839 7.8864,5.88959 0.5198,0.97119 3.2172,3.43374 5.9943,5.47233 4.0547,2.97636 4.8219,3.98058 3.8947,5.09774 -1.2666,1.52621 -5.6623,1.83478 -7.7021,0.54067 -0.7108,-0.45095 -1.6411,-2.13156 -2.0673,-3.73468 -0.5104,-1.91974 -1.5208,-3.02395 -2.9598,-3.23461 -1.2017,-0.17591 -2.632,-1.15523 -3.1784,-2.17626 -1.0986,-2.05277 -7.9258,-6.90399 -14.2732,-10.1422 -7.8831,-4.02165 -32.7289,-7.69569 -32.7289,-4.83974 0,2.03644 5.7365,13.60918 9.1629,18.48511 1.9297,2.74611 4.0652,6.40256 4.7455,8.12545 0.6803,1.72289 2.5542,4.39458 4.1643,5.93709 1.61,1.54252 2.9273,3.31415 2.9273,3.93698 0,0.62282 2.4172,3.68863 5.3716,6.81291 3.9122,4.13715 6.0943,5.6805 8.0314,5.6805 1.6259,0 2.9052,0.68021 3.2911,1.75 0.3472,0.9625 1.5099,3.01722 2.5837,4.56604 4.8602,4.26032 4.8389,6.23235 4.8389,6.23235 -2.7775,0.0651 -6.1973,-1.06778 -6.7846,-0.48041 -0.7377,0.73768 -2.8871,0.76879 -6.95,0.10061 l -2.2013,-6.66863 c -0.3953,-2.47764 -2.8969,-4.49158 -5.6219,-4.52602 -1.5587,-0.0197 -2.7878,-1.63138 -5.0589,-6.63349 -1.65,-3.63411 -3.7875,-7.10565 -4.75,-7.71453 -0.9625,-0.60888 -1.75,-1.58553 -1.75,-2.17034 0,-0.58481 -1.6144,-2.61406 -3.5876,-4.50945 -1.9732,-1.89539 -4.4031,-5.02738 -5.3999,-6.95998 -2.2504,-4.36364 -14.0905,-17.66905 -18.5408,-20.83549 -3.0878,-2.19695 -3.6573,-2.27506 -8.6387,-1.18463 -2.9332,0.64206 -12.30796,1.40535 -20.83296,1.69619 -16.95553,0.57845 -25.16383,-0.66443 -41,-6.20811 -7.66284,-2.68248 -22.32214,-4.34307 -27.30331,-3.09287 -1.49807,0.37599 -3.52694,2.33306 -5.06225,4.8831 -1.40921,2.34059 -4.23648,5.38062 -6.28282,6.75562 -2.04634,1.375 -6.0001,4.8227 -8.78612,7.66156 -2.78603,2.83886 -6.49252,5.86957 -8.23666,6.73491 -1.74414,0.86534 -4.13424,2.92587 -5.31133,4.57894 -2.53389,3.55851 -3.88304,10.02459 -2.09165,10.02459 0.82098,0 0.72643,0.65834 -0.30631,2.13279 -1.07968,1.54146 -1.33029,3.55156 -0.90388,7.25 0.62741,5.44179 1.4817,6.57744 4.96624,6.6019 1.32378,0.009 3.06454,1.2935 4.42616,3.26531 1.23434,1.7875 1.09353,5.475 1.31671,5.75" />
</g>
<g
id="layer14"
style="display:inline">
<rect
style="display:inline;opacity:0.38000039;fill:none;stroke:#000000;stroke-width:1.00782073;stroke-opacity:1"
id="frame07"
width="358.99219"
height="238.99217"
x="1144.5039"
y="272.50391" />
<path
id="horse07"
style="display:inline;opacity:1;fill:#000000"
d="m 1367.9032,364.605 c 4.9294,-1.85926 9.1231,-3.86193 9.3192,-4.45038 0.5798,-1.73947 -13.8045,-7.34569 -21.9625,-8.55977 l -4.6807,-0.69658 -2.0693,4.678 c -2.1094,4.76856 -2.5472,8.01481 -1.4623,10.84197 1.0963,2.8569 10.6837,2.02335 20.8556,-1.81324 z m 30.0363,120.85921 c -10.2267,-0.18907 -15.6251,-1.00869 -12.1856,-3.15799 l -0.6733,-2.4031 c -0.3704,-1.3217 -1.1414,-6.00309 -1.7135,-10.40309 -0.5721,-4.4 -1.7173,-9.039 -2.545,-10.30888 -0.907,-1.39176 -2.112,-7.9458 -3.0335,-16.5 -0.8407,-7.80512 -1.8989,-14.5795 -2.3514,-15.05418 -0.4525,-0.47468 -7.2743,-1.02393 -15.1597,-1.22056 -30.5321,-0.76133 -45.3027,-3.43419 -59.3369,-10.73751 -5.9231,-3.08233 -17.1703,-2.64555 -23.9871,0.93151 -2.7571,1.44677 -7.7129,3.97774 -11.0129,5.62438 -3.3,1.64664 -8.0361,4.89064 -10.5247,7.20888 -2.4886,2.31824 -5.8636,5.05966 -7.5,6.09204 -5.7703,3.64037 -14.6113,11.80213 -17.7174,16.35623 -5.7136,8.3773 -11.1845,14.07684 -16.9086,17.61515 -6.0929,3.76624 -10.5088,4.65392 -9.452,1.90004 0.3362,-0.8761 0.8831,-2.6761 1.2154,-4 0.4672,-1.86159 1.272,-2.4071 3.5511,-2.4071 2.27,0 4.2551,-1.33323 8.6416,-5.80394 5.8924,-6.00554 14.4915,-18.04359 15.6413,-21.89641 0.3611,-1.21019 2.2083,-3.15939 4.1049,-4.33156 7.4656,-4.61398 2.3359,-5.1218 -11.1249,-1.10132 -3.8903,1.16196 -10.8653,4.45261 -15.5,7.31256 -8.4108,5.19009 -8.4451,5.20066 -18.1767,5.60399 -10.6934,0.4432 -11.9706,-0.3485 -7.4355,-4.60901 2.5306,-2.3774 5.6453,-2.81454 7.4186,-1.04119 2.2604,2.26033 21.0077,-6.68031 30.9724,-14.77081 3.8223,-3.10337 6.4795,-4.41278 10,-4.92778 8.9347,-1.30702 17.7272,-6.7699 18.6691,-11.5993 0.2505,-1.28438 0.8942,-6.0851 1.4305,-10.66827 0.8086,-6.90983 1.5267,-9.10113 4.2048,-12.83024 4.33,-6.02941 2.8921,-7.64138 -3.4834,-3.90509 -2.5333,1.48459 -6.1052,4.01559 -7.9376,5.62444 -3.6243,3.18219 -14.7113,8.93004 -21.0889,10.93312 -2.2,0.69097 -4.9,1.72793 -6,2.30433 -3.2027,1.67826 -21.7826,2.13202 -28.5442,0.69711 -5.1291,-1.08848 -5.9152,-1.54334 -5.4112,-3.13127 0.4324,-1.36215 -0.095,-2.11821 -1.9775,-2.83383 -1.4119,-0.53682 -2.5671,-1.34717 -2.5671,-1.80078 0,-1.50078 2.368,-3.22452 4.45,-3.2393 1.1275,-0.008 4.075,-0.73259 6.55,-1.61018 2.7118,-0.96155 8.4738,-1.68897 14.5,-1.83052 20.0908,-0.47194 25.4372,-1.58137 39,-8.09298 7.8518,-3.76968 14.7222,-4.78349 33,-4.86957 14.0773,-0.0663 19.1931,0.33807 29.7559,2.35193 12.3106,2.34708 12.8026,2.36807 14.0944,0.60147 1.0034,-1.37222 2.0298,-1.65703 4.0994,-1.13758 3.6841,0.92465 11.5503,-0.31789 11.5503,-1.82447 0,-0.65965 -1.3173,-2.46142 -2.9273,-4.00394 -4.8031,-4.60166 -5.6362,-7.75964 -3.2344,-12.26088 4.1883,-7.84926 5.3777,-11.31187 4.7478,-13.82162 -0.7594,-3.02568 0.3694,-5.35635 5.8057,-11.98711 5.6902,-6.94053 5.5525,-6.82286 10.8989,-9.31521 5.5569,-2.5905 6.5039,-4.21219 4.2985,-7.36092 -0.8741,-1.24788 -1.5892,-3.7322 -1.5892,-5.5207 0,-2.58955 0.6009,-3.56253 2.9503,-4.77749 1.6227,-0.83912 4.5417,-1.52568 6.4866,-1.52568 3.1189,0 3.7149,0.42747 5.0497,3.62212 0.8324,1.99217 1.5134,5.05732 1.5134,6.81144 0,3.32696 -3.0435,7.56644 -5.432,7.56644 -1.6259,0 -2.568,2.17366 -2.568,5.92524 0,1.51891 -0.8805,5.321 -1.9568,8.44909 -1.0762,3.12809 -1.7122,6.23604 -1.4134,6.90655 0.5425,1.217 6.4056,6.24004 13.7577,11.78641 3.3151,2.50091 4.7889,2.93271 10.0095,2.93271 4.8847,0 6.3566,-0.37579 7.2832,-1.85952 0.6645,-1.06401 2.8818,-2.13464 5.1832,-2.50264 5.173,-0.8272 5.6639,-1.7768 2.6179,-5.06356 -1.3647,-1.47253 -2.4813,-3.10414 -2.4813,-3.6258 0,-1.43278 5.4139,-1.14154 13.0526,0.70214 6.4223,1.55011 6.999,1.54557 9.4715,-0.0744 1.5536,-1.01794 2.4085,-2.30941 2.0857,-3.15062 -0.3879,-1.0109 0.2163,-1.42556 2.0772,-1.42556 2.2508,0 5.1264,1.67671 11.096,6.46984 0.7057,0.56659 4.0556,4.63016 7.4443,9.03016 3.3887,4.4 8.3641,10.5562 11.0565,13.68044 5.0953,5.91272 5.4656,7.92734 2.0793,11.31364 -1.9815,1.98151 -7.0258,1.93107 -8.1521,-0.0815 -1.0672,-1.90703 -11.6957,-6.3952 -15.211,-6.42324 -1.8137,-0.0145 -2.1217,-0.25956 -1.1219,-0.89283 2.5818,-1.6353 0.016,-3.09649 -5.4371,-3.09649 -4.1698,0 -5.441,0.35046 -5.441,1.5 0,0.825 -0.8216,1.5 -1.8257,1.5 -2.0682,0 -4.4602,2.47537 -8.6966,9 -1.607,2.475 -3.9636,5.79182 -5.2368,7.37072 -4.3156,5.35172 -5.3378,9.10319 -3.7255,13.67295 0.7813,2.2145 1.1967,5.24811 0.923,6.74135 -0.4357,2.377 0.1535,3.15069 4.7326,6.21498 2.8766,1.925 7.5024,5.34535 10.2796,7.60077 2.7772,2.25543 7.6534,5.63043 10.8361,7.5 3.1827,1.86958 7.4577,4.40104 9.5,5.62548 8.4524,5.06748 16.0891,7.2454 25.4633,7.26188 7.1488,0.0126 8.2921,0.95533 4.3171,3.55989 -1.9861,1.3013 -2.8483,1.37187 -4.6937,0.38421 -1.2434,-0.66546 -4.9508,-1.17178 -8.2387,-1.12516 -4.2299,0.06 -6.7318,-0.43946 -8.5563,-1.70805 -3.194,-2.22083 -13.8816,-7.09902 -15.5532,-7.09902 -0.6782,0 -5.6863,-2.05413 -11.1291,-4.56474 -5.4429,-2.51061 -11.2461,-5.16478 -12.8961,-5.89816 -4.3004,-1.9114 -14.0667,-3.91733 -15.8119,-3.24765 -2.847,1.09247 -4.0955,13.67609 -2.9571,29.80308 1.2728,18.03118 3.3523,22.90747 9.769,22.90747 2.0018,0 3.8996,0.79828 5.095,2.14318 1.0478,1.17875 3.17,2.92306 4.7161,3.87626 l 2.8111,1.73308 -2.6791,0.67241 c -1.4735,0.36982 -2.919,0.4325 -3.2122,0.13928 -0.2932,-0.29322 -1.0276,0.0993 -1.632,0.87223 -0.9355,1.19642 -1.3964,1.20055 -3.1,0.0277 z" />
</g>
<g
id="layer15"
style="display:inline">
<rect
style="display:inline;opacity:0.38000039;fill:none;stroke:#000000;stroke-width:1.00782073;stroke-opacity:1"
id="frame08"
width="358.99219"
height="238.99217"
x="26.003906"
y="516.50391" />
<path
id="horse08"
style="display:inline;opacity:1;fill:#000000"
d="m 239.64142,608.9006 c 2.91457,-0.60468 6.29589,-1.72968 7.51404,-2.5 1.21815,-0.77031 3.32909,-1.40057 4.69098,-1.40057 4.70864,0 4.17486,-2.65512 -1.07435,-5.34403 -3.75292,-1.92243 -12.71105,-5.20631 -16.56024,-6.07067 -2.37653,-0.53366 -3.05425,-0.0972 -5.25,3.3811 -2.73251,4.32858 -3.05363,6.50304 -1.54596,10.4685 1.12158,2.94999 3.6247,3.25008 12.22553,1.46567 z m 69.79922,3.59943 c -1.33903,-1.61344 -3.91365,-1.86727 -8.875,-0.875 -5.35284,1.07057 -3.43192,2.375 3.49744,2.375 5.77324,0 6.46281,-0.19235 5.37756,-1.5 z m -196.5651,55.52475 c 3.64908,-1.38738 3.21351,-3.21414 -0.67671,-2.83811 -2.13505,0.20638 -3.35499,0.91081 -3.57332,2.06336 -0.3773,1.99169 0.58692,2.16746 4.25003,0.77475 z m 110.89843,60.41242 c -3.84234,-1.30717 -4.5774,-0.31194 -4.5774,-0.31194 1.1616,-1.8795 0.32492,-8.04616 -3.02901,-8.9399 -3.07249,-0.81875 -3.21319,-1.0671 -2.94002,-5.18935 0.16957,-2.5589 0.94798,-4.81285 1.9034,-5.51147 1.64092,-1.19987 3.32952,-4.00801 6.65504,-11.06729 1.88083,-3.99255 2.81251,-5.80085 9.08969,-17.64226 1.96073,-3.69877 3.56497,-6.9724 3.56497,-7.27475 0,-1.26652 -5.10706,-2.29844 -14.45009,-2.91975 -14.91083,-0.99155 -24.30026,-3.65596 -36.82245,-10.44898 -4.7184,-2.55963 -6.91478,-3.13148 -12.02749,-3.13148 -6.58188,0 -8.59793,0.87003 -14.24279,6.14648 -2.61884,2.44793 -4.4999,3.05357 -13.5,4.3466 -6.33725,0.91045 -12.42709,2.45451 -15.45718,3.9191 -16.84398,8.14153 -22.19984,10.58782 -23.18081,10.58782 -0.60688,0 -5.089463,2.51665 -9.961304,5.59256 l -8.857889,5.59257 -7.308532,-0.63957 c -4.019693,-0.35176 -8.466582,-1.07986 -9.881977,-1.61799 -2.480234,-0.94298 -2.509557,-1.04902 -0.809584,-2.92747 0.970123,-1.07197 2.717013,-2.2471 3.881977,-2.6114 1.164964,-0.3643 3.388221,-1.72417 4.940571,-3.02194 2.281019,-1.90693 3.207183,-2.15367 4.828,-1.28624 1.515282,0.81096 2.817896,0.68785 5.328674,-0.50359 1.827721,-0.86731 3.771801,-1.57693 4.320178,-1.57693 1.47134,0 10.343266,-10.43951 12.999616,-15.29653 4.9181,-8.99252 4.9423,-9.0127 10.079,-8.40433 2.56616,0.30392 7.46842,0.29845 10.89391,-0.0122 l 6.22817,-0.56472 0,-9.69163 c 0,-8.35268 0.34481,-10.37129 2.49581,-14.61111 3.12712,-6.16383 3.11579,-6.41948 -0.28437,-6.41948 -3.62002,0 -8.71683,2.64158 -14.81664,7.67919 -9.72394,8.03065 -20.335923,11.74437 -31.892082,11.16081 -6.732665,-0.33998 -7.663493,-0.65 -10.205545,-3.39907 -1.538447,-1.66373 -5.384676,-5.19822 -8.547176,-7.85442 -3.1625,-2.6562 -5.747155,-5.11229 -5.743677,-5.45798 0.0035,-0.34569 1.348652,-1.39233 2.989277,-2.32587 l 2.982955,-1.69733 2.629411,3.44733 c 2.879576,3.77532 5.950279,4.43374 7.946414,1.70386 1.212206,-1.65779 1.610821,-1.65738 8.110243,0.008 11.211534,2.87347 13.62955,2.48498 25.92574,-4.16531 10.28773,-5.56404 11.56521,-5.98851 22.40964,-7.44612 22.84666,-3.07085 28.23411,-3.03074 43.22883,0.32187 13.89719,3.10721 22.77117,3.8652 22.77117,1.94505 0,-0.73324 2.08122,-0.85672 6.48721,-0.38488 8.29804,0.88865 9.02153,-0.43084 4.03897,-7.3662 -3.58459,-4.98949 -3.60037,-5.056 -2.06916,-8.72071 0.84864,-2.03108 1.54298,-4.70781 1.54298,-5.9483 0,-1.24049 0.69217,-2.82988 1.53816,-3.53199 1.16501,-0.96687 1.3792,-2.33663 0.88288,-5.64627 -0.55003,-3.66791 -0.2467,-4.98712 1.88867,-8.21387 3.75315,-5.6714 9.56333,-10.87565 14.94029,-13.3822 4.38079,-2.04217 5.87145,-4.2712 4.06466,-6.07799 -0.82488,-0.82489 -3.27841,-7.70014 -3.2996,-9.24613 -0.0228,-1.66254 7.29016,-4.60962 10.50475,-4.23335 5.11511,0.59872 8.10146,9.17907 5.31967,15.28443 -0.66696,1.46382 -1.99111,2.54705 -3.11354,2.54705 -1.73156,0 -1.88062,0.48284 -1.3145,4.25804 0.40401,2.69411 0.0824,6.09153 -0.87563,9.25 -2.58382,8.51846 -2.10409,10.45971 3.70488,14.99196 2.81973,2.2 6.7316,4.7757 8.69305,5.72378 3.88593,1.87829 12.08225,2.36023 13.64042,0.80206 0.53579,-0.53579 2.76329,-1.5952 4.95,-2.35426 3.36015,-1.16638 3.92929,-1.76504 3.67523,-3.86591 -0.20018,-1.65533 0.68556,-3.54151 2.65121,-5.64574 2.55778,-2.7381 3.62459,-3.15993 7.99159,-3.15993 2.77188,0 5.31789,-0.45 5.65781,-1 0.79736,-1.29015 8.59866,-1.29319 11.98774,-0.005 4.31063,1.6389 10.26022,6.98067 15.06673,13.5275 2.48976,3.39125 6.99879,8.30003 10.02005,10.9084 7.44973,6.43163 8.81226,8.62577 7.34974,11.83566 -1.08154,2.37371 -4.64914,4.7331 -7.15686,4.7331 -0.62617,0 -2.0675,-0.81568 -3.20295,-1.81263 -4.07326,-3.57641 -12.19633,-5.11748 -23.0483,-4.37263 l -9.98386,0.68526 -2.47102,4.48557 c -1.35906,2.46706 -5.52882,8.70735 -9.26614,13.86731 -3.73732,5.15995 -6.84886,10.11645 -6.91454,11.01443 -0.0657,0.89798 -0.0288,4.33269 0.0819,7.63269 0.18704,5.57441 0.50379,6.31919 4.46556,10.5 2.34533,2.475 6.32336,7.2 8.84006,10.5 6.20506,8.13633 24.13497,26.24183 30.00613,30.29999 3.17515,2.19467 6.44088,3.49737 9.75,3.88929 5.77086,0.68347 6.33492,2.14657 2.27731,5.90703 -3.49972,3.24343 -8.63921,3.04706 -9.12142,-0.3485 -0.368,-2.59132 -2.14785,-3.70795 -7.43016,-4.6615 -2.3653,-0.42624 -3.74997,-1.22993 -3.74997,-2.17584 0,-1.72246 -12.16458,-14.40973 -13.81607,-14.40973 -0.60233,0 -5.05262,-3.82586 -9.88954,-8.50191 -6.2989,-6.08942 -11.08015,-9.68288 -16.84967,-12.66376 l -8.05528,-4.16184 -6.79259,1.83867 c -5.79596,1.56889 -7.12597,2.36322 -9.06467,5.41375 -1.24965,1.9663 -4.8056,6.4046 -7.90213,9.86289 -3.09653,3.45829 -5.63005,6.67179 -5.63005,7.14112 0,0.46932 -1.82605,3.03981 -4.05789,5.7122 -3.83668,4.59401 -8.94211,13.79559 -8.94211,16.11648 0,1.37259 5.77006,6.2424 7.39639,6.2424 0.68362,0 2.22111,1.125 3.41666,2.5 2.51651,2.89423 3.11201,5.33983 5.74299,3.41601 3.03584,4.42047 -4.00663,2.72889 -7.88937,2.41223 -0.44829,-0.77148 -3.50834,0.57223 -4.33334,0.10893 z" />
</g>
<g
id="layer16"
style="display:inline">
<rect
style="display:inline;opacity:0.38000039;fill:none;stroke:#000000;stroke-width:1.00782073;stroke-opacity:1"
id="frame09"
width="358.99219"
height="238.99217"
x="397.50391"
y="516.50391" />
<path
id="horse09"
style="display:inline;opacity:1;fill:#000000"
d="m 623.19064,609.75452 c 4.9337,-2.61319 5.20672,-3.29755 1.66968,-4.18529 -1.41918,-0.3562 -5.40026,-1.97998 -8.84685,-3.60841 -3.44658,-1.62844 -6.95419,-2.96079 -7.79467,-2.96079 -2.79633,0 -3.16028,8.36431 -0.51128,11.75 1.6495,2.10823 10.72494,1.52472 15.48312,-0.99551 z m 55.5,3.60579 c 3.10451,-0.87823 1.86777,-2.11553 -2.81674,-2.81802 -4.65424,-0.69794 -9.43326,1.11301 -9.43326,3.57463 0,1.01098 7.67799,0.53675 12.25,-0.75661 z m -204.75,16.63972 c -0.33992,-0.55 -1.26648,-1 -2.05902,-1 -0.79254,0 -1.44098,0.45 -1.44098,1 0,0.55 0.92656,1 2.05902,1 1.13246,0 1.7809,-0.45 1.44098,-1 z m 153.68171,94.6914 -0.61333,-3.0957 c -0.65429,-3.30252 -1.17661,-6.77926 -1.93772,-12.89824 -0.26014,-2.0914 -0.9625,-4.39238 -1.56081,-5.11329 -0.5983,-0.72091 -1.29715,-5.58739 -1.553,-10.81439 -0.25584,-5.22701 -0.92114,-10.70295 -1.47845,-12.16877 l -1.01328,-2.66513 -6.76256,7.09974 c -6.20871,6.51827 -11.16495,13.83213 -11.23439,16.57846 -0.0155,0.61274 -1.94067,1.404 -4.27817,1.75837 -2.3375,0.35436 -7.85,1.30667 -12.25,2.11625 -12.7177,2.33998 -27.7965,1.78698 -28.88878,-1.05947 -0.5762,-1.50154 5.13645,-5.42923 7.89657,-5.42923 0.97445,0 2.27133,0.6284 2.88197,1.39644 1.46297,1.84008 18.40145,0.53212 23.94856,-1.84928 3.33965,-1.43373 4.28351,-2.64812 7.26505,-9.34748 1.88471,-4.23482 4.31996,-9.36383 5.41168,-11.3978 3.76668,-7.01763 3.79359,-7.00141 -14.5443,-8.76842 -11.08921,-1.06854 -15.73235,-2.4383 -25.66903,-7.57251 -7.06408,-3.64995 -12.74139,-4.44349 -14.72145,-2.05766 -1.8971,2.28586 -11.36684,6.51318 -16.97131,7.57605 -2.86507,0.54334 -8.59448,0.9531 -12.73204,0.91057 -4.13755,-0.0425 -7.77489,0.17473 -8.08297,0.4828 -0.30807,0.30808 1.07961,4.37709 3.08374,9.04224 l 3.64387,8.4821 -2.09035,4.30148 c -3.37862,6.95244 -3.48646,7.11978 -5.30661,8.23464 -4.21763,2.58334 -5.68984,-6.26502 -1.54458,-9.28333 1.52705,-1.1119 1.74299,-2.16198 1.22369,-5.95071 -0.6676,-4.87069 -1.23365,-6.18147 -5.59188,-12.94913 -2.15361,-3.34422 -3.33647,-4.25 -5.55006,-4.25 -3.53305,0 -5.88553,2.53908 -10.65485,11.5 -4.2282,7.94424 -6.68742,10.5 -10.10335,10.5 -1.30618,0 -4.4037,0.54263 -6.88338,1.20584 -5.76655,1.54232 -7.63154,0.23926 -5.46134,-3.81581 1.94676,-3.63754 5.48007,-5.15907 8.13301,-3.50228 1.80495,1.12721 2.43339,0.89857 5.37994,-1.95734 1.83495,-1.7785 5.84039,-8.30573 8.90098,-14.50494 3.06059,-6.19922 6.11878,-11.46417 6.79597,-11.6999 0.67719,-0.23573 6.06875,-0.20669 11.98125,0.0645 11.97386,0.54927 11.98149,0.54415 8.72082,-5.84729 -3.33306,-6.53335 -4.20785,-13.30994 -2.32548,-18.01446 0.88276,-2.20623 1.35208,-4.26427 1.04292,-4.57342 -0.30915,-0.30915 -3.85298,1.91005 -7.87518,4.93157 -10.91746,8.20131 -19.51454,12.56141 -27.95078,14.17553 -9.50213,1.81806 -15.70557,1.08041 -16.87945,-2.00713 -0.47272,-1.24334 -1.33724,-2.55589 -1.92117,-2.91678 -0.58392,-0.36085 -1.06168,-1.82369 -1.06168,-3.25072 0,-1.74489 -1.30995,-3.80393 -4,-6.28737 -4.41686,-4.07763 -5.21227,-7 -1.90524,-7 1.15212,0 5.19122,0.94052 8.97578,2.09004 9.51074,2.8888 20.86393,1.86046 33.43994,-3.02891 3.29423,-1.28075 6.88952,-2.65379 7.98952,-3.0512 3.54078,-1.27921 29.78961,-6.01634 36.5,-6.58715 3.575,-0.3041 8.75,-0.0642 11.5,0.53316 12.64419,2.74649 27.98661,4.95745 28.79456,4.1495 0.50627,-0.50627 0.41822,-1.16492 -0.20743,-1.55159 -2.59713,-1.60512 -0.91818,-2.75662 3.16287,-2.16924 2.3375,0.33644 4.7,0.27504 5.25,-0.13645 0.55,-0.41149 1.03639,-4.57316 1.08087,-9.24816 0.0445,-4.675 0.75383,-11.2 1.57633,-14.5 2.32474,-9.32713 5.09637,-13.05199 17.2628,-23.19995 l 2.63753,-2.19996 -2.02876,-3.78524 c -3.92545,-7.32403 -2.4175,-10.53565 5.81904,-12.39329 4.4363,-1.00055 5.64599,-0.44468 8.1061,3.7249 3.28342,5.56498 2.15113,13.5698 -2.07581,14.67517 -1.29969,0.33987 -1.8781,1.39568 -1.8781,3.4282 0,1.61539 -0.9,5.55296 -2,8.75017 -3.47935,10.11289 -2.68512,12.1334 7.07546,18 1.83013,1.1 4.24934,2.55587 5.37603,3.23526 3.81812,2.30234 9.8618,1.53854 14.64847,-1.85126 5.9084,-4.18419 7.052,-5.73154 5.86928,-7.94147 -1.1777,-2.20056 0.25895,-2.86916 4.70587,-2.19004 2.39609,0.36592 4.16964,-0.21895 7.22864,-2.3838 2.22945,-1.57778 4.06316,-3.65619 4.0749,-4.61869 0.0318,-2.60369 2.46377,-2.15206 10.14403,1.8838 4.46495,2.34627 8.36566,5.3663 11.00894,8.52341 2.2516,2.68928 7.68206,7.66545 12.06771,11.05814 7.44143,5.75664 7.93393,6.36837 7.3754,9.16098 -1.34419,6.72099 -5.43813,8.12155 -13.00038,4.44753 -4.4776,-2.17539 -4.48272,-2.17553 -14.77675,-0.40658 -12.88359,2.21394 -14.58946,2.89335 -15.86946,6.32043 -2.38274,6.37956 -5.3549,11.54124 -9.96991,17.31454 -2.9896,3.73994 -5.14521,7.55974 -5.52489,9.79023 -1.39533,8.19705 -2.67525,10.90855 -7.8057,16.53626 -7.33136,8.04195 -9.09892,15.41807 -8.42889,35.17427 l 0.46822,13.8056 3.37874,2.82069 c 1.85831,1.55139 4.55886,2.8207 6.00122,2.8207 1.65955,0 3.94811,2.78036 5.6583,4.69975" />
</g>
<g
id="layer17"
style="display:inline">
<rect
style="display:inline;opacity:0.38000039;fill:none;stroke:#000000;stroke-width:1.00782073;stroke-opacity:1"
id="frame10"
width="358.99219"
height="238.99217"
x="771.00391"
y="517.00391" />
<path
id="horse10"
style="display:inline;opacity:1;fill:#000000"
d="m 990.58485,607.25003 c 2.08969,-0.9625 3.68933,-2.11836 3.55476,-2.56857 -0.18664,-0.62437 -13.2166,-6.68143 -14.37312,-6.68143 -0.12751,0 -0.69404,1.67395 -1.25895,3.71989 -1.18312,4.28491 -0.60365,5.17529 4.09045,6.2851 1.83846,0.43466 3.53272,0.83635 3.76504,0.89265 0.23231,0.0563 2.13213,-0.68514 4.22182,-1.64764 z m 55.11935,0.32144 c 4.6672,-1.95005 4.6735,-1.16598 -0.3902,-1.97569 -4.8716,-0.77901 -9.0566,-0.19159 -9.0566,3.08668 0,1.79374 0.7985,1.09952 3.3132,0.59657 1.6208,-0.32415 4.1794,-0.89103 6.1336,-1.70756 z m -146.9914,63.35576 c 2.05031,-1.69005 3.72784,-3.49005 3.72784,-4 0,-1.17817 -10.03494,-1.19107 -11.89172,-0.0153 -1.14453,0.72476 -0.99923,1.43249 0.8181,3.98468 1.21539,1.70687 2.52664,3.1034 2.91387,3.1034 0.38723,0 2.38159,-1.38276 4.43191,-3.0728 z m 91.22451,20.07816 C 990.72341,689.73345 986.48195,678 985.23606,678 c -0.51514,0 -3.26734,1.90638 -6.11601,4.2364 -2.84868,2.33001 -5.35604,4.34414 -5.57191,4.47583 -1.00824,0.61506 2.47241,3.39097 5.26826,4.20158 4.29478,1.24519 10.37698,1.29528 11.12091,0.0916 z m -50.85979,34.37682 c 5.38538,-0.51864 1.28749,-1.91499 2.36668,-4.23663 0.67638,-1.45509 1.61959,-3.4147 2.09603,-4.35469 0.47643,-0.93999 0.49345,-2.71683 0.0378,-3.94852 -0.71954,-1.94508 0.39997,-3.43243 8.51708,-11.31555 9.70783,-9.42792 11.23385,-12.44585 7.34553,-14.52682 -3.88565,-2.07954 -1.60556,-4.1616 6,-5.47887 2.67013,-0.46246 4.41189,-1.78851 7.34588,-5.5926 4.55136,-5.90108 4.28109,-7.91958 -1.0645,-7.95017 -5.25853,-0.0301 -19.14962,-3.21853 -30.02404,-6.89144 -12.40239,-4.189 -14.46589,-4.07039 -20.23456,1.16308 -2.57654,2.3375 -6.33571,5.50668 -8.3537,7.04263 -5.55965,4.2316 -4.98698,6.53289 2.58462,10.3863 3.43546,1.74842 7.88001,3.84048 9.87677,4.64903 2.86843,1.16153 4.14408,2.59327 6.07741,6.82107 1.34582,2.94303 2.73836,6.81347 3.09453,8.60097 0.61287,3.07576 0.49018,3.25 -2.28845,3.25 -4.2878,0 -7.1992,-3.49565 -6.41094,-7.69744 0.48235,-2.57116 0.27971,-3.30256 -0.915,-3.30256 -0.84401,0 -2.87644,-1.12911 -4.51651,-2.50914 -3.05044,-2.56678 -13.09918,-6.72261 -18.92151,-7.82533 -2.42632,-0.45953 -3.25,-0.25666 -3.25,0.80045 0,0.77879 0.45,1.6941 1,2.03402 1.25763,0.77726 1.33113,18.5 0.0767,18.5 -0.50781,0 -2.30781,-1.165 -4,-2.58889 -3.36356,-2.83025 -4.01046,-6.3913 -1.53435,-8.44628 1.07006,-0.88808 1.22318,-1.59927 0.5,-2.32245 -0.57331,-0.57331 -1.04406,-1.96488 -1.04612,-3.09238 -0.006,-3.10167 -3.01124,-7.42136 -10.86831,-15.62012 -9.62164,-10.04007 -9.56998,-11.9063 0.37205,-13.4405 6.13456,-0.94666 12.5,-3.50067 12.5,-5.01538 0,-0.74833 -0.99163,-2.05516 -2.20362,-2.90407 -1.21199,-0.84891 -3.4976,-3.46193 -5.07914,-5.8067 -2.93648,-4.35362 -3.0679,-6.25624 -1.01969,-14.76323 0.57998,-2.40886 0.531,-2.43729 -1.34347,-0.77994 -1.06997,0.94604 -4.84986,3.03947 -8.39974,4.65208 -3.54989,1.61261 -7.59474,3.83236 -8.98857,4.93279 -1.39382,1.10043 -5.66882,3.03003 -9.5,4.28801 -3.83117,1.25798 -8.87906,3.14222 -11.21752,4.1872 -3.81658,1.7055 -4.96805,1.77915 -11.25,0.71956 -6.61387,-1.11557 -8.28152,-2.08856 -5.99825,-3.4997 2.0803,-1.28569 0.84876,-3.64782 -3.5,-6.71311 -5.02157,-3.53953 -5.40449,-4.3171 -2.5,-5.07664 1.1,-0.28766 2,-1.22431 2,-2.08145 0,-0.85714 -0.9,-2.0401 -2,-2.6288 -3.24113,-1.7346 -2.37287,-2.71286 4.4117,-4.97062 4.86631,-1.6194 8.43484,-2.07791 14.80555,-1.90233 4.61661,0.12724 8.89248,-0.0768 9.50193,-0.45349 0.60945,-0.37666 4.16253,0.0235 7.89575,0.88933 5.69655,1.32111 7.84035,1.38036 13.33636,0.36854 8.02018,-1.47652 21.83296,-5.591 24.54871,-7.31245 1.1,-0.69727 4.90964,-2.07232 8.46587,-3.05568 7.21606,-1.99536 11.42225,-1.76535 26.94343,1.47333 12.18618,2.5428 14.77652,2.52862 15.6062,-0.0855 0.57018,-1.79648 1.18677,-1.96839 5.0058,-1.39569 l 4.35552,0.65315 -1.10138,-3.58866 c -0.81557,-2.65734 -0.7973,-4.60362 0.0704,-7.49964 0.64447,-2.15104 0.90791,-4.59857 0.58542,-5.43896 -0.35525,-0.92577 0.19574,-1.94653 1.39803,-2.58998 1.63106,-0.87292 1.88935,-1.77051 1.45064,-5.04134 -0.44236,-3.298 0.0111,-4.82839 2.64831,-8.93815 3.54054,-5.51746 9.63373,-11.47018 15.3218,-14.96859 4.28499,-2.63546 4.46914,-3.18251 1.86478,-5.53943 -2.08305,-1.88513 -3.39,-6.72308 -2.46641,-9.12992 C 980.02005,546.0477 984.91883,544 989.7922,544 c 4.04034,0 4.64448,0.32811 6.54966,3.55716 3.65228,6.19022 2.24438,13.26148 -3.21298,16.13688 -1.41583,0.74598 -1.86606,2.35877 -2.06028,7.38027 -0.13669,3.53413 -1.09428,9.08881 -2.12799,12.34373 l -1.87946,5.91803 2.41611,1.58197 c 1.32886,0.87008 3.88414,2.8616 5.6784,4.4256 6.29184,5.48439 14.90714,4.26122 16.50724,-2.34364 1.5119,-6.24095 3.0302,-8.01836 9.4787,-11.09593 3.4763,-1.65908 7.3714,-4.06737 8.6558,-5.35176 2.1602,-2.16018 2.7404,-2.2629 7.7392,-1.37011 6.437,1.14964 12.4491,4.46427 18.4098,10.14984 2.4033,2.29238 7.5134,6.86796 11.3559,10.16796 3.8424,3.3 7.2264,6.54982 7.5201,7.22182 0.9441,2.16094 -1.4052,6.96783 -3.9786,8.14034 -3.3752,1.53785 -5.4215,1.43122 -7.4309,-0.38721 -0.9268,-0.83878 -3.2123,-1.55479 -5.0787,-1.59114 -3.8253,-0.0745 -22.728,4.50497 -23.8776,5.78472 -0.4108,0.45731 -1.943,4.01865 -3.4049,7.91409 -1.4619,3.89544 -4.7113,10.19544 -7.2209,14 -6.1873,9.38004 -7.2114,11.48526 -8.4919,17.45621 -0.821,3.82815 -2.1801,6.26382 -5.3288,9.54997 -2.3247,2.42616 -5.0012,4.4112 -5.9477,4.4112 -0.9466,0 -3.0888,0.70727 -4.76046,1.57172 l -3.03935,1.57171 0.33167,12.17829 0.33166,12.17828 -3.50008,1.71648 c -3.35142,1.64357 -3.83955,1.62731 -11.49264,-0.38275 -13.40627,-3.52113 -13.99834,-3.51068 -17.5819,0.31026 -1.73113,1.84581 -4.89421,5.164 -7.02908,7.37376 -2.13487,2.20977 -3.88158,4.43514 -3.88158,4.94528 0,0.51014 -1.13184,2.10892 -2.5152,3.55283 l -2.5152,2.6253 2.2652,4.42942 c 2.41046,4.71347 3.6926,6.09232 4.94516,5.3182" />
</g>
<g
id="layer18"
style="display:inline">
<rect
style="display:inline;opacity:0.38000039;fill:none;stroke:#000000;stroke-width:1.00782073;stroke-opacity:1"
id="frame11"
width="358.99219"
height="238.99217"
x="1143.5039"
y="517.00391" />
<path
id="horse11"
style="display:inline;opacity:1;fill:#000000"
d="m 1259.8016,647.48209 c -5.0084,-9.88888 -6.3319,-11.48524 -3.9686,-4.78701 0.7776,2.20387 1.6273,6.28189 1.8883,9.06229 0.3299,3.51418 1.3502,6.20772 3.3469,8.83574 l 2.8724,3.78049 0.3136,-3.74058 c 0.241,-2.8748 -0.7896,-5.91866 -4.4526,-13.15093 z m 19.3947,75.43572 c 0.2256,-0.6869 -0.9155,-3.67642 -2.5358,-4.60634 -2.5011,-1.43546 -3.1001,-2.60593 -3.9664,-7.75111 -1.5771,-9.36658 -4.6441,-20.06033 -5.7535,-20.06033 -1.2648,0 -2.5282,13.53262 -1.8205,19.5 0.2935,2.475 1.0915,4.95 1.7734,5.5 0.6818,0.55 2.0087,2.48818 2.9486,4.30707 1.5189,2.93946 2.111,3.27294 5.3264,3 1.9896,-0.16889 3.8021,0.7976 4.0278,0.11071 z m -27.2557,1.75496 c 12.586,-0.54492 8.505,-3.13649 6.9186,-9.58707 -0.7955,-3.23471 -2.4503,-3.61918 -1.8065,-6.32672 0.8654,-3.63916 0.8128,-3.1153 2.1842,-21.7589 l 0.9931,-13.5 -5.432,-8.21063 c -9.3637,-14.15347 -12.3574,-22.74361 -12.3574,-35.45798 0,-10.82174 4.4932,-16.76638 14.5079,-19.19441 3.2956,-0.79903 10.3852,-2.61922 15.7546,-4.04488 5.3694,-1.42565 10.9251,-2.5921 12.3461,-2.5921 3.0025,0 11.3717,2.21486 19.7903,5.23734 l 5.8988,2.11785 2.3655,-2.74997 c 1.3009,-1.51248 2.0832,-3.20649 1.7384,-3.76446 -0.3449,-0.55797 0.165,-2.77096 1.1331,-4.91775 l 1.7601,-3.90325 -2.7875,-2.19271 -2.7876,-2.19272 0.5669,-10.74601 c 0.6291,-11.92551 1.411,-14.16346 5.7286,-16.39616 3.8739,-2.00331 4.7058,-5.56691 2.4613,-10.54431 -1.3565,-3.00814 -1.5534,-4.69186 -0.8407,-7.18807 0.8909,-3.12045 1.1644,-3.27086 6.3975,-3.51908 3.0067,-0.14261 6.0387,0.11479 6.7377,0.572 0.6991,0.45721 1.5352,3.7239 1.8582,7.2593 0.5489,6.00891 0.4171,6.58606 -2.021,8.85231 -2.9798,2.76971 -3.357,6.41766 -1.1077,10.71138 0.8253,1.57537 2.0484,5.491 2.7181,8.70139 1.4741,7.06735 4.4305,9.24255 11.185,8.22965 4.732,-0.70962 7.7344,0.86695 8.2644,4.33976 0.2548,1.66978 -0.4373,2.51662 -2.917,3.56919 -1.9433,0.82489 -3.6236,1.01634 -4.1772,0.47595 -0.5535,-0.54021 -1.476,-0.44773 -2.2924,0.22978 -1.0198,0.84638 -1.6596,0.84034 -2.5238,-0.0238 -1.5398,-1.5398 -4.7291,-1.47928 -4.8683,0.0924 -0.635,7.17107 3.5956,11.12227 7.6102,7.10764 0.9033,-0.90329 3.7,-2.02676 6.2149,-2.49659 5.1477,-0.9617 7.2797,-2.34446 7.2982,-4.73349 0.01,-0.89516 2.4768,-3.7887 5.4887,-6.4301 3.0118,-2.64139 6.697,-6.91639 8.1893,-9.5 1.4924,-2.5836 2.96,-4.93457 3.2614,-5.22436 0.3014,-0.2898 2.5395,-2.63736 4.9736,-5.21681 4.1085,-4.35383 4.3392,-4.87968 3.2191,-7.33801 -1.3774,-3.023 -0.6632,-6.41828 1.3501,-6.41828 0.748,0 2.25,1.13142 3.3378,2.51427 1.0877,1.38285 4.0267,3.42066 6.5311,4.52847 2.5044,1.10781 4.7976,2.4092 5.096,2.89198 0.2983,0.48277 3.3545,2.28447 6.7914,4.00377 15.0428,7.52511 19.3323,10.76946 19.9683,15.10324 0.3224,2.19628 -0.2236,3.54614 -2.2,5.43972 -2.9935,2.86793 -5.2168,3.19054 -7.0194,1.01855 -1.741,-2.09774 -3.1274,-1.91619 -11.7581,1.53969 -4.1752,1.67182 -8.3001,2.9021 -9.1666,2.73394 -0.8664,-0.16816 0.5622,-1.12324 3.1747,-2.12239 2.6125,-0.99916 4.75,-2.17192 4.75,-2.60614 0,-0.43422 -1.8951,-1.09252 -4.2113,-1.4629 -6.2186,-0.99439 -7.3187,0.74327 -9.7754,15.43936 -0.5076,3.03686 -2.322,9.78686 -4.0319,15 -2.2984,7.00699 -3.1281,11.43402 -3.1822,16.97844 -0.086,8.86891 -0.483,10.12249 -5.1253,16.20423 -3.2102,4.2056 -3.688,5.70312 -5.1176,16.04089 -1.0863,7.85573 -1.4162,15.42279 -1.0606,24.32856 0.703,17.60563 2.7099,17.68246 9.3698,25.50965 l 2.328,4.58333 -11.5181,-0.0163 c 0.9047,-1.69045 0.9308,-4.12472 -1.568,-6.41667 -2.8805,-2.64211 -2.9938,-3.08557 -3.382,-13.23372 -0.3714,-9.70841 -3.2798,-30.84879 -4.4023,-31.99843 -1.2911,-1.32236 -3.2545,3.97028 -4.3588,11.74976 -0.6736,4.74515 -1.879,10.19353 -2.6787,12.10752 -2.2694,5.43157 -2.6278,17.96421 -0.603,21.08582 3.0277,4.66756 6.6644,6.54699 12.1989,6.6517 l -24.0092,0.10512 c 1.3425,-2.11207 5.8589,-1.94644 5.6277,-5.96012 -0.2037,-3.53761 -2.1651,-4.98378 0.021,-13.51661 1.0248,-3.99992 1.5957,-11.77464 1.75,-23.83077 l 0.2291,-17.89399 -11.5,-0.63274 c -20.8928,-1.14953 -27.9212,-3.0216 -41.1021,-10.94786 -7.2745,-4.37446 -9.0697,-4.33308 -10.9692,0.2528 -0.69,1.66567 -2.7559,4.82556 -4.5909,7.02197 -1.8351,2.19641 -3.9493,6.31376 -4.6983,9.14965 -4.3497,16.46857 -4.6022,21.23043 -1.7316,32.65618 2.5449,10.12952 3.6127,12.83185 9.3621,19.10047 l 4.4367,4.83736" />
</g>
</svg>
Display the source blob
Display the rendered blob
Raw
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
<!DOCTYPE html>
<html vocab="http://schema.org" lang="ja">
<head>
<title>Three.jsによる馬のアニメーション</title>
<meta charset="utf-8" />
<meta name="description" content="SVGアニメーションのテスト" />
<meta name="keywords" content="Youtube,d3.js,Q.js,jquery" />
<meta name="author" content="sfpgmr" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" />
<script type="text/javascript" src="./pathseg.js"></script>
<script type="text/javascript" src="http://cdnjs.cloudflare.com/ajax/libs/d3/3.5.2/d3.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/three.js/r70/three.js"></script>
<script type="text/javascript" src="pathSerializer.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/q.js/1.1.2/q.min.js" ></script>
<!--<script type="text/javascript" src="./graphics.js"></script> -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/3.0.2/normalize.min.css" />
<style>
body {
margin: 0;
padding: 0;
overflow: hidden;
}
#svg {
display:none;
}
</style>
</head>
<body>
<div id="content"></div>
<div id="svg"></div>
<div id="svgcell"></div>
<script type="text/javascript" src="index.js"></script>
<script></script>
</body>
</html>
//The MIT License (MIT)
//
//Copyright (c) 2015 Satoshi Fujiwara
//
//Permission is hereby granted, free of charge, to any person obtaining a copy
//of this software and associated documentation files (the "Software"), to deal
//in the Software without restriction, including without limitation the rights
//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
//copies of the Software, and to permit persons to whom the Software is
//furnished to do so, subject to the following conditions:
//
//The above copyright notice and this permission notice shall be included in
//all copies or substantial portions of the Software.
//
//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
//IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
//FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
//AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
//LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
//OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
//THE SOFTWARE.
/// <reference path="http://cdnjs.cloudflare.com/ajax/libs/d3/3.5.2/d3.js" />
/// <reference path="http://cdnjs.cloudflare.com/ajax/libs/three.js/r70/three.js" />
/// <reference path="..\intellisense\q.intellisense.js" />
/// <reference path="shapeSerializer.js" />
//var fs = require('fs');
//try {
// fs.mkdirSync('./temp');
//} catch(e){
// if(e.code != "EEXIST"){
// throw e;
// }
//}
// リリース時にはコメントアウトすること
// document.write('<script src="http://' + (location.host || 'localhost').split(':')[0] +
// ':35729/livereload.js?snipver=2"></' + 'script>');
// stackoverflowより
// 絶対座標から相対座標への変換
// http://stackoverflow.com/questions/14179333/convert-svg-path-to-relative-commands
function convertToRelative(path) {
function set(type) {
var args = [].slice.call(arguments, 1)
, rcmd = 'createSVGPathSeg'+ type +'Rel'
, rseg = path[rcmd].apply(path, args);
segs.replaceItem(rseg, i);
}
var dx, dy, x0, y0, x1, y1, x2, y2, segs = path.pathSegList;
for (var x = 0, y = 0, i = 0, len = segs.numberOfItems; i < len; i++) {
var seg = segs.getItem(i)
, c = seg.pathSegTypeAsLetter;
if (/[MLHVCSQTAZz]/.test(c)) {
if ('x1' in seg) x1 = seg.x1 - x;
if ('x2' in seg) x2 = seg.x2 - x;
if ('y1' in seg) y1 = seg.y1 - y;
if ('y2' in seg) y2 = seg.y2 - y;
if ('x' in seg) dx = -x + (x = seg.x);
if ('y' in seg) dy = -y + (y = seg.y);
switch (c) {
case 'M': set('Moveto',dx,dy); break;
case 'L': set('Lineto',dx,dy); break;
case 'H': set('LinetoHorizontal',dx); break;
case 'V': set('LinetoVertical',dy); break;
case 'C': set('CurvetoCubic',dx,dy,x1,y1,x2,y2); break;
case 'S': set('CurvetoCubicSmooth',dx,dy,x2,y2); break;
case 'Q': set('CurvetoQuadratic',dx,dy,x1,y1); break;
case 'T': set('CurvetoQuadraticSmooth',dx,dy); break;
case 'A': set('Arc',dx,dy,seg.r1,seg.r2,seg.angle,
seg.largeArcFlag,seg.sweepFlag); break;
case 'Z': case 'z': x = x0; y = y0; break;
}
}
else {
if ('x' in seg) x += seg.x;
if ('y' in seg) y += seg.y;
}
// store the start of a subpath
if (c == 'M' || c == 'm') {
x0 = x;
y0 = y;
}
}
path.setAttribute('d', path.getAttribute('d').replace(/Z/g, 'z'));
}
// svg pathをthree.jsのshapeに変換する
// スペースの処理とy座標を反転するように修正
// From d3-threeD.js
// https://github.com/asutherland/d3-threeD
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
* You can obtain one at http://mozilla.org/MPL/2.0/. */
var DEGS_TO_RADS = Math.PI / 180, UNIT_SIZE = 100;
var DIGIT_0 = 48, DIGIT_9 = 57, COMMA = 44, SPACE = 32, PERIOD = 46, MINUS = 45,E = 101;
function transformSVGPath(pathStr) {
var path = new THREE.Path();
var idx = 1, len = pathStr.length, activeCmd,
x = 0, y = 0, nx = 0, ny = 0, firstX = null, firstY = null,
x1 = 0, x2 = 0, y1 = 0, y2 = 0,
rx = 0, ry = 0, xar = 0, laf = 0, sf = 0, cx, cy;
function eatNum() {
var sidx, c, isFloat = false, s;
// eat delims
while (idx < len) {
c = pathStr.charCodeAt(idx);
if (c !== COMMA && c !== SPACE)
break;
idx++;
}
if (c === MINUS)
sidx = idx++;
else
sidx = idx;
// eat number
while (idx < len) {
c = pathStr.charCodeAt(idx);
if (DIGIT_0 <= c && c <= DIGIT_9) {
idx++;
continue;
}
else if (c === PERIOD || c === E || c === MINUS) {
idx++;
isFloat = true;
continue;
}
s = pathStr.substring(sidx, idx);
return isFloat ? parseFloat(s) : parseInt(s);
}
s = pathStr.substring(sidx);
return isFloat ? parseFloat(s) : parseInt(s);
}
function nextIsNum() {
var c;
// do permanently eat any delims...
while (idx < len) {
c = pathStr.charCodeAt(idx);
if (c !== COMMA && c !== SPACE)
break;
idx++;
}
c = pathStr.charCodeAt(idx);
return (c === MINUS || (DIGIT_0 <= c && c <= DIGIT_9));
}
var canRepeat;
activeCmd = pathStr[0];
while (idx <= len) {
canRepeat = true;
switch (activeCmd) {
// moveto commands, become lineto's if repeated
case 'M':
x = eatNum();
y = -eatNum();
path.moveTo(x, y);
activeCmd = 'L';
firstX = x;
firstY = y;
break;
case 'm':
x += eatNum();
y += -eatNum();
path.moveTo(x, y);
activeCmd = 'l';
firstX = x;
firstY = y;
break;
case 'Z':
case 'z':
canRepeat = false;
if (x !== firstX || y !== firstY)
path.lineTo(firstX, firstY);
break;
// - lines!
case 'L':
case 'H':
case 'V':
nx = (activeCmd === 'V') ? x : eatNum();
ny = (activeCmd === 'H') ? y : -eatNum();
path.lineTo(nx, ny);
x = nx;
y = ny;
break;
case 'l':
case 'h':
case 'v':
nx = (activeCmd === 'v') ? x : (x + eatNum());
ny = (activeCmd === 'h') ? y : (y + -eatNum());
path.lineTo(nx, ny);
x = nx;
y = ny;
break;
// - cubic bezier
case 'C':
x1 = eatNum(); y1 = -eatNum();
case 'S':
if (activeCmd === 'S') {
x1 = 2 * x - x2; y1 = 2 * y - y2;
}
x2 = eatNum();
y2 = -eatNum();
nx = eatNum();
ny = -eatNum();
path.bezierCurveTo(x1, y1, x2, y2, nx, ny);
x = nx; y = ny;
break;
case 'c':
x1 = x + eatNum();
y1 = y + -eatNum();
case 's':
if (activeCmd === 's') {
x1 = 2 * x - x2;
y1 = 2 * y - y2;
}
x2 = x + eatNum();
y2 = y + -eatNum();
nx = x + eatNum();
ny = y + -eatNum();
path.bezierCurveTo(x1, y1, x2, y2, nx, ny);
x = nx; y = ny;
break;
// - quadratic bezier
case 'Q':
x1 = eatNum(); y1 = -eatNum();
case 'T':
if (activeCmd === 'T') {
x1 = 2 * x - x1;
y1 = 2 * y - y1;
}
nx = eatNum();
ny = -eatNum();
path.quadraticCurveTo(x1, y1, nx, ny);
x = nx;
y = ny;
break;
case 'q':
x1 = x + eatNum();
y1 = y + -eatNum();
case 't':
if (activeCmd === 't') {
x1 = 2 * x - x1;
y1 = 2 * y - y1;
}
nx = x + eatNum();
ny = y + -eatNum();
path.quadraticCurveTo(x1, y1, nx, ny);
x = nx; y = ny;
break;
// - elliptical arc
case 'A':
rx = eatNum();
ry = eatNum();
xar = eatNum() * DEGS_TO_RADS;
laf = eatNum();
sf = eatNum();
nx = eatNum();
ny = -eatNum();
if (rx !== ry) {
console.warn("Forcing elliptical arc to be a circular one :(",
rx, ry);
}
// SVG implementation notes does all the math for us! woo!
// http://www.w3.org/TR/SVG/implnote.html#ArcImplementationNotes
// step1, using x1 as x1'
x1 = Math.cos(xar) * (x - nx) / 2 + Math.sin(xar) * (y - ny) / 2;
y1 = -Math.sin(xar) * (x - nx) / 2 + Math.cos(xar) * (y - ny) / 2;
// step 2, using x2 as cx'
var norm = Math.sqrt(
(rx*rx * ry*ry - rx*rx * y1*y1 - ry*ry * x1*x1) /
(rx*rx * y1*y1 + ry*ry * x1*x1));
if (laf === sf)
norm = -norm;
x2 = norm * rx * y1 / ry;
y2 = norm * -ry * x1 / rx;
// step 3
cx = Math.cos(xar) * x2 - Math.sin(xar) * y2 + (x + nx) / 2;
cy = Math.sin(xar) * x2 + Math.cos(xar) * y2 + (y + ny) / 2;
var u = new THREE.Vector2(1, 0),
v = new THREE.Vector2((x1 - x2) / rx,
(y1 - y2) / ry);
var startAng = Math.acos(u.dot(v) / u.length() / v.length());
if (u.x * v.y - u.y * v.x < 0)
startAng = -startAng;
// we can reuse 'v' from start angle as our 'u' for delta angle
u.x = (-x1 - x2) / rx;
u.y = (-y1 - y2) / ry;
var deltaAng = Math.acos(v.dot(u) / v.length() / u.length());
// This normalization ends up making our curves fail to triangulate...
if (v.x * u.y - v.y * u.x < 0)
deltaAng = -deltaAng;
if (!sf && deltaAng > 0)
deltaAng -= Math.PI * 2;
if (sf && deltaAng < 0)
deltaAng += Math.PI * 2;
path.absarc(cx, cy, rx, startAng, startAng + deltaAng, sf);
x = nx;
y = ny;
break;
default:
if(activeCmd == ' '){
break;
}
throw new Error("weird path command: " + activeCmd);
}
// just reissue the command
if (canRepeat && nextIsNum())
continue;
activeCmd = pathStr[idx++];
}
return path;
}
// from gist
// https://gist.github.com/gabrielflorit/3758456
function createShape( geometry, color, x, y, z, rx, ry, rz, s ) {
// flat shape
// var geometry = new THREE.ShapeGeometry( shape );
var material = new THREE.MeshBasicMaterial({
color: color,
side: THREE.DoubleSide,
overdraw: true
});
var mesh = new THREE.Mesh( geometry, material );
mesh.position.set( x, y, z );
mesh.rotation.set( rx, ry, rz );
mesh.scale.set( s, s, s );
return mesh;
}
// メイン
window.addEventListener('load',function(){
var WIDTH = window.innerWidth, HEIGHT = window.innerHeight;
var renderer = new THREE.WebGLRenderer({ antialias: false, sortObjects: true });
renderer.setSize(WIDTH, HEIGHT);
renderer.setClearColor(0x000000, 1);
renderer.domElement.id = 'console';
renderer.domElement.className = 'console';
renderer.domElement.style.zIndex = 0;
d3.select('#content').node().appendChild(renderer.domElement);
renderer.clear();
// シーンの作成
var scene = new THREE.Scene();
// カメラの作成
var camera = new THREE.PerspectiveCamera(90.0, WIDTH / HEIGHT);
camera.position.x = 0.0;
camera.position.y = 0.0;
camera.position.z = (WIDTH / 2.0) * HEIGHT / WIDTH;
camera.lookAt(new THREE.Vector3(0.0, 0.0, 0.0));
var horseGroups = [];
window.addEventListener('resize',function()
{
WIDTH = window.innerWidth;
HEIGHT = window.innerHeight;
renderer.setSize(WIDTH,HEIGHT);
camera.aspect = WIDTH / HEIGHT;
camera.position.z = (WIDTH / 2.0) * HEIGHT / WIDTH;
camera.updateProjectionMatrix();
});
var xml = Q.nfbind(d3.xml);
var gto;
// SVGファイルから馬のメッシュを作る
xml('./horse.svg','image/svg+xml')
.then(function(svg){
try {
document.querySelector('#svg').appendChild(svg.firstChild);
var shapes = [];
var loader = new THREE.BufferGeometryLoader();
d3.select('#svg').selectAll('g').each(function(){
var g = d3.select(this);
var boundingBox = g.select('rect').node();
var paths = g.selectAll('path');
var holes = [];
var shape = null;
var shapeId = null;
paths.each(function(){
// 馬セルの取り出しと座標補正
var path = d3.select(this);
convertToRelative(path.node());
var m = path.node().createSVGPathSegMovetoRel
(path.node().pathSegList.getItem(0).x - boundingBox.x.baseVal.value - boundingBox.width.baseVal.value / 2.0,
path.node().pathSegList.getItem(0).y - boundingBox.y.baseVal.value - boundingBox.height.baseVal.value / 2.0
);
path.node().pathSegList.replaceItem(m,0);
path.attr('d',path.attr('d'));
// svg pathからthree.js shapeへの変換
var threePath = transformSVGPath(path.attr('d'));
// シリアライズテスト //
// シリアライズ
var threePathString = JSON.stringify(threePath,null,2);
console.log(threePathString.length);
// デシリアライズ
shape = SF.deserialize(JSON.parse(threePathString)).toShapes();
shapeId = path.attr('id');
});
var shapeGeometry = new THREE.ShapeGeometry( shape );
shapes.push({name:shapeId,shape:shapeGeometry});
});
var ggroup = new THREE.Group();
for(var i = 0; i < 1;++i){
var group = new THREE.Group();
shapes.forEach(function(sm){
var shapeMesh = createShape(sm.shape,0xFFFF00,0,0,0,0,0,0,1.0);
shapeMesh.visible = false;
shapeMesh.name = sm.name;
group.add(shapeMesh);
});
group.position.x = 0;
group.position.y = 0;
// group.position.z = 2000.0 * Math.random() - 1000.0;
horseGroups.push(group);
ggroup.add(group);
}
scene.add(ggroup);
ggroup.name = 'world';
d3.select('#svg').remove();
} catch (e) {
console.log(e + '\n' + e.stack);
}
//レンダリング
var r = 0.0;
(function render(index){
if(index > 10.0) index = 0.0;
var idx = parseInt(index,10);
for(var i = 0,end = horseGroups.length;i< end;++i){
var g = horseGroups[i];
g.getObjectByName('horse' + ('00' + idx.toString(10)).slice(-2)).visible = true;
if(idx == 0){
g.getObjectByName('horse10').visible = false;
} else {
g.getObjectByName('horse' + ('00' + (idx - 1).toString(10)).slice(-2)).visible = false;
}
}
renderer.render(scene,camera);
index += 0.25;
requestAnimationFrame(render.bind(null,index));
})(0);
// console.log(d3.select('#svg').html());
});
});
{
"name": "5e85dd1519d7b1d09626",
"version": "1.0.0",
"description": "SVGからThree.jsのgeometryへの変換",
"main": "app://localhost:35729/index.html",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"repository": {
"type": "git",
"url": "git@gist.github.com:/892dc3eb0775c70130b6.git"
},
"keywords": [
"Node-Webkit"
],
"author": "S.F.",
"license": "MIT",
"devDependencies": {
},
"dependencies": {
"q": "^1.1.2",
"request": "^2.53.0"
},
"window": {
"toolbar": true,
"width": 1280,
"height": 720
}
}
// SVGPathSeg API polyfill
// https://github.com/progers/pathseg
//
// This is a drop-in replacement for the SVGPathSeg and SVGPathSegList APIs that were removed from
// SVG2 (https://lists.w3.org/Archives/Public/www-svg/2015Jun/0044.html), including the latest spec
// changes which were implemented in Firefox 43 and Chrome 46.
(function() { "use strict";
if (!("SVGPathSeg" in window)) {
// Spec: http://www.w3.org/TR/SVG11/single-page.html#paths-InterfaceSVGPathSeg
window.SVGPathSeg = function(type, typeAsLetter, owningPathSegList) {
this.pathSegType = type;
this.pathSegTypeAsLetter = typeAsLetter;
this._owningPathSegList = owningPathSegList;
}
window.SVGPathSeg.prototype.classname = "SVGPathSeg";
window.SVGPathSeg.PATHSEG_UNKNOWN = 0;
window.SVGPathSeg.PATHSEG_CLOSEPATH = 1;
window.SVGPathSeg.PATHSEG_MOVETO_ABS = 2;
window.SVGPathSeg.PATHSEG_MOVETO_REL = 3;
window.SVGPathSeg.PATHSEG_LINETO_ABS = 4;
window.SVGPathSeg.PATHSEG_LINETO_REL = 5;
window.SVGPathSeg.PATHSEG_CURVETO_CUBIC_ABS = 6;
window.SVGPathSeg.PATHSEG_CURVETO_CUBIC_REL = 7;
window.SVGPathSeg.PATHSEG_CURVETO_QUADRATIC_ABS = 8;
window.SVGPathSeg.PATHSEG_CURVETO_QUADRATIC_REL = 9;
window.SVGPathSeg.PATHSEG_ARC_ABS = 10;
window.SVGPathSeg.PATHSEG_ARC_REL = 11;
window.SVGPathSeg.PATHSEG_LINETO_HORIZONTAL_ABS = 12;
window.SVGPathSeg.PATHSEG_LINETO_HORIZONTAL_REL = 13;
window.SVGPathSeg.PATHSEG_LINETO_VERTICAL_ABS = 14;
window.SVGPathSeg.PATHSEG_LINETO_VERTICAL_REL = 15;
window.SVGPathSeg.PATHSEG_CURVETO_CUBIC_SMOOTH_ABS = 16;
window.SVGPathSeg.PATHSEG_CURVETO_CUBIC_SMOOTH_REL = 17;
window.SVGPathSeg.PATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS = 18;
window.SVGPathSeg.PATHSEG_CURVETO_QUADRATIC_SMOOTH_REL = 19;
// Notify owning PathSegList on any changes so they can be synchronized back to the path element.
window.SVGPathSeg.prototype._segmentChanged = function() {
if (this._owningPathSegList)
this._owningPathSegList.segmentChanged(this);
}
window.SVGPathSegClosePath = function(owningPathSegList) {
window.SVGPathSeg.call(this, window.SVGPathSeg.PATHSEG_CLOSEPATH, "z", owningPathSegList);
}
window.SVGPathSegClosePath.prototype = Object.create(window.SVGPathSeg.prototype);
window.SVGPathSegClosePath.prototype.toString = function() { return "[object SVGPathSegClosePath]"; }
window.SVGPathSegClosePath.prototype._asPathString = function() { return this.pathSegTypeAsLetter; }
window.SVGPathSegClosePath.prototype.clone = function() { return new window.SVGPathSegClosePath(undefined); }
window.SVGPathSegMovetoAbs = function(owningPathSegList, x, y) {
window.SVGPathSeg.call(this, window.SVGPathSeg.PATHSEG_MOVETO_ABS, "M", owningPathSegList);
this._x = x;
this._y = y;
}
window.SVGPathSegMovetoAbs.prototype = Object.create(window.SVGPathSeg.prototype);
window.SVGPathSegMovetoAbs.prototype.toString = function() { return "[object SVGPathSegMovetoAbs]"; }
window.SVGPathSegMovetoAbs.prototype._asPathString = function() { return this.pathSegTypeAsLetter + " " + this._x + " " + this._y; }
window.SVGPathSegMovetoAbs.prototype.clone = function() { return new window.SVGPathSegMovetoAbs(undefined, this._x, this._y); }
Object.defineProperty(window.SVGPathSegMovetoAbs.prototype, "x", { get: function() { return this._x; }, set: function(x) { this._x = x; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegMovetoAbs.prototype, "y", { get: function() { return this._y; }, set: function(y) { this._y = y; this._segmentChanged(); }, enumerable: true });
window.SVGPathSegMovetoRel = function(owningPathSegList, x, y) {
window.SVGPathSeg.call(this, window.SVGPathSeg.PATHSEG_MOVETO_REL, "m", owningPathSegList);
this._x = x;
this._y = y;
}
window.SVGPathSegMovetoRel.prototype = Object.create(window.SVGPathSeg.prototype);
window.SVGPathSegMovetoRel.prototype.toString = function() { return "[object SVGPathSegMovetoRel]"; }
window.SVGPathSegMovetoRel.prototype._asPathString = function() { return this.pathSegTypeAsLetter + " " + this._x + " " + this._y; }
window.SVGPathSegMovetoRel.prototype.clone = function() { return new window.SVGPathSegMovetoRel(undefined, this._x, this._y); }
Object.defineProperty(window.SVGPathSegMovetoRel.prototype, "x", { get: function() { return this._x; }, set: function(x) { this._x = x; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegMovetoRel.prototype, "y", { get: function() { return this._y; }, set: function(y) { this._y = y; this._segmentChanged(); }, enumerable: true });
window.SVGPathSegLinetoAbs = function(owningPathSegList, x, y) {
window.SVGPathSeg.call(this, window.SVGPathSeg.PATHSEG_LINETO_ABS, "L", owningPathSegList);
this._x = x;
this._y = y;
}
window.SVGPathSegLinetoAbs.prototype = Object.create(window.SVGPathSeg.prototype);
window.SVGPathSegLinetoAbs.prototype.toString = function() { return "[object SVGPathSegLinetoAbs]"; }
window.SVGPathSegLinetoAbs.prototype._asPathString = function() { return this.pathSegTypeAsLetter + " " + this._x + " " + this._y; }
window.SVGPathSegLinetoAbs.prototype.clone = function() { return new window.SVGPathSegLinetoAbs(undefined, this._x, this._y); }
Object.defineProperty(window.SVGPathSegLinetoAbs.prototype, "x", { get: function() { return this._x; }, set: function(x) { this._x = x; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegLinetoAbs.prototype, "y", { get: function() { return this._y; }, set: function(y) { this._y = y; this._segmentChanged(); }, enumerable: true });
window.SVGPathSegLinetoRel = function(owningPathSegList, x, y) {
window.SVGPathSeg.call(this, window.SVGPathSeg.PATHSEG_LINETO_REL, "l", owningPathSegList);
this._x = x;
this._y = y;
}
window.SVGPathSegLinetoRel.prototype = Object.create(window.SVGPathSeg.prototype);
window.SVGPathSegLinetoRel.prototype.toString = function() { return "[object SVGPathSegLinetoRel]"; }
window.SVGPathSegLinetoRel.prototype._asPathString = function() { return this.pathSegTypeAsLetter + " " + this._x + " " + this._y; }
window.SVGPathSegLinetoRel.prototype.clone = function() { return new window.SVGPathSegLinetoRel(undefined, this._x, this._y); }
Object.defineProperty(window.SVGPathSegLinetoRel.prototype, "x", { get: function() { return this._x; }, set: function(x) { this._x = x; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegLinetoRel.prototype, "y", { get: function() { return this._y; }, set: function(y) { this._y = y; this._segmentChanged(); }, enumerable: true });
window.SVGPathSegCurvetoCubicAbs = function(owningPathSegList, x, y, x1, y1, x2, y2) {
window.SVGPathSeg.call(this, window.SVGPathSeg.PATHSEG_CURVETO_CUBIC_ABS, "C", owningPathSegList);
this._x = x;
this._y = y;
this._x1 = x1;
this._y1 = y1;
this._x2 = x2;
this._y2 = y2;
}
window.SVGPathSegCurvetoCubicAbs.prototype = Object.create(window.SVGPathSeg.prototype);
window.SVGPathSegCurvetoCubicAbs.prototype.toString = function() { return "[object SVGPathSegCurvetoCubicAbs]"; }
window.SVGPathSegCurvetoCubicAbs.prototype._asPathString = function() { return this.pathSegTypeAsLetter + " " + this._x1 + " " + this._y1 + " " + this._x2 + " " + this._y2 + " " + this._x + " " + this._y; }
window.SVGPathSegCurvetoCubicAbs.prototype.clone = function() { return new window.SVGPathSegCurvetoCubicAbs(undefined, this._x, this._y, this._x1, this._y1, this._x2, this._y2); }
Object.defineProperty(window.SVGPathSegCurvetoCubicAbs.prototype, "x", { get: function() { return this._x; }, set: function(x) { this._x = x; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoCubicAbs.prototype, "y", { get: function() { return this._y; }, set: function(y) { this._y = y; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoCubicAbs.prototype, "x1", { get: function() { return this._x1; }, set: function(x1) { this._x1 = x1; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoCubicAbs.prototype, "y1", { get: function() { return this._y1; }, set: function(y1) { this._y1 = y1; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoCubicAbs.prototype, "x2", { get: function() { return this._x2; }, set: function(x2) { this._x2 = x2; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoCubicAbs.prototype, "y2", { get: function() { return this._y2; }, set: function(y2) { this._y2 = y2; this._segmentChanged(); }, enumerable: true });
window.SVGPathSegCurvetoCubicRel = function(owningPathSegList, x, y, x1, y1, x2, y2) {
window.SVGPathSeg.call(this, window.SVGPathSeg.PATHSEG_CURVETO_CUBIC_REL, "c", owningPathSegList);
this._x = x;
this._y = y;
this._x1 = x1;
this._y1 = y1;
this._x2 = x2;
this._y2 = y2;
}
window.SVGPathSegCurvetoCubicRel.prototype = Object.create(window.SVGPathSeg.prototype);
window.SVGPathSegCurvetoCubicRel.prototype.toString = function() { return "[object SVGPathSegCurvetoCubicRel]"; }
window.SVGPathSegCurvetoCubicRel.prototype._asPathString = function() { return this.pathSegTypeAsLetter + " " + this._x1 + " " + this._y1 + " " + this._x2 + " " + this._y2 + " " + this._x + " " + this._y; }
window.SVGPathSegCurvetoCubicRel.prototype.clone = function() { return new window.SVGPathSegCurvetoCubicRel(undefined, this._x, this._y, this._x1, this._y1, this._x2, this._y2); }
Object.defineProperty(window.SVGPathSegCurvetoCubicRel.prototype, "x", { get: function() { return this._x; }, set: function(x) { this._x = x; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoCubicRel.prototype, "y", { get: function() { return this._y; }, set: function(y) { this._y = y; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoCubicRel.prototype, "x1", { get: function() { return this._x1; }, set: function(x1) { this._x1 = x1; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoCubicRel.prototype, "y1", { get: function() { return this._y1; }, set: function(y1) { this._y1 = y1; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoCubicRel.prototype, "x2", { get: function() { return this._x2; }, set: function(x2) { this._x2 = x2; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoCubicRel.prototype, "y2", { get: function() { return this._y2; }, set: function(y2) { this._y2 = y2; this._segmentChanged(); }, enumerable: true });
window.SVGPathSegCurvetoQuadraticAbs = function(owningPathSegList, x, y, x1, y1) {
window.SVGPathSeg.call(this, window.SVGPathSeg.PATHSEG_CURVETO_QUADRATIC_ABS, "Q", owningPathSegList);
this._x = x;
this._y = y;
this._x1 = x1;
this._y1 = y1;
}
window.SVGPathSegCurvetoQuadraticAbs.prototype = Object.create(window.SVGPathSeg.prototype);
window.SVGPathSegCurvetoQuadraticAbs.prototype.toString = function() { return "[object SVGPathSegCurvetoQuadraticAbs]"; }
window.SVGPathSegCurvetoQuadraticAbs.prototype._asPathString = function() { return this.pathSegTypeAsLetter + " " + this._x1 + " " + this._y1 + " " + this._x + " " + this._y; }
window.SVGPathSegCurvetoQuadraticAbs.prototype.clone = function() { return new window.SVGPathSegCurvetoQuadraticAbs(undefined, this._x, this._y, this._x1, this._y1); }
Object.defineProperty(window.SVGPathSegCurvetoQuadraticAbs.prototype, "x", { get: function() { return this._x; }, set: function(x) { this._x = x; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoQuadraticAbs.prototype, "y", { get: function() { return this._y; }, set: function(y) { this._y = y; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoQuadraticAbs.prototype, "x1", { get: function() { return this._x1; }, set: function(x1) { this._x1 = x1; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoQuadraticAbs.prototype, "y1", { get: function() { return this._y1; }, set: function(y1) { this._y1 = y1; this._segmentChanged(); }, enumerable: true });
window.SVGPathSegCurvetoQuadraticRel = function(owningPathSegList, x, y, x1, y1) {
window.SVGPathSeg.call(this, window.SVGPathSeg.PATHSEG_CURVETO_QUADRATIC_REL, "q", owningPathSegList);
this._x = x;
this._y = y;
this._x1 = x1;
this._y1 = y1;
}
window.SVGPathSegCurvetoQuadraticRel.prototype = Object.create(window.SVGPathSeg.prototype);
window.SVGPathSegCurvetoQuadraticRel.prototype.toString = function() { return "[object SVGPathSegCurvetoQuadraticRel]"; }
window.SVGPathSegCurvetoQuadraticRel.prototype._asPathString = function() { return this.pathSegTypeAsLetter + " " + this._x1 + " " + this._y1 + " " + this._x + " " + this._y; }
window.SVGPathSegCurvetoQuadraticRel.prototype.clone = function() { return new window.SVGPathSegCurvetoQuadraticRel(undefined, this._x, this._y, this._x1, this._y1); }
Object.defineProperty(window.SVGPathSegCurvetoQuadraticRel.prototype, "x", { get: function() { return this._x; }, set: function(x) { this._x = x; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoQuadraticRel.prototype, "y", { get: function() { return this._y; }, set: function(y) { this._y = y; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoQuadraticRel.prototype, "x1", { get: function() { return this._x1; }, set: function(x1) { this._x1 = x1; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoQuadraticRel.prototype, "y1", { get: function() { return this._y1; }, set: function(y1) { this._y1 = y1; this._segmentChanged(); }, enumerable: true });
window.SVGPathSegArcAbs = function(owningPathSegList, x, y, r1, r2, angle, largeArcFlag, sweepFlag) {
window.SVGPathSeg.call(this, window.SVGPathSeg.PATHSEG_ARC_ABS, "A", owningPathSegList);
this._x = x;
this._y = y;
this._r1 = r1;
this._r2 = r2;
this._angle = angle;
this._largeArcFlag = largeArcFlag;
this._sweepFlag = sweepFlag;
}
window.SVGPathSegArcAbs.prototype = Object.create(window.SVGPathSeg.prototype);
window.SVGPathSegArcAbs.prototype.toString = function() { return "[object SVGPathSegArcAbs]"; }
window.SVGPathSegArcAbs.prototype._asPathString = function() { return this.pathSegTypeAsLetter + " " + this._r1 + " " + this._r2 + " " + this._angle + " " + (this._largeArcFlag ? "1" : "0") + " " + (this._sweepFlag ? "1" : "0") + " " + this._x + " " + this._y; }
window.SVGPathSegArcAbs.prototype.clone = function() { return new window.SVGPathSegArcAbs(undefined, this._x, this._y, this._r1, this._r2, this._angle, this._largeArcFlag, this._sweepFlag); }
Object.defineProperty(window.SVGPathSegArcAbs.prototype, "x", { get: function() { return this._x; }, set: function(x) { this._x = x; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegArcAbs.prototype, "y", { get: function() { return this._y; }, set: function(y) { this._y = y; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegArcAbs.prototype, "r1", { get: function() { return this._r1; }, set: function(r1) { this._r1 = r1; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegArcAbs.prototype, "r2", { get: function() { return this._r2; }, set: function(r2) { this._r2 = r2; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegArcAbs.prototype, "angle", { get: function() { return this._angle; }, set: function(angle) { this._angle = angle; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegArcAbs.prototype, "largeArcFlag", { get: function() { return this._largeArcFlag; }, set: function(largeArcFlag) { this._largeArcFlag = largeArcFlag; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegArcAbs.prototype, "sweepFlag", { get: function() { return this._sweepFlag; }, set: function(sweepFlag) { this._sweepFlag = sweepFlag; this._segmentChanged(); }, enumerable: true });
window.SVGPathSegArcRel = function(owningPathSegList, x, y, r1, r2, angle, largeArcFlag, sweepFlag) {
window.SVGPathSeg.call(this, window.SVGPathSeg.PATHSEG_ARC_REL, "a", owningPathSegList);
this._x = x;
this._y = y;
this._r1 = r1;
this._r2 = r2;
this._angle = angle;
this._largeArcFlag = largeArcFlag;
this._sweepFlag = sweepFlag;
}
window.SVGPathSegArcRel.prototype = Object.create(window.SVGPathSeg.prototype);
window.SVGPathSegArcRel.prototype.toString = function() { return "[object SVGPathSegArcRel]"; }
window.SVGPathSegArcRel.prototype._asPathString = function() { return this.pathSegTypeAsLetter + " " + this._r1 + " " + this._r2 + " " + this._angle + " " + (this._largeArcFlag ? "1" : "0") + " " + (this._sweepFlag ? "1" : "0") + " " + this._x + " " + this._y; }
window.SVGPathSegArcRel.prototype.clone = function() { return new window.SVGPathSegArcRel(undefined, this._x, this._y, this._r1, this._r2, this._angle, this._largeArcFlag, this._sweepFlag); }
Object.defineProperty(window.SVGPathSegArcRel.prototype, "x", { get: function() { return this._x; }, set: function(x) { this._x = x; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegArcRel.prototype, "y", { get: function() { return this._y; }, set: function(y) { this._y = y; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegArcRel.prototype, "r1", { get: function() { return this._r1; }, set: function(r1) { this._r1 = r1; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegArcRel.prototype, "r2", { get: function() { return this._r2; }, set: function(r2) { this._r2 = r2; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegArcRel.prototype, "angle", { get: function() { return this._angle; }, set: function(angle) { this._angle = angle; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegArcRel.prototype, "largeArcFlag", { get: function() { return this._largeArcFlag; }, set: function(largeArcFlag) { this._largeArcFlag = largeArcFlag; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegArcRel.prototype, "sweepFlag", { get: function() { return this._sweepFlag; }, set: function(sweepFlag) { this._sweepFlag = sweepFlag; this._segmentChanged(); }, enumerable: true });
window.SVGPathSegLinetoHorizontalAbs = function(owningPathSegList, x) {
window.SVGPathSeg.call(this, window.SVGPathSeg.PATHSEG_LINETO_HORIZONTAL_ABS, "H", owningPathSegList);
this._x = x;
}
window.SVGPathSegLinetoHorizontalAbs.prototype = Object.create(window.SVGPathSeg.prototype);
window.SVGPathSegLinetoHorizontalAbs.prototype.toString = function() { return "[object SVGPathSegLinetoHorizontalAbs]"; }
window.SVGPathSegLinetoHorizontalAbs.prototype._asPathString = function() { return this.pathSegTypeAsLetter + " " + this._x; }
window.SVGPathSegLinetoHorizontalAbs.prototype.clone = function() { return new window.SVGPathSegLinetoHorizontalAbs(undefined, this._x); }
Object.defineProperty(window.SVGPathSegLinetoHorizontalAbs.prototype, "x", { get: function() { return this._x; }, set: function(x) { this._x = x; this._segmentChanged(); }, enumerable: true });
window.SVGPathSegLinetoHorizontalRel = function(owningPathSegList, x) {
window.SVGPathSeg.call(this, window.SVGPathSeg.PATHSEG_LINETO_HORIZONTAL_REL, "h", owningPathSegList);
this._x = x;
}
window.SVGPathSegLinetoHorizontalRel.prototype = Object.create(window.SVGPathSeg.prototype);
window.SVGPathSegLinetoHorizontalRel.prototype.toString = function() { return "[object SVGPathSegLinetoHorizontalRel]"; }
window.SVGPathSegLinetoHorizontalRel.prototype._asPathString = function() { return this.pathSegTypeAsLetter + " " + this._x; }
window.SVGPathSegLinetoHorizontalRel.prototype.clone = function() { return new window.SVGPathSegLinetoHorizontalRel(undefined, this._x); }
Object.defineProperty(window.SVGPathSegLinetoHorizontalRel.prototype, "x", { get: function() { return this._x; }, set: function(x) { this._x = x; this._segmentChanged(); }, enumerable: true });
window.SVGPathSegLinetoVerticalAbs = function(owningPathSegList, y) {
window.SVGPathSeg.call(this, window.SVGPathSeg.PATHSEG_LINETO_VERTICAL_ABS, "V", owningPathSegList);
this._y = y;
}
window.SVGPathSegLinetoVerticalAbs.prototype = Object.create(window.SVGPathSeg.prototype);
window.SVGPathSegLinetoVerticalAbs.prototype.toString = function() { return "[object SVGPathSegLinetoVerticalAbs]"; }
window.SVGPathSegLinetoVerticalAbs.prototype._asPathString = function() { return this.pathSegTypeAsLetter + " " + this._y; }
window.SVGPathSegLinetoVerticalAbs.prototype.clone = function() { return new window.SVGPathSegLinetoVerticalAbs(undefined, this._y); }
Object.defineProperty(window.SVGPathSegLinetoVerticalAbs.prototype, "y", { get: function() { return this._y; }, set: function(y) { this._y = y; this._segmentChanged(); }, enumerable: true });
window.SVGPathSegLinetoVerticalRel = function(owningPathSegList, y) {
window.SVGPathSeg.call(this, window.SVGPathSeg.PATHSEG_LINETO_VERTICAL_REL, "v", owningPathSegList);
this._y = y;
}
window.SVGPathSegLinetoVerticalRel.prototype = Object.create(window.SVGPathSeg.prototype);
window.SVGPathSegLinetoVerticalRel.prototype.toString = function() { return "[object SVGPathSegLinetoVerticalRel]"; }
window.SVGPathSegLinetoVerticalRel.prototype._asPathString = function() { return this.pathSegTypeAsLetter + " " + this._y; }
window.SVGPathSegLinetoVerticalRel.prototype.clone = function() { return new window.SVGPathSegLinetoVerticalRel(undefined, this._y); }
Object.defineProperty(window.SVGPathSegLinetoVerticalRel.prototype, "y", { get: function() { return this._y; }, set: function(y) { this._y = y; this._segmentChanged(); }, enumerable: true });
window.SVGPathSegCurvetoCubicSmoothAbs = function(owningPathSegList, x, y, x2, y2) {
window.SVGPathSeg.call(this, window.SVGPathSeg.PATHSEG_CURVETO_CUBIC_SMOOTH_ABS, "S", owningPathSegList);
this._x = x;
this._y = y;
this._x2 = x2;
this._y2 = y2;
}
window.SVGPathSegCurvetoCubicSmoothAbs.prototype = Object.create(window.SVGPathSeg.prototype);
window.SVGPathSegCurvetoCubicSmoothAbs.prototype.toString = function() { return "[object SVGPathSegCurvetoCubicSmoothAbs]"; }
window.SVGPathSegCurvetoCubicSmoothAbs.prototype._asPathString = function() { return this.pathSegTypeAsLetter + " " + this._x2 + " " + this._y2 + " " + this._x + " " + this._y; }
window.SVGPathSegCurvetoCubicSmoothAbs.prototype.clone = function() { return new window.SVGPathSegCurvetoCubicSmoothAbs(undefined, this._x, this._y, this._x2, this._y2); }
Object.defineProperty(window.SVGPathSegCurvetoCubicSmoothAbs.prototype, "x", { get: function() { return this._x; }, set: function(x) { this._x = x; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoCubicSmoothAbs.prototype, "y", { get: function() { return this._y; }, set: function(y) { this._y = y; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoCubicSmoothAbs.prototype, "x2", { get: function() { return this._x2; }, set: function(x2) { this._x2 = x2; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoCubicSmoothAbs.prototype, "y2", { get: function() { return this._y2; }, set: function(y2) { this._y2 = y2; this._segmentChanged(); }, enumerable: true });
window.SVGPathSegCurvetoCubicSmoothRel = function(owningPathSegList, x, y, x2, y2) {
window.SVGPathSeg.call(this, window.SVGPathSeg.PATHSEG_CURVETO_CUBIC_SMOOTH_REL, "s", owningPathSegList);
this._x = x;
this._y = y;
this._x2 = x2;
this._y2 = y2;
}
window.SVGPathSegCurvetoCubicSmoothRel.prototype = Object.create(window.SVGPathSeg.prototype);
window.SVGPathSegCurvetoCubicSmoothRel.prototype.toString = function() { return "[object SVGPathSegCurvetoCubicSmoothRel]"; }
window.SVGPathSegCurvetoCubicSmoothRel.prototype._asPathString = function() { return this.pathSegTypeAsLetter + " " + this._x2 + " " + this._y2 + " " + this._x + " " + this._y; }
window.SVGPathSegCurvetoCubicSmoothRel.prototype.clone = function() { return new window.SVGPathSegCurvetoCubicSmoothRel(undefined, this._x, this._y, this._x2, this._y2); }
Object.defineProperty(window.SVGPathSegCurvetoCubicSmoothRel.prototype, "x", { get: function() { return this._x; }, set: function(x) { this._x = x; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoCubicSmoothRel.prototype, "y", { get: function() { return this._y; }, set: function(y) { this._y = y; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoCubicSmoothRel.prototype, "x2", { get: function() { return this._x2; }, set: function(x2) { this._x2 = x2; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoCubicSmoothRel.prototype, "y2", { get: function() { return this._y2; }, set: function(y2) { this._y2 = y2; this._segmentChanged(); }, enumerable: true });
window.SVGPathSegCurvetoQuadraticSmoothAbs = function(owningPathSegList, x, y) {
window.SVGPathSeg.call(this, window.SVGPathSeg.PATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS, "T", owningPathSegList);
this._x = x;
this._y = y;
}
window.SVGPathSegCurvetoQuadraticSmoothAbs.prototype = Object.create(window.SVGPathSeg.prototype);
window.SVGPathSegCurvetoQuadraticSmoothAbs.prototype.toString = function() { return "[object SVGPathSegCurvetoQuadraticSmoothAbs]"; }
window.SVGPathSegCurvetoQuadraticSmoothAbs.prototype._asPathString = function() { return this.pathSegTypeAsLetter + " " + this._x + " " + this._y; }
window.SVGPathSegCurvetoQuadraticSmoothAbs.prototype.clone = function() { return new window.SVGPathSegCurvetoQuadraticSmoothAbs(undefined, this._x, this._y); }
Object.defineProperty(window.SVGPathSegCurvetoQuadraticSmoothAbs.prototype, "x", { get: function() { return this._x; }, set: function(x) { this._x = x; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoQuadraticSmoothAbs.prototype, "y", { get: function() { return this._y; }, set: function(y) { this._y = y; this._segmentChanged(); }, enumerable: true });
window.SVGPathSegCurvetoQuadraticSmoothRel = function(owningPathSegList, x, y) {
window.SVGPathSeg.call(this, window.SVGPathSeg.PATHSEG_CURVETO_QUADRATIC_SMOOTH_REL, "t", owningPathSegList);
this._x = x;
this._y = y;
}
window.SVGPathSegCurvetoQuadraticSmoothRel.prototype = Object.create(window.SVGPathSeg.prototype);
window.SVGPathSegCurvetoQuadraticSmoothRel.prototype.toString = function() { return "[object SVGPathSegCurvetoQuadraticSmoothRel]"; }
window.SVGPathSegCurvetoQuadraticSmoothRel.prototype._asPathString = function() { return this.pathSegTypeAsLetter + " " + this._x + " " + this._y; }
window.SVGPathSegCurvetoQuadraticSmoothRel.prototype.clone = function() { return new window.SVGPathSegCurvetoQuadraticSmoothRel(undefined, this._x, this._y); }
Object.defineProperty(window.SVGPathSegCurvetoQuadraticSmoothRel.prototype, "x", { get: function() { return this._x; }, set: function(x) { this._x = x; this._segmentChanged(); }, enumerable: true });
Object.defineProperty(window.SVGPathSegCurvetoQuadraticSmoothRel.prototype, "y", { get: function() { return this._y; }, set: function(y) { this._y = y; this._segmentChanged(); }, enumerable: true });
// Add createSVGPathSeg* functions to window.SVGPathElement.
// Spec: http://www.w3.org/TR/SVG11/single-page.html#paths-Interfacewindow.SVGPathElement.
window.SVGPathElement.prototype.createSVGPathSegClosePath = function() { return new window.SVGPathSegClosePath(undefined); }
window.SVGPathElement.prototype.createSVGPathSegMovetoAbs = function(x, y) { return new window.SVGPathSegMovetoAbs(undefined, x, y); }
window.SVGPathElement.prototype.createSVGPathSegMovetoRel = function(x, y) { return new window.SVGPathSegMovetoRel(undefined, x, y); }
window.SVGPathElement.prototype.createSVGPathSegLinetoAbs = function(x, y) { return new window.SVGPathSegLinetoAbs(undefined, x, y); }
window.SVGPathElement.prototype.createSVGPathSegLinetoRel = function(x, y) { return new window.SVGPathSegLinetoRel(undefined, x, y); }
window.SVGPathElement.prototype.createSVGPathSegCurvetoCubicAbs = function(x, y, x1, y1, x2, y2) { return new window.SVGPathSegCurvetoCubicAbs(undefined, x, y, x1, y1, x2, y2); }
window.SVGPathElement.prototype.createSVGPathSegCurvetoCubicRel = function(x, y, x1, y1, x2, y2) { return new window.SVGPathSegCurvetoCubicRel(undefined, x, y, x1, y1, x2, y2); }
window.SVGPathElement.prototype.createSVGPathSegCurvetoQuadraticAbs = function(x, y, x1, y1) { return new window.SVGPathSegCurvetoQuadraticAbs(undefined, x, y, x1, y1); }
window.SVGPathElement.prototype.createSVGPathSegCurvetoQuadraticRel = function(x, y, x1, y1) { return new window.SVGPathSegCurvetoQuadraticRel(undefined, x, y, x1, y1); }
window.SVGPathElement.prototype.createSVGPathSegArcAbs = function(x, y, r1, r2, angle, largeArcFlag, sweepFlag) { return new window.SVGPathSegArcAbs(undefined, x, y, r1, r2, angle, largeArcFlag, sweepFlag); }
window.SVGPathElement.prototype.createSVGPathSegArcRel = function(x, y, r1, r2, angle, largeArcFlag, sweepFlag) { return new window.SVGPathSegArcRel(undefined, x, y, r1, r2, angle, largeArcFlag, sweepFlag); }
window.SVGPathElement.prototype.createSVGPathSegLinetoHorizontalAbs = function(x) { return new window.SVGPathSegLinetoHorizontalAbs(undefined, x); }
window.SVGPathElement.prototype.createSVGPathSegLinetoHorizontalRel = function(x) { return new window.SVGPathSegLinetoHorizontalRel(undefined, x); }
window.SVGPathElement.prototype.createSVGPathSegLinetoVerticalAbs = function(y) { return new window.SVGPathSegLinetoVerticalAbs(undefined, y); }
window.SVGPathElement.prototype.createSVGPathSegLinetoVerticalRel = function(y) { return new window.SVGPathSegLinetoVerticalRel(undefined, y); }
window.SVGPathElement.prototype.createSVGPathSegCurvetoCubicSmoothAbs = function(x, y, x2, y2) { return new window.SVGPathSegCurvetoCubicSmoothAbs(undefined, x, y, x2, y2); }
window.SVGPathElement.prototype.createSVGPathSegCurvetoCubicSmoothRel = function(x, y, x2, y2) { return new window.SVGPathSegCurvetoCubicSmoothRel(undefined, x, y, x2, y2); }
window.SVGPathElement.prototype.createSVGPathSegCurvetoQuadraticSmoothAbs = function(x, y) { return new window.SVGPathSegCurvetoQuadraticSmoothAbs(undefined, x, y); }
window.SVGPathElement.prototype.createSVGPathSegCurvetoQuadraticSmoothRel = function(x, y) { return new window.SVGPathSegCurvetoQuadraticSmoothRel(undefined, x, y); }
}
if (!("SVGPathSegList" in window)) {
// Spec: http://www.w3.org/TR/SVG11/single-page.html#paths-InterfaceSVGPathSegList
window.SVGPathSegList = function(pathElement) {
this._pathElement = pathElement;
this._list = this._parsePath(this._pathElement.getAttribute("d"));
// Use a MutationObserver to catch changes to the path's "d" attribute.
this._mutationObserverConfig = { "attributes": true, "attributeFilter": ["d"] };
this._pathElementMutationObserver = new MutationObserver(this._updateListFromPathMutations.bind(this));
this._pathElementMutationObserver.observe(this._pathElement, this._mutationObserverConfig);
}
window.SVGPathSegList.prototype.classname = "SVGPathSegList";
Object.defineProperty(window.SVGPathSegList.prototype, "numberOfItems", {
get: function() {
this._checkPathSynchronizedToList();
return this._list.length;
},
enumerable: true
});
// Add the pathSegList accessors to window.SVGPathElement.
// Spec: http://www.w3.org/TR/SVG11/single-page.html#paths-InterfaceSVGAnimatedPathData
Object.defineProperty(window.SVGPathElement.prototype, "pathSegList", {
get: function() {
if (!this._pathSegList)
this._pathSegList = new window.SVGPathSegList(this);
return this._pathSegList;
},
enumerable: true
});
// FIXME: The following are not implemented and simply return window.SVGPathElement.pathSegList.
Object.defineProperty(window.SVGPathElement.prototype, "normalizedPathSegList", { get: function() { return this.pathSegList; }, enumerable: true });
Object.defineProperty(window.SVGPathElement.prototype, "animatedPathSegList", { get: function() { return this.pathSegList; }, enumerable: true });
Object.defineProperty(window.SVGPathElement.prototype, "animatedNormalizedPathSegList", { get: function() { return this.pathSegList; }, enumerable: true });
// Process any pending mutations to the path element and update the list as needed.
// This should be the first call of all public functions and is needed because
// MutationObservers are not synchronous so we can have pending asynchronous mutations.
window.SVGPathSegList.prototype._checkPathSynchronizedToList = function() {
this._updateListFromPathMutations(this._pathElementMutationObserver.takeRecords());
}
window.SVGPathSegList.prototype._updateListFromPathMutations = function(mutationRecords) {
if (!this._pathElement)
return;
var hasPathMutations = false;
mutationRecords.forEach(function(record) {
if (record.attributeName == "d")
hasPathMutations = true;
});
if (hasPathMutations)
this._list = this._parsePath(this._pathElement.getAttribute("d"));
}
// Serialize the list and update the path's 'd' attribute.
window.SVGPathSegList.prototype._writeListToPath = function() {
this._pathElementMutationObserver.disconnect();
this._pathElement.setAttribute("d", window.SVGPathSegList._pathSegArrayAsString(this._list));
this._pathElementMutationObserver.observe(this._pathElement, this._mutationObserverConfig);
}
// When a path segment changes the list needs to be synchronized back to the path element.
window.SVGPathSegList.prototype.segmentChanged = function(pathSeg) {
this._writeListToPath();
}
window.SVGPathSegList.prototype.clear = function() {
this._checkPathSynchronizedToList();
this._list.forEach(function(pathSeg) {
pathSeg._owningPathSegList = null;
});
this._list = [];
this._writeListToPath();
}
window.SVGPathSegList.prototype.initialize = function(newItem) {
this._checkPathSynchronizedToList();
this._list = [newItem];
newItem._owningPathSegList = this;
this._writeListToPath();
return newItem;
}
window.SVGPathSegList.prototype._checkValidIndex = function(index) {
if (isNaN(index) || index < 0 || index >= this.numberOfItems)
throw "INDEX_SIZE_ERR";
}
window.SVGPathSegList.prototype.getItem = function(index) {
this._checkPathSynchronizedToList();
this._checkValidIndex(index);
return this._list[index];
}
window.SVGPathSegList.prototype.insertItemBefore = function(newItem, index) {
this._checkPathSynchronizedToList();
// Spec: If the index is greater than or equal to numberOfItems, then the new item is appended to the end of the list.
if (index > this.numberOfItems)
index = this.numberOfItems;
if (newItem._owningPathSegList) {
// SVG2 spec says to make a copy.
newItem = newItem.clone();
}
this._list.splice(index, 0, newItem);
newItem._owningPathSegList = this;
this._writeListToPath();
return newItem;
}
window.SVGPathSegList.prototype.replaceItem = function(newItem, index) {
this._checkPathSynchronizedToList();
if (newItem._owningPathSegList) {
// SVG2 spec says to make a copy.
newItem = newItem.clone();
}
this._checkValidIndex(index);
this._list[index] = newItem;
newItem._owningPathSegList = this;
this._writeListToPath();
return newItem;
}
window.SVGPathSegList.prototype.removeItem = function(index) {
this._checkPathSynchronizedToList();
this._checkValidIndex(index);
var item = this._list[index];
this._list.splice(index, 1);
this._writeListToPath();
return item;
}
window.SVGPathSegList.prototype.appendItem = function(newItem) {
this._checkPathSynchronizedToList();
if (newItem._owningPathSegList) {
// SVG2 spec says to make a copy.
newItem = newItem.clone();
}
this._list.push(newItem);
newItem._owningPathSegList = this;
// TODO: Optimize this to just append to the existing attribute.
this._writeListToPath();
return newItem;
}
window.SVGPathSegList._pathSegArrayAsString = function(pathSegArray) {
var string = "";
var first = true;
pathSegArray.forEach(function(pathSeg) {
if (first) {
first = false;
string += pathSeg._asPathString();
} else {
string += " " + pathSeg._asPathString();
}
});
return string;
}
// This closely follows SVGPathParser::parsePath from Source/core/svg/SVGPathParser.cpp.
window.SVGPathSegList.prototype._parsePath = function(string) {
if (!string || string.length == 0)
return [];
var owningPathSegList = this;
var Builder = function() {
this.pathSegList = [];
}
Builder.prototype.appendSegment = function(pathSeg) {
this.pathSegList.push(pathSeg);
}
var Source = function(string) {
this._string = string;
this._currentIndex = 0;
this._endIndex = this._string.length;
this._previousCommand = window.SVGPathSeg.PATHSEG_UNKNOWN;
this._skipOptionalSpaces();
}
Source.prototype._isCurrentSpace = function() {
var character = this._string[this._currentIndex];
return character <= " " && (character == " " || character == "\n" || character == "\t" || character == "\r" || character == "\f");
}
Source.prototype._skipOptionalSpaces = function() {
while (this._currentIndex < this._endIndex && this._isCurrentSpace())
this._currentIndex++;
return this._currentIndex < this._endIndex;
}
Source.prototype._skipOptionalSpacesOrDelimiter = function() {
if (this._currentIndex < this._endIndex && !this._isCurrentSpace() && this._string.charAt(this._currentIndex) != ",")
return false;
if (this._skipOptionalSpaces()) {
if (this._currentIndex < this._endIndex && this._string.charAt(this._currentIndex) == ",") {
this._currentIndex++;
this._skipOptionalSpaces();
}
}
return this._currentIndex < this._endIndex;
}
Source.prototype.hasMoreData = function() {
return this._currentIndex < this._endIndex;
}
Source.prototype.peekSegmentType = function() {
var lookahead = this._string[this._currentIndex];
return this._pathSegTypeFromChar(lookahead);
}
Source.prototype._pathSegTypeFromChar = function(lookahead) {
switch (lookahead) {
case "Z":
case "z":
return window.SVGPathSeg.PATHSEG_CLOSEPATH;
case "M":
return window.SVGPathSeg.PATHSEG_MOVETO_ABS;
case "m":
return window.SVGPathSeg.PATHSEG_MOVETO_REL;
case "L":
return window.SVGPathSeg.PATHSEG_LINETO_ABS;
case "l":
return window.SVGPathSeg.PATHSEG_LINETO_REL;
case "C":
return window.SVGPathSeg.PATHSEG_CURVETO_CUBIC_ABS;
case "c":
return window.SVGPathSeg.PATHSEG_CURVETO_CUBIC_REL;
case "Q":
return window.SVGPathSeg.PATHSEG_CURVETO_QUADRATIC_ABS;
case "q":
return window.SVGPathSeg.PATHSEG_CURVETO_QUADRATIC_REL;
case "A":
return window.SVGPathSeg.PATHSEG_ARC_ABS;
case "a":
return window.SVGPathSeg.PATHSEG_ARC_REL;
case "H":
return window.SVGPathSeg.PATHSEG_LINETO_HORIZONTAL_ABS;
case "h":
return window.SVGPathSeg.PATHSEG_LINETO_HORIZONTAL_REL;
case "V":
return window.SVGPathSeg.PATHSEG_LINETO_VERTICAL_ABS;
case "v":
return window.SVGPathSeg.PATHSEG_LINETO_VERTICAL_REL;
case "S":
return window.SVGPathSeg.PATHSEG_CURVETO_CUBIC_SMOOTH_ABS;
case "s":
return window.SVGPathSeg.PATHSEG_CURVETO_CUBIC_SMOOTH_REL;
case "T":
return window.SVGPathSeg.PATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS;
case "t":
return window.SVGPathSeg.PATHSEG_CURVETO_QUADRATIC_SMOOTH_REL;
default:
return window.SVGPathSeg.PATHSEG_UNKNOWN;
}
}
Source.prototype._nextCommandHelper = function(lookahead, previousCommand) {
// Check for remaining coordinates in the current command.
if ((lookahead == "+" || lookahead == "-" || lookahead == "." || (lookahead >= "0" && lookahead <= "9")) && previousCommand != window.SVGPathSeg.PATHSEG_CLOSEPATH) {
if (previousCommand == window.SVGPathSeg.PATHSEG_MOVETO_ABS)
return window.SVGPathSeg.PATHSEG_LINETO_ABS;
if (previousCommand == window.SVGPathSeg.PATHSEG_MOVETO_REL)
return window.SVGPathSeg.PATHSEG_LINETO_REL;
return previousCommand;
}
return window.SVGPathSeg.PATHSEG_UNKNOWN;
}
Source.prototype.initialCommandIsMoveTo = function() {
// If the path is empty it is still valid, so return true.
if (!this.hasMoreData())
return true;
var command = this.peekSegmentType();
// Path must start with moveTo.
return command == window.SVGPathSeg.PATHSEG_MOVETO_ABS || command == window.SVGPathSeg.PATHSEG_MOVETO_REL;
}
// Parse a number from an SVG path. This very closely follows genericParseNumber(...) from Source/core/svg/SVGParserUtilities.cpp.
// Spec: http://www.w3.org/TR/SVG11/single-page.html#paths-PathDataBNF
Source.prototype._parseNumber = function() {
var exponent = 0;
var integer = 0;
var frac = 1;
var decimal = 0;
var sign = 1;
var expsign = 1;
var startIndex = this._currentIndex;
this._skipOptionalSpaces();
// Read the sign.
if (this._currentIndex < this._endIndex && this._string.charAt(this._currentIndex) == "+")
this._currentIndex++;
else if (this._currentIndex < this._endIndex && this._string.charAt(this._currentIndex) == "-") {
this._currentIndex++;
sign = -1;
}
if (this._currentIndex == this._endIndex || ((this._string.charAt(this._currentIndex) < "0" || this._string.charAt(this._currentIndex) > "9") && this._string.charAt(this._currentIndex) != "."))
// The first character of a number must be one of [0-9+-.].
return undefined;
// Read the integer part, build right-to-left.
var startIntPartIndex = this._currentIndex;
while (this._currentIndex < this._endIndex && this._string.charAt(this._currentIndex) >= "0" && this._string.charAt(this._currentIndex) <= "9")
this._currentIndex++; // Advance to first non-digit.
if (this._currentIndex != startIntPartIndex) {
var scanIntPartIndex = this._currentIndex - 1;
var multiplier = 1;
while (scanIntPartIndex >= startIntPartIndex) {
integer += multiplier * (this._string.charAt(scanIntPartIndex--) - "0");
multiplier *= 10;
}
}
// Read the decimals.
if (this._currentIndex < this._endIndex && this._string.charAt(this._currentIndex) == ".") {
this._currentIndex++;
// There must be a least one digit following the .
if (this._currentIndex >= this._endIndex || this._string.charAt(this._currentIndex) < "0" || this._string.charAt(this._currentIndex) > "9")
return undefined;
while (this._currentIndex < this._endIndex && this._string.charAt(this._currentIndex) >= "0" && this._string.charAt(this._currentIndex) <= "9") {
frac *= 10;
decimal += (this._string.charAt(this._currentIndex) - "0") / frac;
this._currentIndex += 1;
}
}
// Read the exponent part.
if (this._currentIndex != startIndex && this._currentIndex + 1 < this._endIndex && (this._string.charAt(this._currentIndex) == "e" || this._string.charAt(this._currentIndex) == "E") && (this._string.charAt(this._currentIndex + 1) != "x" && this._string.charAt(this._currentIndex + 1) != "m")) {
this._currentIndex++;
// Read the sign of the exponent.
if (this._string.charAt(this._currentIndex) == "+") {
this._currentIndex++;
} else if (this._string.charAt(this._currentIndex) == "-") {
this._currentIndex++;
expsign = -1;
}
// There must be an exponent.
if (this._currentIndex >= this._endIndex || this._string.charAt(this._currentIndex) < "0" || this._string.charAt(this._currentIndex) > "9")
return undefined;
while (this._currentIndex < this._endIndex && this._string.charAt(this._currentIndex) >= "0" && this._string.charAt(this._currentIndex) <= "9") {
exponent *= 10;
exponent += (this._string.charAt(this._currentIndex) - "0");
this._currentIndex++;
}
}
var number = integer + decimal;
number *= sign;
if (exponent)
number *= Math.pow(10, expsign * exponent);
if (startIndex == this._currentIndex)
return undefined;
this._skipOptionalSpacesOrDelimiter();
return number;
}
Source.prototype._parseArcFlag = function() {
if (this._currentIndex >= this._endIndex)
return undefined;
var flag = false;
var flagChar = this._string.charAt(this._currentIndex++);
if (flagChar == "0")
flag = false;
else if (flagChar == "1")
flag = true;
else
return undefined;
this._skipOptionalSpacesOrDelimiter();
return flag;
}
Source.prototype.parseSegment = function() {
var lookahead = this._string[this._currentIndex];
var command = this._pathSegTypeFromChar(lookahead);
if (command == window.SVGPathSeg.PATHSEG_UNKNOWN) {
// Possibly an implicit command. Not allowed if this is the first command.
if (this._previousCommand == window.SVGPathSeg.PATHSEG_UNKNOWN)
return null;
command = this._nextCommandHelper(lookahead, this._previousCommand);
if (command == window.SVGPathSeg.PATHSEG_UNKNOWN)
return null;
} else {
this._currentIndex++;
}
this._previousCommand = command;
switch (command) {
case window.SVGPathSeg.PATHSEG_MOVETO_REL:
return new window.SVGPathSegMovetoRel(owningPathSegList, this._parseNumber(), this._parseNumber());
case window.SVGPathSeg.PATHSEG_MOVETO_ABS:
return new window.SVGPathSegMovetoAbs(owningPathSegList, this._parseNumber(), this._parseNumber());
case window.SVGPathSeg.PATHSEG_LINETO_REL:
return new window.SVGPathSegLinetoRel(owningPathSegList, this._parseNumber(), this._parseNumber());
case window.SVGPathSeg.PATHSEG_LINETO_ABS:
return new window.SVGPathSegLinetoAbs(owningPathSegList, this._parseNumber(), this._parseNumber());
case window.SVGPathSeg.PATHSEG_LINETO_HORIZONTAL_REL:
return new window.SVGPathSegLinetoHorizontalRel(owningPathSegList, this._parseNumber());
case window.SVGPathSeg.PATHSEG_LINETO_HORIZONTAL_ABS:
return new window.SVGPathSegLinetoHorizontalAbs(owningPathSegList, this._parseNumber());
case window.SVGPathSeg.PATHSEG_LINETO_VERTICAL_REL:
return new window.SVGPathSegLinetoVerticalRel(owningPathSegList, this._parseNumber());
case window.SVGPathSeg.PATHSEG_LINETO_VERTICAL_ABS:
return new window.SVGPathSegLinetoVerticalAbs(owningPathSegList, this._parseNumber());
case window.SVGPathSeg.PATHSEG_CLOSEPATH:
this._skipOptionalSpaces();
return new window.SVGPathSegClosePath(owningPathSegList);
case window.SVGPathSeg.PATHSEG_CURVETO_CUBIC_REL:
var points = {x1: this._parseNumber(), y1: this._parseNumber(), x2: this._parseNumber(), y2: this._parseNumber(), x: this._parseNumber(), y: this._parseNumber()};
return new window.SVGPathSegCurvetoCubicRel(owningPathSegList, points.x, points.y, points.x1, points.y1, points.x2, points.y2);
case window.SVGPathSeg.PATHSEG_CURVETO_CUBIC_ABS:
var points = {x1: this._parseNumber(), y1: this._parseNumber(), x2: this._parseNumber(), y2: this._parseNumber(), x: this._parseNumber(), y: this._parseNumber()};
return new window.SVGPathSegCurvetoCubicAbs(owningPathSegList, points.x, points.y, points.x1, points.y1, points.x2, points.y2);
case window.SVGPathSeg.PATHSEG_CURVETO_CUBIC_SMOOTH_REL:
var points = {x2: this._parseNumber(), y2: this._parseNumber(), x: this._parseNumber(), y: this._parseNumber()};
return new window.SVGPathSegCurvetoCubicSmoothRel(owningPathSegList, points.x, points.y, points.x2, points.y2);
case window.SVGPathSeg.PATHSEG_CURVETO_CUBIC_SMOOTH_ABS:
var points = {x2: this._parseNumber(), y2: this._parseNumber(), x: this._parseNumber(), y: this._parseNumber()};
return new window.SVGPathSegCurvetoCubicSmoothAbs(owningPathSegList, points.x, points.y, points.x2, points.y2);
case window.SVGPathSeg.PATHSEG_CURVETO_QUADRATIC_REL:
var points = {x1: this._parseNumber(), y1: this._parseNumber(), x: this._parseNumber(), y: this._parseNumber()};
return new window.SVGPathSegCurvetoQuadraticRel(owningPathSegList, points.x, points.y, points.x1, points.y1);
case window.SVGPathSeg.PATHSEG_CURVETO_QUADRATIC_ABS:
var points = {x1: this._parseNumber(), y1: this._parseNumber(), x: this._parseNumber(), y: this._parseNumber()};
return new window.SVGPathSegCurvetoQuadraticAbs(owningPathSegList, points.x, points.y, points.x1, points.y1);
case window.SVGPathSeg.PATHSEG_CURVETO_QUADRATIC_SMOOTH_REL:
return new window.SVGPathSegCurvetoQuadraticSmoothRel(owningPathSegList, this._parseNumber(), this._parseNumber());
case window.SVGPathSeg.PATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS:
return new window.SVGPathSegCurvetoQuadraticSmoothAbs(owningPathSegList, this._parseNumber(), this._parseNumber());
case window.SVGPathSeg.PATHSEG_ARC_REL:
var points = {x1: this._parseNumber(), y1: this._parseNumber(), arcAngle: this._parseNumber(), arcLarge: this._parseArcFlag(), arcSweep: this._parseArcFlag(), x: this._parseNumber(), y: this._parseNumber()};
return new window.SVGPathSegArcRel(owningPathSegList, points.x, points.y, points.x1, points.y1, points.arcAngle, points.arcLarge, points.arcSweep);
case window.SVGPathSeg.PATHSEG_ARC_ABS:
var points = {x1: this._parseNumber(), y1: this._parseNumber(), arcAngle: this._parseNumber(), arcLarge: this._parseArcFlag(), arcSweep: this._parseArcFlag(), x: this._parseNumber(), y: this._parseNumber()};
return new window.SVGPathSegArcAbs(owningPathSegList, points.x, points.y, points.x1, points.y1, points.arcAngle, points.arcLarge, points.arcSweep);
default:
throw "Unknown path seg type."
}
}
var builder = new Builder();
var source = new Source(string);
if (!source.initialCommandIsMoveTo())
return [];
while (source.hasMoreData()) {
var pathSeg = source.parseSegment();
if (!pathSeg)
return [];
builder.appendSegment(pathSeg);
}
return builder.pathSegList;
}
}
}());
//The MIT License (MIT)
//
//Copyright (c) 2015 Satoshi Fujiwara
//
//Permission is hereby granted, free of charge, to any person obtaining a copy
//of this software and associated documentation files (the "Software"), to deal
//in the Software without restriction, including without limitation the rights
//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
//copies of the Software, and to permit persons to whom the Software is
//furnished to do so, subject to the following conditions:
//
//The above copyright notice and this permission notice shall be included in
//all copies or substantial portions of the Software.
//
//THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
//IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
//FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
//AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
//LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
//OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
//THE SOFTWARE.
/// <reference path="http://cdnjs.cloudflare.com/ajax/libs/d3/3.5.2/d3.js" />
/// <reference path="http://cdnjs.cloudflare.com/ajax/libs/three.js/r70/three.js" />
/// <reference path="..\intellisense\q.intellisense.js" />
"use strict";
// Node.js で動作しているか
(function () {
var isNode = (typeof process !== "undefined" && typeof require !== "undefined");
// ブラウザ上(非Node.js)で動作しているか
var isBrowser = !isNode
// node-webkitで動作しているか
var isNodeWebkit;
try {
isNodeWebkit = isNode ? (typeof require('nw.gui') !== "undefined") : false;
} catch (e) {
isNodeWebkit = false;
}
if ((isBrowser || isNodeWebkit) && !window['SF']) {
window.SF = {};
}
function mapArray(array){
return array.map(function(d){
if('metadata' in d){
return objArrays[d.metadata.type].factory(d);
} else {
return d;
}
});
}
var objArrays = {
'Vector2': {
factory: function (json) {
var obj = json.object;
return new THREE.Vector2(obj.x, obj.y);
}
},
'Vector3': {
factory: function (json) {
var obj = json.object;
return new THREE.Vector3(obj.x, obj.y, obj.z);
}
},
'EllipseCurve': {
factory: function (json) {
var obj = json.object;
return new THREE.EllipseCurve(obj.aX, obj.aY, obj.xRadius, obj.yRadius, obj.aStartAngle, obj.aEndAngle, obj.aClockwise);
}
},
'ArcCurve': {
factory: function (json) {
var obj = json.object;
return new THREE.ArcCurve(obj.aX, obj.aY, obj.xRadius, obj.aStartAngle, obj.aEndAngle, obj.aClockwise);
}
},
'ClosedSplineCurve3': {
factory: function (json) {
var obj = json.object;
if(obj['points']){
var points = mapArray(obj.points);
return new THREE.ClosedSplineCurve3(points);
}
return new THREE.ClosedSplineCurve3();
}
},
'CubicBezierCurve': {
factory: function (json) {
var o = json.object;
return new THREE.CubicBezierCurve(
objArrays[o.v0.metadata.type].factory(o.v0),
objArrays[o.v1.metadata.type].factory(o.v1),
objArrays[o.v2.metadata.type].factory(o.v2),
objArrays[o.v3.metadata.type].factory(o.v3)
);
}
},
'CubicBezierCurve3': {
factory: function (json) {
var o = json.object;
return new THREE.CubicBezierCurve3(
objArrays[o.v0.metadata.type].factory(o.v0),
objArrays[o.v1.metadata.type].factory(o.v1),
objArrays[o.v2.metadata.type].factory(o.v2),
objArrays[o.v3.metadata.type].factory(o.v3)
);
}
},
'LineCurve': {
factory: function (json) {
var o = json.object;
return new THREE.LineCurve(
objArrays[o.v1.metadata.type].factory(o.v1),
objArrays[o.v2.metadata.type].factory(o.v2)
);
}
},
'LineCurve3': {
factory: function (json) {
var o = json.object;
return new THREE.LineCurve3(
objArrays[o.v1.metadata.type].factory(o.v1),
objArrays[o.v2.metadata.type].factory(o.v2)
);
}
},
'QuadraticBezierCurve': {
factory: function (json) {
var o = json.object;
return new THREE.QuadraticBezierCurve(
objArrays[o.v0.metadata.type].factory(o.v0),
objArrays[o.v1.metadata.type].factory(o.v1),
objArrays[o.v2.metadata.type].factory(o.v2)
);
}
},
'QuadraticBezierCurve3': {
factory: function (json) {
var o = json.object;
return new THREE.QuadraticBezierCurve3(
objArrays[o.v0.metadata.type].factory(o.v0),
objArrays[o.v1.metadata.type].factory(o.v1),
objArrays[o.v2.metadata.type].factory(o.v2)
);
}
},
'SplineCurve': {
factory: function(json){
var o = json.object;
if(o['points']){
var points = mapArray(o.points);
return new THREE.SplineCurve(points);
} else{
return new THREE.SplineCurve(points);
}
}
},
'SplineCurve3': {
factory: function(json){
var o = json.object;
if(o['points']){
var points = mapArray(o.points);
return new THREE.SplineCurve3(points);
} else{
return new THREE.SplineCurve3(points);
}
}
},
'CurvePath': {
factory:function(json){
var o = json.object;
var instance = new THREE.CurvePath();
if('curves' in o){
instance.curves = mapArray(o.curves);
}
if('bends' in o){
instance.bends = mapArray(o.bends);
}
instance.autoClose = o.autoClose;
return instance;
}
},
'Path': {
factory:function(json){
var o = json.object;
var instance = new THREE.Path();
if('curves' in o){
instance.curves = mapArray(o.curves);
}
if('bends' in o){
instance.bends = mapArray(o.bends);
}
if('actions' in o){
instance.actions = mapArray(o.actions);
}
instance.autoClose = o.autoClose;
return instance;
}
}
}
// 対象オブジェクトのプロトタイプにtoJSONメソッドを定義する
for (var name in objArrays) {
(function () {
var name_ = name;
THREE[name_].prototype.toJSON = function () {
return toJSONBase(this, name_);
};
})();
};
function toJSONBase(obj, name) {
var json = {
"metadata": {
"type": name,
},
"object": {}
};
for (var i in obj) {
if (typeof obj[i] !== 'function') {
json.object[i] = obj[i].toJSON ? obj[i].toJSON() : obj[i];
}
}
return json;
}
SF.deserialize = function (json) {
if (objArrays[json.metadata.type]) {
return objArrays[json.metadata.type].factory(json);
}
}
})();
//(function () {
// // EllipseCurve
// var tobj = new THREE.EllipseCurve(1, 2, 3, 4, 5, 6, 7);
// console.log(tobj);
// var jsonData = JSON.stringify(tobj);
// console.log(jsonData);
// var tobj2 = SF.deserialize(JSON.parse(jsonData));
// console.log(tobj2);
// // ArcCurve
// tobj = new THREE.ArcCurve(1, 2, 3, 4, 5, 6);
// console.log(tobj);
// jsonData = JSON.stringify(tobj);
// console.log(jsonData);
// tobj2 = SF.deserialize(JSON.parse(jsonData));
// console.log(tobj2);
// // CubicBezierCurve
// tobj = new THREE.CubicBezierCurve(new THREE.Vector2(0, 0), new THREE.Vector2(1, 1), new THREE.Vector2(2, 2), new THREE.Vector2(3, 3));
// console.log(tobj);
// jsonData = JSON.stringify(tobj);
// console.log(jsonData);
// tobj2 = SF.deserialize(JSON.parse(jsonData));
// console.log(tobj2);
// // CubicBezierCurve3
// tobj = new THREE.CubicBezierCurve(new THREE.Vector3(0, 0, 0), new THREE.Vector3(1, 1, 1), new THREE.Vector3(2, 2, 2), new THREE.Vector3(3, 3, 3));
// console.log(tobj);
// jsonData = JSON.stringify(tobj);
// console.log(jsonData);
// tobj2 = SF.deserialize(JSON.parse(jsonData));
// console.log(tobj2);
// // LineCurve
// tobj = new THREE.LineCurve(new THREE.Vector2(0, 0), new THREE.Vector2(1, 1));
// console.log(tobj);
// jsonData = JSON.stringify(tobj);
// console.log(jsonData);
// tobj2 = SF.deserialize(JSON.parse(jsonData));
// console.log(tobj2);
// // LineCurve
// tobj = new THREE.LineCurve3(new THREE.Vector3(0, 0), new THREE.Vector3(1, 1));
// console.log(tobj);
// jsonData = JSON.stringify(tobj);
// console.log(jsonData);
// tobj2 = SF.deserialize(JSON.parse(jsonData));
// console.log(tobj2);
// // QuadraticBezierCurve
// tobj = new THREE.QuadraticBezierCurve(new THREE.Vector2(0, 0), new THREE.Vector2(1, 1),new THREE.Vector2(2,2));
// console.log(tobj);
// jsonData = JSON.stringify(tobj);
// console.log(jsonData);
// tobj2 = SF.deserialize(JSON.parse(jsonData));
// console.log(tobj2);
// // QuadraticBezierCurve3
// tobj = new THREE.QuadraticBezierCurve3(new THREE.Vector3(0, 0,0), new THREE.Vector3(1, 1,1),new THREE.Vector3(2,2,2));
// console.log(tobj);
// jsonData = JSON.stringify(tobj);
// console.log(jsonData);
// tobj2 = SF.deserialize(JSON.parse(jsonData));
// console.log(tobj2);
//})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment