提交 27a1a2c9 编写于 作者: N nihui

add highgui imshow waitKey stub

上级 9d8814ba
......@@ -53,6 +53,10 @@ CV_EXPORTS_W Mat imdecode(InputArray buf, int flags);
CV_EXPORTS_W bool imencode(const String& ext, InputArray img, CV_OUT std::vector<uchar>& buf, const std::vector<int>& params = std::vector<int>());
CV_EXPORTS_W void imshow(const String& winname, InputArray mat);
CV_EXPORTS_W int waitKey(int delay = 0);
} // namespace cv
#endif // OPENCV_HIGHGUI_HPP
......@@ -418,4 +418,17 @@ bool imencode(const String& ext, InputArray _img, std::vector<uchar>& buf, const
return success;
}
void imshow(const String& winname, InputArray mat)
{
fprintf(stderr, "imshow save image to %s.png", winname.c_str());
imwrite(winname + ".png", mat);
}
int waitKey(int delay)
{
(void)delay;
fprintf(stderr, "waitKey stub");
return -1;
}
} // namespace cv
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册