From: Mark B. <mb...@0x...> - 2000-04-20 20:57:17
|
On Thu, 20 Apr 2000, Eric Jacobs wrote: > > > > Wow! Not only did that make the PNG and BMP times the same, it cut > > them by about 40%! Very nice. Thanks for your help. > > I second that wow! However, I'm having a little problem. Whenever I > call either convert() or convert_display(), the alpha channel seems > to be lost. This is coming off of PNGs. If I don't call the convert, > the blit is much slower, but the alpha is preserved. Any ideas? When you convert a surface to the format of the video surface, you're going to lose your per-pixel alpha information. This is because the image is literally converted to the format of the display image. So a 32-bit RGBA PNG is converted to a 16-bit 5-5|6-5 video surface, or a 24-bit surface, or so on and so forth. If you want to preserve the per-pixel alpha information, don't convert the surface. |