SFML community forums

Help => General => Topic started by: Aldasa on April 22, 2012, 12:46:32 am

Title: SVG Images
Post by: Aldasa on April 22, 2012, 12:46:32 am
How can I load use SVG images with sfml?

Ive tried the snippet in the WIKI, using cairo, but I get a lot of linking errors.

Has anybody tried loading SVG images recently? Whats the best way to go about it?
Title: Re: SVG Images
Post by: Laurent on April 22, 2012, 08:35:30 am
SFML doesn't support the SVG format, so using another library is the only solution.
Title: Re: SVG Images
Post by: fer_t on October 09, 2015, 06:32:49 pm
But it would be a nice feature, because it would save a lot of diskspace.
If I only need one SVG (which is also very easy to compress) instead of a lot of png files or one big and scale it.
But I think this is a lot of work.
Title: Re: SVG Images
Post by: Gambit on October 09, 2015, 06:55:16 pm
Parsing svg files is quite difficult and it has been asked many times on here. Yes it would be handy and it IS technically in the realm of multimedia but as I mentioned I don't believe it's as simple as JPEG/png support.
Title: Re: SVG Images
Post by: Laurent on October 09, 2015, 08:21:05 pm
Parsing the SVG format is one thing, rendering vector graphics is another story...
Title: Re: SVG Images
Post by: Nexus on October 09, 2015, 08:33:11 pm
But it would be a nice feature, because it would save a lot of diskspace.
Besides disk space not being a critical resource nowadays, I don't think game graphics are a good example of a format that would benefit of vector graphics. With their extreme detail and heavy use of colors, shades, gradients etc., game graphics are usually better represented as raster graphics.