SEMS-data-collection/include/visible_light_camera.h

28 lines
664 B
C
Raw Permalink Normal View History

2024-09-11 17:14:49 +08:00
#ifndef _VISIBLE_LIGHT_CAMERA_H
#define _VISIBLE_LIGHT_CAMERA_H
#include <fstream>
#include <vector>
#include "SI_sensor.h"
#include "SI_errors.h"
#include <opencv2\core\core.hpp>
#include <opencv2\highgui\highgui.hpp>
#include <opencv2\imgproc\imgproc.hpp>
class VisibleLightCamera
{
public:
VisibleLightCamera();
~VisibleLightCamera();
int init(int video_capture_index);
int read(void);
void close(void);
void save(std::ofstream &h_visible_light_file, std::ofstream &h_header_file);
cv::Mat image_frame;
private:
int video_capture_index;
cv::VideoCapture *video_capture;
std::vector<unsigned char> image_buff;
};
#endif