Discussion:
Can't see any SVG Symbol with SVGCAIRO support
Ludovic Gnemmi
2014-04-05 07:37:13 UTC
Permalink
Hi list,
I've been trying to build mapserver (6.4.1) with SVG Symbol support on
CentOS6. I did not succeded with libsrvg (too much dependency problem). So
I've built libsvg (0.1.4) and cairo-svg (0.1.6). exported those package
config paths. i've also installed Cairo 1.8.8 with a ditsrib package.

I succedded in building mapserver with SVGCAIRO support. But i can't see my
symbol :( I don't see anything in mapserver log file.

GetMap requets sometimes crash without any message in mapserver log file. i
only see something like this in my system message log file :

Apr 5 09:22:45 myserver abrtd: Executable '/var/www/cgi-bin/mapserv'
doesn't belong to any package and ProcessUnpackaged is set to 'no'
Apr 5 09:22:45 myserver abrtd: 'post-create' on
'/var/spool/abrt/ccpp-2014-04-05-09:22:45-2817' exited with 1
Apr 5 09:22:45 myserver abrtd: Deleting problem directory
'/var/spool/abrt/ccpp-2014-04-05-09:22:45-2817'

I really think that it is related to SVGCAIRO support but i don't know how
to correct this problem.

any help would be very welcome :/

Ludovic



--
View this message in context: http://osgeo-org.1560.x6.nabble.com/Can-t-see-any-SVG-Symbol-with-SVGCAIRO-support-tp5133260.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
Ludovic Gnemmi
2014-04-07 16:02:11 UTC
Permalink
i finally found that this problem was depending on svg file type.

Some SVG files doesn't work with mapserver built with libsvg/libsvg-cairo.
IE svg files provided with Qgis.

These files cause assert (segmentation fault) => (freeSVGCache). The
renderer_cache come with a NULL svg handle.

I had to change all my SVG files. (With Inkscape : Save As PLAIN SVG file)

This problem doesn't occur with librsvg but only with libsvg/libsvg-cairo.


Ludovic



--
View this message in context: http://osgeo-org.1560.x6.nabble.com/Can-t-see-any-SVG-Symbol-with-SVGCAIRO-support-tp5133260p5133615.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
Stephen Woodbridge
2014-04-07 17:08:03 UTC
Permalink
Post by Ludovic Gnemmi
i finally found that this problem was depending on svg file type.
Some SVG files doesn't work with mapserver built with libsvg/libsvg-cairo.
IE svg files provided with Qgis.
These files cause assert (segmentation fault) => (freeSVGCache). The
renderer_cache come with a NULL svg handle.
I had to change all my SVG files. (With Inkscape : Save As PLAIN SVG file)
This problem doesn't occur with librsvg but only with libsvg/libsvg-cairo.
Yes, this was a common problem when I original did a bunch of test with
Thomas. I was using a version of mapserv-6.1-dev in the original tests
and put together this test suite:

http://imaptools.com:8080/svg-test/

Most all of these SVG files would display correctly in mapserver.

I just put the test suite back up and based on:

MapServer version 6.2.1 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG SUPPORTS=PROJ
SUPPORTS=GD SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=CAIRO
SUPPORTS=SVG_SYMBOLS SUPPORTS=ICONV SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER
SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT
SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI
SUPPORTS=THREADS SUPPORTS=GEOS INPUT=JPEG INPUT=POSTGIS INPUT=OGR
INPUT=GDAL INPUT=SHAPEFILE

I looks like I'm seeing a lot more failures.

The trick was to flatten the SVG and save them a plain. Basically some
complex and nested symbols did not work and text objects needed to be
exploded to vectors.

I remember that there was some discussion about svg libraries and
licensing issues the impacted this but I forget the details.

Thomas - can you summarize the issues again?

Thanks,
-Steve W
Stephen Woodbridge
2014-04-07 17:37:59 UTC
Permalink
Post by Stephen Woodbridge
Post by Ludovic Gnemmi
i finally found that this problem was depending on svg file type.
Some SVG files doesn't work with mapserver built with
libsvg/libsvg-cairo.
IE svg files provided with Qgis.
These files cause assert (segmentation fault) => (freeSVGCache). The
renderer_cache come with a NULL svg handle.
I had to change all my SVG files. (With Inkscape : Save As PLAIN SVG file)
This problem doesn't occur with librsvg but only with
libsvg/libsvg-cairo.
Yes, this was a common problem when I original did a bunch of test with
Thomas. I was using a version of mapserv-6.1-dev in the original tests
http://imaptools.com:8080/svg-test/
Most all of these SVG files would display correctly in mapserver.
MapServer version 6.2.1 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG SUPPORTS=PROJ
SUPPORTS=GD SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=CAIRO
SUPPORTS=SVG_SYMBOLS SUPPORTS=ICONV SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER
SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT
SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI
SUPPORTS=THREADS SUPPORTS=GEOS INPUT=JPEG INPUT=POSTGIS INPUT=OGR
INPUT=GDAL INPUT=SHAPEFILE
I looks like I'm seeing a lot more failures.
The trick was to flatten the SVG and save them a plain. Basically some
complex and nested symbols did not work and text objects needed to be
exploded to vectors.
I remember that there was some discussion about svg libraries and
licensing issues the impacted this but I forget the details.
Thomas - can you summarize the issues again?
Here is another test which adds another column for additional comparison:

http://imaptools.com:8080/svg-test/index-agg-svg.html

It looks like some of the paths have changes especially in the osm
scalable symbols. I probably need to regenerate the the html and
mapserver map files based on the current set of symbols to fix the
broken paths.

Let me know if you need this done and I will try to find some time to
fix the test suite.

Thanks,
-Steve

Loading...