怎么解决 c++ 没有与参数列表匹配的 重载函数

1 IntelliSense: 没有与参数列表匹配的 重载函数 "cv::CascadeClassifier::detectMultiScale" 实例
参数类型为: (IplImage *, std::vector<cv::Rect, std::allocator<cv::Rect>>, double, int, int, cv::Size, cv::Size)
对象类型是: cv::CascadeClassifier d:\my\ivLaneDepartureWanringSystem\ivLaneDepartureWanringSystem\ivLaneDepartureWanringSystem.cpp 474

就是你给openCV的CascadeClassifier类的detectMultiScale函数传递的参数不对啊。

//比如有如下三个重载函数
bool isGood(int i);
bool isGood(int i,std::vector<int>& v);
bool isGood(int i,std::string& s);
//但是你调用了
int i=1,j=2;
bool ok=isGood(i,j);    //这里就会说“没有与参数列表匹配的重载函数”
//因为三个重载函数没有接受两个整数的
//你给的参数列表没法和其中的某个匹配

温馨提示:答案为网友推荐,仅供参考