You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I tried getting alpha transparencies working following the instructions here: http://imager.perl.org/docs/Imager/Color.html
However, no matter what I do, the alpha channel doesn�t seem to work. I may be doing something wrong, or it may be broken. I thought I should report it to find out.
I�ve attached some sample code and a sample output image.
On Tue Jul 22 11:40:15 2014, jt@plainblack.com wrote:
> I tried getting alpha transparencies working following the
> instructions here: http://imager.perl.org/docs/Imager/Color.html
>
> However, no matter what I do, the alpha channel doesn�t seem to work.
> I may be doing something wrong, or it may be broken. I thought I
> should report it to find out.
>
> I�ve attached some sample code and a sample output image.
It's more a missing feature.
By default, box(), and most other methods, replace the underlying pixel rather than combining with it.
If you sample had used a 4 channel image, the blue part of the image would have been translucent.
This is something I plan to change, someday, but there are other issues I want to fix first.
You can use fill objects (and Imager's shortcut for fill objects) to do transparent fills:
$image->box(fill => { solid => $color, combine => "normal" },
xmin => 150, ymin => 150, xmax => 250, ymax => 250)
or die $image->errstr;
Note that setting "filled" to non-zero as you did causes the "fill" parameter to be ignored.
Tony
The text was updated successfully, but these errors were encountered:
Migrated from rt.cpan.org#97404 (status was 'open')
Requestors:
Attachments:
From jt@plainblack.com on 2014-07-22 15:40:15
:
From tonyc@cpan.org on 2014-07-24 13:21:44
:
The text was updated successfully, but these errors were encountered: