View Single Post
Old Apr 7th, 2005, 4:34 AM   #6
Cerulean
Professional Programmer
 
Cerulean's Avatar
 
Join Date: Apr 2005
Location: London, England
Posts: 459
Rep Power: 4 Cerulean is on a distinguished road
IIRC == If I Recall Correctly.

I see. You can load the image and make all white regions transparent by passing -1 to this `load_image` function, which returns the image and a rectangle representing the size, but you don't want that. You want whatever is returned by pygame.image.load.
Like I said, I think it will "just work" if you use a PNG instead of a BMP - PNG's have native support for transparency and semi-transparency. Open up the bmp file in your favourite image editor with support for drawing transparent pixels (the GIMP, Photoshop, Kolourpaint) and replace all the white pixels with transparent pixels. Just save it as a png file and then load that.

Good luck!
Cerulean is offline   Reply With Quote