wrap_rsvg
is an Eiffel binding of Librsv C API
using WrapC tool.
This is librsvg - A small library to render Scalable Vector Graphics (SVG), associated with the GNOME Project. It renders SVG files to Cairo surfaces. Cairo is the 2D, antialiased drawing library that GNOME uses to draw things to the screen or to generate output for printing.
- WrapC tool.
- Librsvg C API
Here I will describe the installation for Ubuntu check the librsvg documentation to know how to install it in other Platforms.
We are using version 2.40.20
apt-get install -y gcc make rustc cargo \
automake autoconf libtool gettext itstool \
libgdk-pixbuf2.0-dev libgirepository1.0-dev \
gtk-doc-tools git \
libxml2-dev libcairo2-dev libpango1.0-dev libcroco3-dev
If you are compiling a tarball:
./configure
make
make install
See the INSTALL file for details on options you can pass to the configure script to select where to install the compiled library.
If you are compiling from a git checkout:
./autogen.sh
make
make install
If you got the error gdk-pixbuf-query-loaders not found in path
sudo ln -s /usr/lib/*/gdk-pixbuf-2.0/gdk-pixbuf-query-loaders /usr/local/bin/gdk-pixbuf-query-loaders
Now try again to compile and install the library.
Using vckpg
vckpg install librsvg:x64-windows
Copy the .lib
files rsvg-2.40.lib
and cairo.lib
to $ECF_CONFIG_PATH/C/lib
.
Be sure to have the dlls
in the PATH before running the example.
Work in progress
- SVG Rendering to PNG using Cairo
Shows how to SVG Rendering to PNG using Cairo
.
Before to use the examples you will need to compile the C glue code, go to
library/generated_wrapper/c/src
and run
finish_freezing --library
It will copy the C lib eif_librsvg.a
to $ECF_CONFIG_PATH/C/spec/$(ISE_PLATFORM)/lib/
or eif_librsvg.lib
to $ECF_CONFIG_PATH/C/spec/$ISE_C_COMPILER/$ISE_PLATFORM/lib