I'm not sure if this is the right place to ask, but anyhow. I have a bit
of a problem with SVG images in my Activity.

I have a collection of .SVG images I designed with Inkscape. They are
not saved in Inkscape .SVG, but "plain .SVG", according to Inkscape.

Now, I am attempting to load these aforementioned images via a function
that looks much like this:

def load_svg(name, width=card_width(), height=card_height()):

    svg = open(os.path.join('data', name)).read()
    load = svgsprite.SVGSprite(svg, size=(width, height))
    if load:
        rendered = load._render(width, height)
        pygame.image.save(rendered, os.path.join('data', name + '.tga'))
        return rendered
    else: return None


When I do so, I get mixed results. Some images partially load, but are
almost fully transparent, and are almost invisible. Others simply
produce a completely transparent image. I've attached two example
images, their .SVG files and .TGA rendered version.

Can anyone help me out with this? Am I doing something wrong?

Thanks.

<<inline: example1.svg>>

<<inline: example1.tga>>

<<inline: example2.svg>>

<<inline: example2.tga>>

_______________________________________________
Devel mailing list
[email protected]
http://lists.laptop.org/listinfo/devel

Reply via email to