[SDL] Loading bitmaps with transparency?

Bill Kendrick nbs at sonic.net
Sat Mar 3 23:12:17 PST 2007


On Sun, Mar 04, 2007 at 02:06:25AM -0800, L-28C wrote:
> Yes, like sprites, only one part is shown... On bitmaps, there's no 
> blank-pixel, so the background shows white... :-/
> 
> I can't use any of the C++ libraries 'cause I'm on Lua.
> 
> Maybe transparency masks, where there's a separate black-and-white 
> bitmap with the black areas as the background and white areas as what I 
> want to show? Would that be best or no?

You want this:

http://www.libsdl.org/docs/html/sdlsetcolorkey.html

:)

-bill!


More information about the SDL mailing list