OpenCv assertion failed
问题 I am working on application for finding face in 2D image and later inside same image I want to find mouth, but I have some problem right now. This is my code so far: for (int i = 0; i < faces.size(); i++) { Point pt1(faces[i].x, faces[i].y); Point pt2((faces[i].x + faces[i].height), (faces[i].y + faces[i].width)); rectangle(frame, pt1, pt2, Scalar(255,0 , 0), 2, 8, 0); //I WANT ROI(FOR MOUTH DETECTION) TO BE ONLY HALF OF THE RECTANGLE WITH FACE Rect mouthROI; mouthROI.x = (faces[i].x);