|
|
@ -36,6 +36,8 @@ int minx,miny,maxx,maxy,lenx,leny; |
|
|
|
|
|
|
|
|
|
|
|
int channel; |
|
|
|
int channel; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void mouseHandler(int, int, int, int, void*); |
|
|
|
|
|
|
|
|
|
|
|
void mouseHandler(int event, int x, int y, int, void*) |
|
|
|
void mouseHandler(int event, int x, int y, int, void*) |
|
|
|
{ |
|
|
|
{ |
|
|
|
|
|
|
|
|
|
|
@ -123,6 +125,13 @@ void mouseHandler(int event, int x, int y, int, void*) |
|
|
|
|
|
|
|
|
|
|
|
int main(int argc, char **argv) |
|
|
|
int main(int argc, char **argv) |
|
|
|
{ |
|
|
|
{ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(argc != 2) |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
cout << "usage: " << argv[0] << " <input_image>" << endl; |
|
|
|
|
|
|
|
exit(1); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
Mat src = imread(argv[1]); |
|
|
|
Mat src = imread(argv[1]); |
|
|
|
|
|
|
|
|
|
|
|
minx = INT_MAX; miny = INT_MAX; maxx = INT_MIN; maxy = INT_MIN; |
|
|
|
minx = INT_MAX; miny = INT_MAX; maxx = INT_MIN; maxy = INT_MIN; |
|
|
|