OpenCV imwrite 2.2 causes exception with message “OpenCV Error: Unspecified error (could not find a writer for the specified extension)” on Windows 7

前端 未结 3 2034
灰色年华
灰色年华 2021-01-02 06:25

I\'m porting an OpenCV 2.2 app from Unix (that works) onto Windows 7 64-bit and I receive the following exception when cv::imwrite is called

\"OpenCV Error: Unspecif

3条回答
  •  [愿得一人]
    2021-01-02 06:38

    Try

    cvSaveImage("test.jpg", &(IplImage(image)));
    

    instead of

    imwrite("test.jpg", image);
    

    This is a known bug in the version you are using.

提交回复
热议问题