initial commit
This commit is contained in:
31
capture.h
Normal file
31
capture.h
Normal file
@@ -0,0 +1,31 @@
|
||||
#ifndef _CAPTURE_H__
|
||||
#define _CAPTURE_H__
|
||||
|
||||
#include <thread>
|
||||
#include <iostream>
|
||||
#include <opencv2/highgui.hpp>
|
||||
#include <zmq.hpp>
|
||||
|
||||
class capture
|
||||
{
|
||||
public:
|
||||
int index;
|
||||
int port;
|
||||
int width;
|
||||
int height;
|
||||
int fps;
|
||||
bool status = false;
|
||||
char zmq_bind_addr[40] = "tcp://*:";
|
||||
std::thread *thread;
|
||||
cv::VideoCapture *cap;
|
||||
cv::Mat frame;
|
||||
zmq::context_t *context;
|
||||
zmq::socket_t *socket;
|
||||
|
||||
capture(int camera_index, int zmq_port, int width_set = 320, int height_set = 240, int fps_set = 20);
|
||||
void start(void);
|
||||
void run(void);
|
||||
bool is_open(void);
|
||||
};
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user