[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [pygame] Alpha Channel Speed Question



Lenard Lindstrom wrote:
On 27 Nov 2006 at 16:48, Kamilche wrote:

Lenard Lindstrom wrote:
On 22 Nov 2006 at 21:15, Kamilche wrote:

I have a question - Do you know of a way to get method 3 as outlined below to be faster? The necessity of doing all those extra blits to preserve the alpha channel is really slowing things down.

[snip]
Colorkeys are incompatible with per pixel alpha - set_alpha only works on pictures that don't have per pixel alpha.

Yes and no. Colorkey doesn't work on a surface with per pixel alpha. But a colorkey surface does alpha blit to a surface with per pixel alpha, preserving the destination surfaces alpha values. Colorkey is just fine if the night overlay only darkens the bitmap.



Hm, now I understand. Thanks a lot for explaining that!

--Kamilche