|
From: | Jan-Åke Larsson |
Subject: | Re: [Dvipng] accessing alpha channel |
Date: | Fri, 20 May 2005 12:42:24 +0200 |
User-agent: | Debian Thunderbird 1.0.2 (X11/20050331) |
Bob McElrath wrote:
I use the following sequence of commands using python's Imaging library: im = Image.open(os.path.join(workingDir, imname)) im2 = Image.new('RGBA', (im.size[0], im.size[1]), (255,255,255)) im2.paste(im, (0, 0)) To explicitly create an alpha channel I use: alpha = ImageChops.invert(im.convert('L')) im = im.putalpha(alpha) This creates a PNG with a proper alpha channel. I would VERY much like it if dvipng did this for me. I would love it if you could hack it in to dvipng.
Unless I am mistaken, the CVS version of dvipng does create a proper-alpha PNG if you use '-bg Transparent' (capital T). This is to be released very soon as dvipng-1.6. Please try it out, I'd like to remove any remaining flaws. /JÅ
[Prev in Thread] | Current Thread | [Next in Thread] |