1 | initial version |
there is a minimum size that can be detected with Cascades (the size of the train window) , you can look it up, it's in the 1st lines of the resp. xml file.
so if your images are too small, it won't find the eyes or mouth. try to resize the image:
cv::resize(img, img, Size(), 2,2); // keep same aspect ratio
also, a minSize of Size(80,80)
will prevent any detection, if your image is 90x100.
please again, don't blindly copy/paste code, but read the documentation, and try to understand it.
2 | No.2 Revision |
there is a minimum size that can be detected with Cascades (the size of the train window) , you can look it up, it's in the 1st lines of the resp. xml file.
so if your images are too small, it won't find the eyes or mouth. try to resize the image:
cv::resize(img, img, Size(), 2,2); // keep same aspect ratio
also, a minSize of Size(80,80)
will prevent any eye detection, if your image is 90x100.
please again, don't blindly copy/paste code, but read the documentation, and try to understand it.