Undefined reference to alphablend
Yedboy opened this issue · 23 comments
I'm trying to test blur C++ effect but it says "Undefined reference to alphablend"
what to do?
This should be a problem with the compiler
Can you link the msimg32.lib library file?
I linked msimg32.lib. Still the same thing.
Are you include wingdi.h in code?
oh thanks
keeps saying undefined reference to `_imp__AlphaBlend@44'
Are you linked msimg32.lib in code?
try link msimg32.lib in linker options
where to find compiler options
First open your project and click "Tools"Button, and click to "Compiler Options", "Add the following commands when calling the linker" the following input box
I wrote some code:
#include <windows.h>
#include <wingdi.h>
int main() {
AlphaBlend(NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
return 0;
}
linker not say "Undefined reference to alphablend"
Can you try the code?(replace "NULL" to your paramet pls)
It says 5 72 C:\Users\DELL\OneDrive\Escritorio\main.cpp [Error] could not convert '0' from 'int' to 'BLENDFUNCTION' {aka '_BLENDFUNCTION'}
replace "NULL" to your paramet pls.........
I did replace NULL to my paramet
emm
emm
Can you make a video of how to do it so i understand?
I'm a cpp newbie
Do you have test code?
I said make a video ._.
That's right, but I don't have instance code and I don't know much about Windows graphics APIs
I mean the video of how to link it
emm
emm
Does this mean you will produce a video or not?
I don't know.
This is the reason for the Windows API
and
"It says 5 72 C:\Users\DELL\OneDrive\Escritorio\main.cpp [Error] could not convert '0' from 'int' to 'BLENDFUNCTION' {aka '_BLENDFUNCTION'}" This error is because an int value was passed in a parameter of AlphaBlend instead of BLENDFUTURE (without type conversion)