Transparency in Windows GDI
How can I do transparent blits in Windows GDI? I'm trying to stay away from DX, but I'll use it if I have to. BTW, I can't be sure whether the people who use it will be using Windows versions later than 95. Basically I'm looking for the color keying that DX does -- just eliminating the black pixels from the source bitmap.
If there's no way to do it with BitBlt, then perhaps I can modify the bitmap bits directly? Would it be easy or hard to accomplish color keying with this method? (i.e., could I simply set the black pixels of the source equal to the same pixels of the destination, making it look transparent?) How can I access a bitmap handle as a chunk of memory?
Thanks!
- null_pointer
Edited by - null_pointer on 3/21/00 8:05:02 AM
There is a new API function called TransparentBlt, but it is only available for Win98 and up...
Otherwise, you will have to do it the old fashioned way (afaik)..here is a link that might get you started:
http://support.microsoft.com/support/kb/articles/Q79/2/12.ASP
Luck!
-mordell
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement