Newer
Older
#pragma once
#ifndef _FTL_RGBD_STEREOVIDEO_HPP_
#define _FTL_RGBD_STEREOVIDEO_HPP_
class LocalSource;
class Calibrate;
class Disparity;
/**
* RGBD source from either a stereo video file with left + right images, or
* direct from two camera devices. A variety of algorithms are included for
* calculating disparity, before converting to depth. Calibration of the images
* is also performed.
*/
class StereoVideoSource : public detail::Source {
explicit StereoVideoSource(ftl::rgbd::Source*);
StereoVideoSource(ftl::rgbd::Source*, const std::string &);
bool capture(int64_t ts);
bool retrieve();
Camera parameters(ftl::codecs::Channel chan);
//const cv::Mat &getRight() const { return right_; }
LocalSource *lsrc_;
Calibrate *calib_;
Disparity *disp_;
#ifdef HAVE_OPTFLOW
// see comments in https://gitlab.utu.fi/nicolas.pope/ftl/issues/155
cv::Ptr<cv::cuda::NvidiaOpticalFlow_1_0> nvof_;
cv::cuda::GpuMat optflow_;
#endif