Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Hey! You can simply crop all returned rectangles:

detectMultiscale(frame, faces_in_frame, ...)
cv::Rect _framerect = cv::Rect(0,0,frame.cols,frame.rows); 
for(size_t i = 0; i < faces_in_frame.size(); i++) {
    faces_in_frame[i] = faces_in_frame[i] & _framerect;
}