On 21 November 2013 14:22, hilaire <[email protected]> wrote:

> The problem is really not related to PNG bitmap as the same issue can be
> exposed with simple, as in this example:
>
> | morph rectangle |
> rectangle := RectangleMorph new color: (Color red alpha: 0.5).
> morph := TransformationMorph new asFlexOf: rectangle.
> morph scale: 0.7.
> morph openInWorld
>
>
> In this example, the red appears darker once the rectangle is scaled.
>
> Is it something related to the Blit ? I reallz don't know where to look.
>
>
no idea..

Except that while adopting cairo surfaces i also has odd transparency
issues until i realized
that cairo surface stores pixel data using premultiplied alpha format,e.g.:

pixelColor = (R*A, G*A, B*A, A)

while bitblt assumes it is (R,G,B,A)



> Hilaire
>
>
>
> --
> View this message in context:
> http://forum.world.st/Scaled-PNG-image-tp4723754p4723975.html
> Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
>
>


-- 
Best regards,
Igor Stasenko.

Reply via email to