imread error - OpenCV-2.4.7rc1 VS2012 Pro(32-bit) Windows7(64-bit) (Bug #3417)


Added by Orkun KASAPOGLU over 11 years ago. Updated about 11 years ago.


Status:Cancelled Start date:2013-12-03
Priority:Normal Due date:
Assignee:Orkun KASAPOGLU % Done:

0%

Category:highgui-images
Target version:2.4.8
Affected version:2.4.7 (latest release) Operating System:Windows
Difficulty: HW Platform:x64
Pull request:

Description

I've builded opencv-2.4.7 with vs2012-x86 and I used opencv-2.4.5 for more than a year. Now I've changed my computer and needed to install opencv but when I want to use imread it returns null Mat element therefore I've tried with C interface (cvLoadImage) and there is no problem. These are cods:

@#include "opencv2\core\core.hpp"
#include "opencv2\highgui\highgui.hpp"
#include "opencv2\imgproc\imgproc.hpp"

using namespace cv;

int main() {
IplImage *x1;
x1 = cvLoadImage("xxx.png", 1);
Mat x1Mat(x1);
Mat Im1 = imread("masaustu.jpeg", CV_LOAD_IMAGE_COLOR);
namedWindow("deneme", CV_WINDOW_AUTOSIZE);
cvShowImage("deneme", x1);
waitKey(30);
imshow("deneme", Im1);
waitKey(30);
cvtColor(Im1, Im1, CV_BGR2GRAY);
namedWindow("deneme_gri", CV_WINDOW_AUTOSIZE);
imshow("deneme_gri", Im1);
}@

How can I fix this problem?


Opencv_imread1.jpg (355 kB) Orkun KASAPOGLU, 2013-12-03 10:27 am

Opencv_imread2.jpg (205.2 kB) Orkun KASAPOGLU, 2013-12-03 10:27 am


Associated revisions

Revision 2d867319
Added by Maksim Shabunin over 10 years ago

Merge pull request #3417 from ilya-lavrenov:dox_warn

History

Updated by Daniil Osokin over 11 years ago

Do you have "masaustu.jpeg" into proper folder? If so, attach both images to reproduce this behaviour.

  • Assignee set to Orkun KASAPOGLU
  • Target version set to 2.4.8

Updated by Orkun KASAPOGLU over 11 years ago

Daniil Osokin wrote:

Do you have "masaustu.jpeg" into proper folder? If so, attach both images to reproduce this behaviour.

Yes, "masaüstü.jpeg" in proper folder and I installed yesterday opencv-2.4.7(vs2012), opencv-master(vs2010) and opencv-2.4.5(vs2010). imread just worked fine with 2.4.5 version of opencv. I'm going to install whole versions of 2.4.5 between 2.4.7 to find which will work fine on vs.

Updated by Orkun KASAPOGLU over 11 years ago

And something caught my attention which is about configure and generate opencv with qt on cmake. I've got building of qt-everywhere-opensource-src-4.8.5. When I tick up WITH_QT on cmake then configure the oCV to build, it want to 6 library paths but they are qt-5 libraries these are Qt5Concurrent, Qt5Core, Qt5Gui,Qt5Test, Qt5OpenGL, Qt5Widgets. I have got just QtCore, QtGui, QtTest and QtOpenGL libraries but cmake does not accept (4 of them) their ways. That can be reason for this because imread is a highgui element and while configuring opencv-2.4.5 with cmake it did not want these library DIRs. Are opencv-2.4.7 and above versions not compatible below versions of qt5?

Updated by Orkun KASAPOGLU over 11 years ago

I deleted all versions of opencv on my computer and rebuild opencv-master with vs2010 it has builded and imread is working well now and I can using builded libraries with vs2012 without any problem for now. But I've uninstalled qt creator and deleted opensource version of qt and build qt opensource again but did not install qt creater (I'll install it later). Opencv is work properly now.

Updated by Daniil Osokin about 11 years ago

So, should we close this ticket, or?

Updated by Nikita Manovich about 11 years ago

Hi,

I have closed the issue. It seems that OpenCV works properly in the case. Feel free to reopen the bug if it is necessary.

  • Status changed from New to Cancelled

Also available in: Atom PDF