Sign in to follow this  
Godlike

TransparentBlt problem

Recommended Posts

When I use the TransparentBlt I get this error from the C++ Builder 6 linker. [Linker Error] Unresolved external 'TransparentBlt' referenced from C:\MY PROJECTS\BUILDER\2D GAME (ON GODLIKE'S FRAMEWORK)\UNIT1.OBJ Does anyone knows what I do wrong because I've tried to use this function and throught Visual C++ 6 and a got the same error.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
Hi!
A linker error appears if something went wrong with
the linkage to libraries.
I think the function TransparentBlt is in some *.lib
you explicitely need to specify in the options of your compiler/linker.

Share this post


Link to post
Share on other sites
That pragma is for MSVC and probably won't work with BCB. Make sure your linker is set up to link to msimg32.lib (which is what the pragma instructs msvc to do).

Also, consider not using TransparentBlt. It's buggy on older Windows versions (98, ME) in that it doesn't give correct results and leaks memory. You could probably roll your own just as well.

Share this post


Link to post
Share on other sites
Basically the thing I want to do is to draw bitmaps with transparent parts into the screen using the Win32 API only. Until now I was drawing with the help of a masked bitmap using StretchBlt. Can I use something else?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this