Skip to content

WIP: image-loader: Add SVG support using librsvg

Link Mauve requested to merge linkmauve/weston:librsvg-support into main

SVG[1] is a vector format which is quite widespread on the Linux desktop, both for icons and for wallpapers.

librsvg[2] is a GNOME project doing rendering of SVG using cairo, which Weston is already using.

This patch only adds support for rendering it at the internal dimensions of the image, since all previous image formats supported are bitmap it didn’t make sense to allow re-rendering at a different resolution. A future improvement would be to let the user specify the wanted size so that the image will be rendered pixel perfect, without any scaling, even on HiDPI outputs and such.

[1] https://en.wikipedia.org/wiki/Scalable_Vector_Graphics [2] https://wiki.gnome.org/action/show/Projects/LibRsvg

Signed-off-by: Emmanuel Gil Peyrot linkmauve@linkmauve.fr


I tagged this MR WIP because I would prefer it to be merged after the next release, which is also why I didn’t touch autotools at all.

Here is a screenshot: wayland-screenshot-2019-02-07_15-54-56

Edited by Daniel Stone

Merge request reports

Loading