[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: generating pdf and png but no ps

From: Jonathan Kulp
Subject: Re: generating pdf and png but no ps
Date: Fri, 03 Oct 2008 09:18:54 -0500
User-agent: Thunderbird (X11/20080925)


Your situation is perfectly suited for the script that Patrick Horgan and I wrote. Now, the script also crops the extra white space off, so you might need to edit the script a bit if you don't want the margins cropped off. Just look for the part in the loop that uses pnmcrop. It handles multipage files just fine, and it cleans up .ps files as part of the process. It's very easy to set the resolution and output format (png is default, but it also supports many other formats). Your command looks like this for a png output at 72 DPI:

lily2image -r=72 -f=png

You can also make a transparent background if you want, and you can set it to preview the converted files in your default image viewer with a -p flag.

The only dependency is the netpbm package, easily obtained from most linux repositories I would guess.

Script and manpage are attached.


Sebastian Menge wrote:
Am Fri, 3 Oct 2008 14:38:39 +0200
schrieb Sebastian Menge <address@hidden>:

How can I generate pdf and png but no ps?

Can I adjust resolution of the png? I just need thumbnails.

Is there a simple way to see (e.g. from the shell or an external
programming language) how many png-pages lilypond produced?

Ok, to clarify this a bit:

I'm invoking lilypond from a php-application and want to reduce the
number of shell commands as far as possible. I also dont want to tidy
up any mess that is generated but not needed. I just want the most
elegant way to generate a pdf and some thumbs to offer it on a web page.

And I know 'rm' and 'imagemagick' :-)

But it seems I need to write a wrapper for that.


lilypond-user mailing list

Jonathan Kulp

Attachment: lily2image.1
Description: Text document

Attachment: lily2image
Description: Text document

reply via email to

[Prev in Thread] Current Thread [Next in Thread]