23#include <opencv2/opencv.hpp>
24#include <opencv2/videoio.hpp>
35 "relative to Component path)",
"movie.mpg", ParamCateg);
44 public jevois::Parameter<bufferedvideoreader::filename>
68 std::future<void> itsRunFut;
69 std::atomic<bool> itsRunning;
Simple class to read video frames from a movie file, decode them, and buffer them for smooth playback...
~BufferedVideoReader()
Virtual destructor for safe inheritance.
JEVOIS_DECLARE_PARAMETER(filename, std::string, "Filename of video to read (if not absolute, will be assumed to be " "relative to Component path)", "movie.mpg", ParamCateg)
Parameter.
virtual void postUninit() override
Uninit, wait on our run thread and swallow any exception.
cv::Mat get()
Get the next frame as a BGR cv::Mat, or an empty cv::Mat when the movie is finished.
virtual void postInit() override
Start the thread that loads, decodes and pushes the frames into our buffer.