Page 1 of 1

label: with partially transparent background

Posted: 2015-06-26T13:00:26-07:00
by geitda
The label: pseudo-image doesn't seem to handle working with transparent backgrounds.

ImageMagick-6.9.1-Q16 64-bit on Windows 7

Code: Select all

convert -depth 8 -background #00CC0033 -pointsize 72 label:"This is a label" png32:label.png
results in
Image

I had to use -depth 8 as convert was giving a 64-bit RGBA (16-bit per channel) PNG without it. After adding the -depth 8, I found that the result must have been expressible as an PLTE+tRNS PNG, as that's what I initially got, so I added the png32: format specifier. If I understand correctly how png:32 works, then that's all I actually need and can skip the -depth 8, but I wanted to show exactly what I used to generate the above image.
As you can see, the transparency is wrong inside the letters. Work-arounds are welcome, but this probably needs fixed within the label: pseudo-image operation. Fully transparent works as expected (like #00CC0000), so I could probably compose that over a separately generated transparent background.

Re: label: with partially transparent background

Posted: 2015-06-26T13:36:56-07:00
by snibgo
With your command, versions 6.9.1-0 and the current 6.9.1-6, on Windows 8.1, I don't get the problem you report. The background is a consistent #0c03.

Exactly what version are you using? "convert -version"

Re: label: with partially transparent background

Posted: 2015-06-29T05:47:08-07:00
by geitda

Code: Select all

convert -version
Version: ImageMagick 6.9.1-2 Q16 x64 2015-04-14 http://www.imagemagick.org
Copyright: Copyright (C) 1999-2015 ImageMagick Studio LLC
License: http://www.imagemagick.org/script/license.php
Features: DPC Modules OpenMP
Delegates (built-in): bzlib cairo freetype jbig jng jp2 jpeg lcms lqr openexr
pangocairo png ps rsvg tiff webp xml zlib

Re: label: with partially transparent background

Posted: 2015-06-29T06:04:14-07:00
by geitda
Upgraded to 6.9.1-6 and the problem is indeed resolved. Not sure what was going on, and I didn't realize I was already nearly 3 months behind, but thanks.