Mercurial Hosting > traffic-intelligence
diff include/InputVideoFileModule.h @ 400:7ef1071e3cc3
clean up of input classes for list of images and video files
author | Nicolas Saunier <nicolas.saunier@polymtl.ca> |
---|---|
date | Mon, 29 Jul 2013 18:06:55 -0400 |
parents | c389fae9689a |
children | b829ebdc18e6 |
line wrap: on
line diff
--- a/include/InputVideoFileModule.h Mon Jul 29 17:12:45 2013 -0400 +++ b/include/InputVideoFileModule.h Mon Jul 29 18:06:55 2013 -0400 @@ -1,37 +1,32 @@ -#ifndef INPUT_VIDEO_FILE_MODULE_H -#define INPUT_VIDEO_FILE_MODULE_H - -#include "InputFrameProviderIface.h" -#include <string> -#include "opencv2/core/core.hpp" -#include "opencv2/highgui/highgui.hpp" - -class InputVideoFileModule : public InputFrameProviderIface -{ -public: - InputVideoFileModule(const std::string& videoPath); - ~InputVideoFileModule(); - - - bool isOpen() const { return mInit;} - const cv::Size& getSize() const { return mSize;} - - - - - - bool getNextFrame(cv::Mat&); - - unsigned int getNbFrames(){ return mNumberOfFrame;} - - - - -private: - cv::Size mSize; - cv::VideoCapture mVideoCapture; - bool mInit; - int mNumberOfFrame; -}; - -#endif \ No newline at end of file +#ifndef INPUT_VIDEO_FILE_MODULE_H +#define INPUT_VIDEO_FILE_MODULE_H + +#include "InputFrameProviderIface.h" +#include <string> +#include "opencv2/core/core.hpp" +#include "opencv2/highgui/highgui.hpp" + +class InputVideoFileModule : public InputFrameProviderIface +{ +public: + InputVideoFileModule(const std::string& videoPath); + ~InputVideoFileModule(); + + bool getNextFrame(cv::Mat&); + + unsigned int getNbFrames(){ return mNumberOfFrame;} + + bool isOpen() const { return mInit;} + + void setFrameNumber(const int& frameNumber); + + const cv::Size& getSize() const { return mSize;} + +private: + cv::Size mSize; + cv::VideoCapture mVideoCapture; + bool mInit; + int mNumberOfFrame; +}; + +#endif