1 | initial version |
you MUST check the result of EACH AND EVERY imread()
call.
Mat currImage_= imread(filename);
if (currImage_.empty()) // ;(
2 | No.2 Revision |
you MUST check the result of EACH AND EVERY imread()
call.
Mat currImage_= imread(filename);
if (currImage_.empty()) // ;(
(it obviously failed in your case, copyTo()
dos not throw anything (baa!), and you end up with n exception in reshape()
, a few lines down of the original problem.)
3 | No.3 Revision |
you MUST check the result of EACH AND EVERY imread()
call.
Mat currImage_= imread(filename);
if (currImage_.empty()) // ;(
(it obviously failed in your case, copyTo()
dos does not throw anything (baa!), and you end up with n an exception in reshape()
, a few lines down of the original problem.)