bitwise_not(src, src); // matrices used Mat dst; // image after preprocessing //frame=src; cvtColor(src, dst, CV_BGR2GRAY); GaussianBlur(dst, dst, Size(7, 7), 5, 3, BORDER_CONSTANT); // tiny bit of smoothing is always a good idea threshold(dst, dst,0, 255, CV_THRESH_BINARY | THRESH_OTSU);
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)