[swfmill] Problem with colors in SVG import

Jesse Welton swfmill at jwelton.v-space.org
Thu Nov 6 06:32:08 PST 2008


I have some SVG resources created in Inkscape 0.46 which I would like
to import to a Flash project.  Using swfmill 0.2.12, the geometry of
these resources appears to be alright, but the colors are not handled
correctly.  Most objects end up rendered as solid black, regardless of
the colors I have set on them.

Sample files attached.  Any help would be appreciated.

-Jesse
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test.xml
Type: text/xml
Size: 264 bytes
Desc: not available
URL: <http://osflash.org/pipermail/swfmill_osflash.org/attachments/20081106/e1a04060/attachment-0001.xml>
-------------- next part --------------
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<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"
   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
   width="640"
   height="480"
   id="svg2980"
   sodipodi:version="0.32"
   inkscape:version="0.46"
   sodipodi:docname="test.svg"
   inkscape:output_extension="org.inkscape.output.svg.inkscape"
   version="1.0">
  <defs
     id="defs2982">
    <linearGradient
       id="linearGradient4374">
      <stop
         style="stop-color:#fffff5;stop-opacity:0.40000001;"
         offset="0"
         id="stop4376" />
      <stop
         id="stop5400"
         offset="0.5"
         style="stop-color:#87928c;stop-opacity:0.05154639;" />
      <stop
         style="stop-color:#0f233f;stop-opacity:0.39175257;"
         offset="1"
         id="stop4378" />
    </linearGradient>
    <inkscape:perspective
       sodipodi:type="inkscape:persp3d"
       inkscape:vp_x="0 : 526.18109 : 1"
       inkscape:vp_y="0 : 1000 : 0"
       inkscape:vp_z="744.09448 : 526.18109 : 1"
       inkscape:persp3d-origin="372.04724 : 350.78739 : 1"
       id="perspective2988" />
  </defs>
  <sodipodi:namedview
     id="base"
     pagecolor="#ffffff"
     bordercolor="#666666"
     borderopacity="1.0"
     gridtolerance="10000"
     guidetolerance="10"
     objecttolerance="10"
     inkscape:pageopacity="0.0"
     inkscape:pageshadow="2"
     inkscape:zoom="0.98994949"
     inkscape:cx="321.69986"
     inkscape:cy="314.68677"
     inkscape:document-units="px"
     inkscape:current-layer="layer1"
     showgrid="false"
     inkscape:window-width="709"
     inkscape:window-height="701"
     inkscape:window-x="32"
     inkscape:window-y="34" />
  <metadata
     id="metadata2985">
    <rdf:RDF>
      <cc:Work
         rdf:about="">
        <dc:format>image/svg+xml</dc:format>
        <dc:type
           rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
      </cc:Work>
    </rdf:RDF>
  </metadata>
  <g
     inkscape:label="Layer1"
     inkscape:groupmode="layer"
     id="layer1">
    <rect
       style="fill:#00ffff;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
       id="rect4575"
       width="88.893425"
       height="54.548237"
       x="28.284271"
       y="20.380592" />
    <path
       style="opacity:1;fill:#00ffff;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
       d="M 119.19701,96.131983 C 94.662418,96.131983 74.759508,115.5925 74.759508,139.56948 C 74.759508,153.85141 81.831458,166.52769 92.728258,174.44448 C 88.429548,179.78038 85.853258,186.42673 85.853258,193.63198 C 85.853258,211.19651 101.01727,225.44448 119.69701,225.44448 C 129.29632,225.44448 137.97379,221.67563 144.13451,215.63198 C 152.87551,218.67451 162.55436,220.38198 172.72826,220.38198 C 211.76055,220.38198 243.44701,195.48771 243.44701,164.81948 C 243.44701,134.15125 211.76056,109.28823 172.72826,109.28823 C 165.90075,109.28823 159.31932,110.0549 153.07201,111.47573 C 144.91718,102.09533 132.76922,96.131981 119.19701,96.131983 z"
       id="path2388" />
    <path
       style="opacity:1;fill:#ffffff;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
       d="M 118.21875,102.15625 C 93.679948,101.4757 73.24528,129.34248 83,152.375 C 85.842513,160.65483 93.082354,166.39475 98.125,173.09375 C 97.971991,180.79551 90.258831,186.31941 91.78125,194.4375 C 92.363378,212.98826 115.18854,225.6134 131.56356,216.86079 C 137.40324,214.5592 142.53849,207.60273 149.15625,211.25 C 176.36489,218.60598 209.16958,213.35312 227.875,190.6875 C 238.23573,178.27024 240.94658,159.37305 232.0625,145.25 C 219.1831,123.1366 191.78919,113.73786 167.21875,115.5 C 160.30638,115.75447 151.79095,119.60152 146.50449,113.21395 C 138.96354,105.81983 128.82278,101.75764 118.21875,102.15625 z"
       id="path3166" />
  </g>
</svg>


More information about the swfmill mailing list