I’m trying to use an external .dll for a camera in my c++ project. I use Visual Studio 2010. I have 3 files: The uEye.h file in /include of my project folder, which I included under Properties…C/C++…additional_include_directories and via #include "include/uEye.h".
Then the uEye_api_64.lib in the /lib folder of my project. I added the path under Properties…Linker…General…Additional_Library_Directories and added uEye_api_64.lib under Properties…Linker…Input…Additional_Dependencies.
And finally the uEye_api_64.dll, which I put to the .cpp files in my project folder. Now I’m trying to use the functions provided by the DLL, for Example is_ExitCamera(), but upon building I get the Linker Error
LNK2019: unresolved external symbol __imp__is_ExitCamera referenced in function …
I have searched numerous forum posts but can’t find out what I did wrong.
Source code:
#include "stdafx.h"
#include "include/uEye.h"
#include "MeasurementAgents_CameraAbstraction.h"
#include <iostream>
UINT nDeviceID = 1;
HIDS hCAM = 0;
JNIEXPORT jboolean JNICALL Java_MeasurementAgents_CameraAbstraction_CamDisconnect
(JNIEnv *, jclass){
int nRet = is_ExitCamera(hCAM);
if(nRet==IS_SUCCESS){
return true;
}else{
std::cout << nRet;
return false;
}
}