comparison c/InputVideoFileModule.cpp @ 401:b829ebdc18e6

simplified input of directories of video frames (simply use the video filename parameter to point at the directory)
author Nicolas Saunier <nicolas.saunier@polymtl.ca>
date Mon, 29 Jul 2013 18:58:05 -0400
parents 7ef1071e3cc3
children 3c271a46b4d4
comparison
equal deleted inserted replaced
400:7ef1071e3cc3 401:b829ebdc18e6
12 } 12 }
13 13
14 InputVideoFileModule::~InputVideoFileModule(void) { } 14 InputVideoFileModule::~InputVideoFileModule(void) { }
15 15
16 16
17 void InputVideoFileModule::setFrameNumber(const int& frameNumber) { 17 void InputVideoFileModule::setFrameNumber(const unsigned int& frameNumber) {
18 mVideoCapture.set(CV_CAP_PROP_POS_FRAMES, frameNumber); 18 mVideoCapture.set(CV_CAP_PROP_POS_FRAMES, frameNumber);
19 } 19 }
20 20
21 bool InputVideoFileModule::getNextFrame(cv::Mat& outputPicture) 21 bool InputVideoFileModule::getNextFrame(cv::Mat& outputPicture)
22 { 22 {
23 bool success = false; 23 bool success = false;
24 if(mInit) 24 if(mInit)
25 { 25 {
26 mVideoCapture >> outputPicture; 26 mVideoCapture >> outputPicture;
27 success = !outputPicture.empty(); 27 success = !outputPicture.empty();
28 } 28 }
29 return success; 29 return success;
30 } 30 }
31 31