[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: png cropping
From: |
Jonathan Kulp |
Subject: |
Re: png cropping |
Date: |
Wed, 17 Sep 2008 18:08:19 -0500 |
User-agent: |
Thunderbird 2.0.0.16 (X11/20080724) |
Ok I changed a couple of things to make it even more flexible. I
changed pnmto__ to ppmto__, giving quite a few more output options.
I've suggested a few in the script. Also added an option to choose
either gif or png when choosing transparent background. this is fun :)
Jon
script attached this time...
Patrick Horgan wrote:
Jonathan Kulp wrote:
I'm guessing that one of the netpbm tools will handle transparency,
it's just a matter of figuring out which one. Didn't this come up on
a recent thread? I seem to remember trying it out on something and
getting a transparent background. When I get some time later I'll
look into it. It would be simple enough to add a prompt asking if
you'd like a transparent background, I guess.
Now that you mention it that rings a bell with me too! I'll have to
search---
giftoppm foobar.gif | ppmtogif -transparent '#rgb' > fooquux.gif
works if you want gif. First translate to ppm, then translate back to
gif with the -transparent flag specifying which color, (in this case
#fff) will be transparent.
pnmtopng has the transparent argument, but pnmtotiff and jpeg don't
since they don't support transparency...so, using your script, if you
want transparency, you have to choose png for the output, then on the
translation step from ppm just add the appropriate flags. I just tried
it adding a quick -transparent '#ffffff' to the command line and then
selecting png so it would work. It worked like a charm:)
--
Jonathan Kulp
http://www.jonathankulp.com
lilyimage
Description: Text document
- Re: png cropping, Jonathan Kulp, 2008/09/17
- Re: png cropping, Patrick Horgan, 2008/09/17
- Message not available
- Re: png cropping, Patrick Horgan, 2008/09/17
- Re: png cropping, Jonathan Kulp, 2008/09/17
- Re: png cropping,
Jonathan Kulp <=
- Re: png cropping, Patrick Horgan, 2008/09/18
- Re: png cropping, Jonathan Kulp, 2008/09/18
- Re: png cropping, Jonathan Kulp, 2008/09/18
- Re: png cropping, Patrick Horgan, 2008/09/18
- Re: png cropping, Jonathan Kulp, 2008/09/19
- Re: png cropping, Patrick Horgan, 2008/09/19
- Re: png cropping, Jonathan Kulp, 2008/09/19
- Re: png cropping, Josh Parmenter, 2008/09/19
- Re: png cropping, Patrick Horgan, 2008/09/19
- Re: png cropping, Josh Parmenter, 2008/09/19