cv::Mat img = cv::imread("../赤月/lena.jpg");
if(img.empty()) std::cout<<"empty image"<<std::endl;
Or
QString const image_name = "../赤月/lena.jpg";
cv::Mat img = cv::imread(image_name_.toAscii().constData());
if(img.empty()) std::cout<<"empty image"<<std::endl;
The api of imread accept std::string, what if I need unicode support?
See Question&Answers more detail:os