cv::remap failes on 16bit arrays (Bug #160)


Added by hype blade about 15 years ago. Updated almost 15 years ago.


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

0%

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

Description

Hi there,
i just found out, that the cv::remap() function fails with an assertion when trying to remap a signed short array.

"OpenCV Error: Assertion failed (ifunc != 0) in unknown function, file ..\..\..\src\cv\cvimgwarp.cpp, line 2364"

//Code Example
cv::Mat_<float> mapx(240,320,pmx);
cv::Mat_<float> mapy(240,320,pmy);
cv::Mat_<short> data(240,320,pShortBuffer);
cv::Mat_<short> dataUndist;

cv::remap(data,dataUndist,mapx,mapy,cv::INTER_CUBIC);
// End of code

I did a simple workaround and first converted everything to 32bit float arrays, remapped them and then converted them back to signed short arrays, but maybe this could be better handled internally!?

Regards
Matthias


Associated revisions

Revision 6cd70c83
Added by Andrey Kamaev over 12 years ago

Merge pull request #160 from asmorkalov/android_4_2_manager_fix

Revision dcfbb8db
Added by Andrey Pavlenko almost 11 years ago

Merge pull request #160 from KonstantinMatskevich:ocl_stereobm_experiment

History

Updated by anonymous - almost 15 years ago

fixed in r2865

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

Also available in: Atom PDF