[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #36820] imread doesn't consider opacity in Mag
From: |
Andreas Weber |
Subject: |
[Octave-bug-tracker] [bug #36820] imread doesn't consider opacity in Magick::BilevelType, Patch included |
Date: |
Wed, 11 Jul 2012 08:47:42 +0000 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:10.0.5) Gecko/20100101 Firefox/10.0.5 Iceweasel/10.0.5 |
Follow-up Comment #2, bug #36820 (project octave):
This is the output of matlab:
>> [img,map,alpha]=imread('rect.png');
> size(img)
ans = 600 800 3
> size(map)
ans = 0 0
> size(alpha)
ans = 600 800
> mean(img(:))
ans = 0
mean(alpha(:))
ans = 5.66368125
> min(alpha(:))
ans = 0
> max(alpha(:))
ans = 255
* In contrast to octave, matlab returns a 600x800x3 (RGB) matrix instead of a
600x800x1 graylevel
* alpha channel is size 600x800 and corresponds to the image opacity but is
"inverted" to graphicsmagick: 0=transparent, 255=opaque. Therefore
mean(alpha)=255-249.34=5.66
btw, the original image was created with inkscape and then downscaled.
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?36820>
_______________________________________________
Nachricht gesendet von/durch Savannah
http://savannah.gnu.org/