|
Application->ProcessMessages();
// Get the point in the center of button 1
TPoint Pt;
Pt.x=0;
Pt.y=0;
mouse_event(MOUSEEVENTF_ABSOLUTE | MOUSEEVENTF_MOVE, Pt.x, Pt.y, 0, 0);
// Simulate the left mouse button down
mouse_event(MOUSEEVENTF_ABSOLUTE | MOUSEEVENTF_LEFTDOWN, Pt.x, Pt.y, 0, 0);
// Simulate the left mouse button up
mouse_event(MOUSEEVENTF_ABSOLUTE | MOUSEEVENTF_LEFTUP, Pt.x, Pt.y, 0, 0);
이 소스가 대략 실행하면 영상인식에 따라 마우스가 그에 따른 위치를 따라가는 기능인데요...
그니까 대략 영상인식을 하여 오른쪽으로 가면 앞으로 이동하기 이벤트를 주고
왼쪽으로 가면 뒤로가기 이벤트를 주고싶습니다...
여기에다가 뭘 넣어야 할지 알려주세요...
|