cv::Mat(const IplImage* img, bool copyData=false) doest work correclty if copyData=true (Bug #555)


Added by Benoit R over 14 years ago. Updated over 14 years ago.


Status:Done Start date:
Priority:Blocker Due date:
Assignee:- % Done:

0%

Category:core
Target version:-
Affected version: Operating System:
Difficulty: HW Platform:
Pull request:

Description

Calling to cv::Mat mat(iplimg,true) create a corrupted matrix (rows=0, cols=0, ...)

If we have an pointer on iplImage

IplImage* iplim=cvCreateImage(cvSize(100,100),IPL_DEPTH_8U,1);
cv::Mat mat = cv::Mat(iplim,true);
cv::imshow("Mat",mat);//error: (-206) Unrecognized or unsupported array type in function cvGetMat

When the following works correctly

IplImage* iplim=cvCreateImage(cvSize(100,100),IPL_DEPTH_8U,1);
cv::Mat tmp = cv::Mat(iplim,false);
cv::Mat mat = tmp.clone();
cv::imshow("Mat",mat);


Associated revisions

Revision dcf7a694
Added by Andrey Kamaev about 12 years ago

Merge pull request #555 from bitwangyaoyao:2.4_fixFft

History

Updated by Vadim Pisarevsky over 14 years ago

the problem is fixed in the trunk

  • Status changed from Open to Done
  • (deleted custom field) set to fixed

Also available in: Atom PDF