--- a/subprojects/shotwell-facedetect/facedetect-opencv.cpp.ORIG 2019-03-27 19:58:01.000000000 +0100 +++ b/subprojects/shotwell-facedetect/facedetect-opencv.cpp 2019-12-09 14:20:48.125205029 +0100 @@ -1,6 +1,8 @@ #include "shotwell-facedetect.hpp" #include +#include + #define OPENFACE_RECOG_TORCH_NET "openface.nn4.small2.v1.t7" #define RESNET_DETECT_CAFFE_NET "res10_300x300_ssd_iter_140000_fp16.caffemodel" @@ -41,7 +43,7 @@ cv::resize(gray, smallImg, smallImgSize, 0, 0, cv::INTER_LINEAR); cv::equalizeHist(smallImg, smallImg); - cascade.detectMultiScale(smallImg, faces, 1.1, 2, CV_HAAR_SCALE_IMAGE, cv::Size(30, 30)); + cascade.detectMultiScale(smallImg, faces, 1.1, 2, cv::CASCADE_SCALE_IMAGE, cv::Size(30, 30)); } else { #ifdef HAS_OPENCV_DNN // DNN based face detection @@ -159,7 +161,7 @@ std::vector faceToVec(cv::String inputName) { std::vector ret; - cv::Mat img = imread(inputName, 1); + cv::Mat img = cv::imread(inputName, 1); if (img.empty()) { std::cout << "error;Could not load the file to process. Filename: \"" << inputName << "\"" << std::endl; ret.assign(128, 0);