报错内容:
terminate called after throwing an instance of 'cv::Exception'
what(): OpenCV(4.5.4) ./modules/core/src/array.cpp:2494:
error: (-206:Bad flag (parameter or structure field)) Unrecognized or unsupported array type
in function 'cvGetMat'
已放弃 (核心已转储)
错误的原因是函数’cvGetMat’无法读取array类型,检查imread("*****.jpg")
是否有中文路径,我这里的问题是没有添加头文件#include<iostream>