getting error using canny edge detector
I do not know why I get error in this line:
Canny( dst_Gaussian, dst_Gaussian, 100, 100*3, 3 );
everything seems correct but I get "Unhandled exception.." error.
This is what I am trying to do:
cv::Mat dis = Mat(width, height, CV_32FC1, dises);
cv::Mat dst_Gaussian(width, height, CV_32FC1);
Mat dst_Canny;
dst_Gaussian= dis.clone();
dst_Canny.create( dis.size(), dis.type() );
//
blur( dis, dis, Size(3,3));
GaussianBlur( dis, dst_Gaussian, Size( 3, 3 ), 2, 2);
imshow("Gaus",dst_Gaussian);
//findContours(dst, contours, hierarchy, int mode, int method, Point offset=Point());
Canny( dst_Gaussian, dst_Gaussian, 100, 100*3, 3 );
dst_Canny = Scalar::all(0);
dis.copyTo( dst_Canny, dst_Gaussian);
imshow("canny", dst_Canny);
"dises is a pointer."
Thanks in advance