I know it is not officially supported yet, but I would like to read images in a directory numbered as 1.png, 2.png ... 137.png using VideoCapture
.
While browsing the source code I saw CvCapture_Images
class which can read images one by one using a printf
like pattern. I can't seem to make it work. I have tried:
VideoCapture cap("c:/fullpath/1.png");
and
VideoCapture cap("c:/fullpath/%d.png");
Neither of them worked, the first one was able to read only 1.png but not the rest of the images. Latter one was not able to open the capture at all.
How can I make VideoCapture work to read images named nicely?