能把你的bmp二值化处理的C语言程序发给我么 1415725413@qq.com 谢谢

2024-12-05 18:13:10
推荐回答(1个)
回答1:

typedef int (WINAPI ICEPUB_IMGTOSINGLEBMP)(char *strImgFilename,char *strBmpFilename,int thresholdValue);
ICEPUB_IMGTOSINGLEBMP *icePub_imgToSingleBmp = 0;
HINSTANCE hDLLDrv = LoadLibrary("icePubDll.dll");
if(hDLLDrv)
{
icePub_imgToSingleBmp=(ICEPUB_IMGTOSINGLEBMP *)GetProcAddress(hDLLDrv,"icePub_imgToSingleBmp");
}
if(icePub_imgToSingleBmp)
{
icePub_imgToSingleBmp("my24.bmp","single1.bmp",150);
icePub_imgToSingleBmp("my.jpg","single2.bmp",150);
icePub_imgToSingleBmp("my.png","single3.bmp",150);
}

if(hDLLDrv)
FreeLibrary(hDLLDrv);