2019赛季RM中部分区赛,自瞄和能量机关,完整稳定版。

This commit is contained in:
xinyang
2019-05-31 19:29:22 +08:00
parent 76bc5988c0
commit c0c12b24f0
28 changed files with 816 additions and 728 deletions

View File

@@ -25,6 +25,7 @@ struct mcu_data{
extern mcu_data mcuData;
void uartReceive(Serial *pSerial);
void initVideoWriter(cv::VideoWriter& video, const std::string &armor_filename_prefix);
void initVideoWriter(cv::VideoWriter& video, const std::string &filename_prefix);
void lastVideo(std::string &video_name, const std::string &filename_prefix);
#endif /* _ADDITIONS_H_ */

View File

@@ -138,9 +138,9 @@
#include <sys/time.h>
#define CNT_TIME(tag, codes, ...) do{ \
static timeval ts, te; \
gettimeofday(&ts); \
gettimeofday(&ts, NULL); \
codes; \
gettimeofday(&te); \
gettimeofday(&te, NULL); \
LOGM(tag": %.1lfms", (te.tv_sec-ts.tv_sec)*1000.0+(te.tv_usec-ts.tv_usec)/1000.0); \
}while (0)
#endif

View File

@@ -1,16 +0,0 @@
//
// Created by xinyang on 19-4-7.
//
#ifndef _ADDITIONS_H_
#define _ADDITIONS_H_
#include <serial/serial.h>
#include <opencv2/core.hpp>
#include <thread>
void save_video_file(cv::Mat &src);
void save_labelled_image(cv::Mat &src, cv::Rect2d box);
#endif /* _ADDITIONS_H_ */