in reply to Re: Image Conversion: SVG to PNG
in thread Image Conversion: SVG to PNG

G'day Rob,

Many thanks for testing the Image::LibRSVG installation and providing such detailed feedback.

I'll wait for other replies but, in the absence of any better ideas, and given the PNG files Image::LibRSVG produces are well under half the size of those from convert, I'll probably go with this module.

Thanks also for offers of help with a PPM package and Windows build. My current, day-to-day OS is Mac OS X — which is where I'll do the initial development — but, when written, the code will also be used on a Windows platform: that's some way off at this stage.

— Ken

Replies are listed 'Best First'.
Re^3: Image Conversion: SVG to PNG
by syphilis (Archbishop) on Apr 24, 2017 at 09:10 UTC
    Thanks also for offers of help with a PPM package and Windows build

    A little extra FYI:
    I ran a "ppm install" of Image-LibRSVG on "strawberry-perl-ld 5.24.0.1 #1 Wed May 11 11:19:43 2016 x64" (MSWin32-x64-multi-thread-ld) and ran your one-liners on the first svg file that came to hand.
    The generated png files look fine to me.

    Cheers,
    Rob

      ++ Again, many thanks for the effort you've put in on this: it is much appreciated.

      The only Windows box I currently have available is an old laptop, which sits in its bag for most of the year, and only sees the light of day every few months or so: I'll probably end up using this for the initial (deployment) tests. It's running Strawberry Perl (v5.12), so good to know Image::LibRSVG works with that. And, although the laptop is now fairly ancient, it's probably about a similar vintage to Image::LibRSVG, so I don't foresee any issues in that area.

      — Ken

        running Strawberry Perl (v5.12), so good to know Image::LibRSVG works with that

        I was a little concerned that there might be problems with such an old version of Strawberry, but it works fine on my 32-bit Strawberry 5.12.2.
        I was more concerned about the capability of that old ppm utility, but it did the job despite emitting some strange warnings.

        Those early builds of Strawberry Perl don't have the sisyphusion repo in their list of repositories, so if you want to run:
        ppm install Image-LibRSVG or even: ppm install http://www.sisyphusion.tk/ppm/Image-LibRSVG.ppd
        then you'll need to add the sisyphusion repo to the list.
        There's probably a command to do that, but I simply inserted:
        <REPOSITORY LOCATION="http://www.sisyphusion.tk/ppm" NAME="Sisyphusion +" SUMMARYFILE="searchsummary.ppm" />
        just under the 2 existing "REPOSITORY LOCATION" entries in perl/vendor/lib/ppm.xml.

        Alternatively you can just run through the dependencies as separate installs:
        ppm install http://www.sisyphusion.tk/ppm/PPM-Sisyphusion.ppd ppm install http://www.sisyphusion.tk/ppm/PPM-Sisyphusion-Glib_dll.ppd ppm install http://www.sisyphusion.tk/ppm/PPM-Sisyphusion-Cairo_dll.pp +d ppm install http://www.sisyphusion.tk/ppm/PPM-Sisyphusion-Pango_dll.pp +d ppm install http://www.sisyphusion.tk/ppm/PPM-Sisyphusion-Gtk2_dll.ppd ppm install http://www.sisyphusion.tk/ppm/PPM-Sisyphusion-Image_LibRSV +G_dll.ppd ppm install http://www.sisyphusion.tk/ppm/Image-LibRSVG.ppd
        (Of course, you might find a more appealing solution before you ever get to try this ppm package out. That wouldn't upset me in any way at all.)

        Cheers,
        Rob