#ifndef _CAPTURE_H__ #define _CAPTURE_H__ #include #include #include #include class capture { public: int index; int port; int width; int height; int fps; bool status = false; bool flip = false; char zmq_bind_addr[40] = "tcp://*:"; std::thread *thread_capture; std::thread *thread_request; 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, bool flip = false); void start(void); void get(void); void req(void); bool is_open(void); }; #endif