# include
# include
# include
# include
using namespace std;
Using the namespace CV;
Int main ()
{
CascadeClassifier cascada;
Cascada. Load (" haarcascade_frontalface_alt2. XML ");
//VideoCapture cap (0);
Vector
Mat img, myface, img_gray;
Img=imread (" 1. JPG ");
CvtColor (img, img_gray COLOR_BGR2GRAY);
Cascada. DetectMultiScale (img_gray, faces, 1.1, 4, CV_HAAR_DO_ROUGH_SEARCH, Size (30, 30), the Size (500, 500));
Printf (" the number of detected face: % d \ n ", faces. The size ());
Imshow (" img ", faces);
waitKey(0);
}
CodePudding user response:
What's wrong, you have to say it outCodePudding user response:
The