Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int n=4;
- int TOTAL_POINTS=n;
- Point pt;
- vector<Point> capturePoint = vector<Point>();
- void CallBackFunc(int event, int x, int y, int flags, void* param)
- {
- //Mat& image= *(Mat*) param;
- if (event == CV_EVENT_LBUTTONDOWN){
- pt.x = x;
- pt.y = y;
- cout << "Point" << TOTAL_POINTS + 1 - n << "(" << x << "," << y << ")" << endl;
- capturePoint.push_back(pt);
- n--;
- //circle(mouseDetector::workingMat,pt,2,Scalar(0,0,255), 5);
- if(n==0){
- cvDestroyAllWindows();
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement