以下几点:
1. 在pro文件中添加以下几句:
INCLUDEPATH += E:/uncompleted/MDI #lib和dll的路径
LIBS += E:/uncompleted/MDI/gpufbp_for_short_scan.dll #dll
2. 包含库的头文件。
3. dll的制作:
#ifdef _EXPORTS #define _API extern "C" __declspec(dllexport) #else #define _API extern "C" __declspec(dllimport) #endif
两个extern "C" 都不能缺少。是否多字节编译目前看来并无影响。
Then, enjoy!