开发者

Loading SVG files with python and pygame [duplicate]

This question already has answers here: Closed 11 years ago.

Possible Duplicate:

SVG rendering in a PyGame ap开发者_如何转开发plication

Can I load .svg files created by inkscape to python via pygame? And if so, how I can do it?


No you cannot, PyGame supports following image formats:

  • JPG
  • PNG
  • GIF (non animated)
  • BMP
  • PCX
  • TGA (uncompressed)
  • TIF
  • LBM (and PBM)
  • PBM (and PGM, PPM)
  • XPM

You can however rasterize that SVG using Cairo RSVG library. There is some documentation for that on PyGame's web.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜