1 | initial version |
oh, that's a fun one ;)
the culprit is bg.getBackgroundImage(back);
i tested this with 2.4.2, there we end up in an empty method in the BackgroundSubtractor
base class. (in 2.4.9 it throws a not impl exception)
so your "back" Mat is left untouched, still empty, and imshow does not like it. (complains of an empty image, that's your exception)
BackgroundSubtractorMOG2 can do that. (that's the good news)
the background image has to get expensively reconstructed from a Model, that's not a simple member access