删除不必要代码。

This commit is contained in:
xinyang
2019-08-04 17:18:32 +08:00
parent 3b4927d275
commit d0ab4342fd
3 changed files with 3 additions and 77 deletions

View File

@@ -84,7 +84,6 @@ public:
double lengthDistanceRatio() const;
double getBoxDistance() const;
BoxOrientation getOrientation() const;
// double
bool operator<(const ArmorBox &box) const;
};
@@ -108,10 +107,6 @@ private:
NORMAL, ANTI_TOP
} AntiTopState;
typedef enum{
INCREASE, DECREASE, NOCHANGE
} BoxRatioChangeType;
systime frame_time; // 当前帧对应时间;
const uint8_t &enemy_color; // 敌方颜色,引用外部变量,自动变化
State state; // 自瞄状态对象实例
@@ -119,7 +114,7 @@ private:
int anti_switch_cnt; // 防止乱切目标计数器
cv::Ptr<cv::Tracker> tracker; // tracker对象实例
Classifier classifier; // CNN分类器对象实例用于数字识别
int contour_area; // 装甲区域亮点个数,用于数字识别未启用时判断是否跟丢(已弃用)
int contour_area; // 装甲区域亮点个数,用于数字识别未启用时判断是否跟丢(已弃用)
int tracking_cnt; // 记录追踪帧数,用于定时退出追踪
Serial &serial; // 串口对象,引用外部变量,用于和能量机关共享同一个变量
const uint8_t &use_classifier; // 标记是否启用CNN分类器引用外部变量自动变化
@@ -135,12 +130,11 @@ private:
bool stateTrackingTarget(cv::Mat &src); // tracking state主函数
bool stateStandBy(); // stand by state主函数已弃用
void antiTop(); // 反小陀螺
BoxRatioChangeType getRatioChangeType(RoundQueue<double, 5> &vec);
void antiTop(); // 反小陀螺
bool sendBoxPosition(uint16_t shoot); // 和主控板通讯
public:
void run(cv::Mat &src); // 自瞄主函数
bool sendBoxPosition(uint16_t shoot); // 和主控板通讯
};
#endif /* _ARMOR_FINDER_H_ */