无法解析的外部符号 __imp__SetCursorPos
1>mouseController.obj : error LNK2019: 无法解析的外部符号 __imp__mouse_event@20,该符号在函数 _wmain 中被引用
1>mouseController.obj : error LNK2019: 无法解析的外部符号 __imp__SetCursorPos@8,该符号在函数 _wmain 中被引用
1>mouseController.obj : error LNK2019: 无法解析的外部符号 __imp__GetCursorPos@4,该符号在函数 _wmain 中被引用
#include "stdafx.h"#include "CVObject.h"#include <Windows.h>#include <iostream>using namespace std;//get sign of number#define SIGN(n) (n==0?(n<0?-1:0):1)int _tmain(int argc, _TCHAR* argv[]){ int cameraIndex=0; if (argc==2){ cameraIndex=argv[1][0]-'0'; } ............if (lastGesture.type==FIST&&g.type==PALM){ mouse_event(MOUSEEVENTF_LEFTUP,0,0,0,0); cout<<"mouse left button up"<<endl; }else if (lastGesture.type==PALM&&g.type==FIST){ mouse_event(MOUSEEVENTF_LEFTDOWN,0,0,0,0); cout<<"mouse left button down"<<endl;............ if(!SetCursorPos(ptDst.x,ptDst.y)){ cout<<"failed to set position of cursor"<<endl; break; }............