You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

23 lines
1.0 KiB
C++

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

// detect.h - 检测模式(check):对一次采集的点集做通道/货物截面分析
#ifndef DETECT_H
#define DETECT_H
#include <string>
#include <vector>
#include "common.h"
// 对一次采集的点集做截面检测:
// 1) 保存原始点云 lidar_data.pcd
// 2) Y轴偏移(SHIFT_Y_POSITIVE)后保存 lidar_data_shifted.pcd
// 3) 起点(Z开头Z_Range_MM区间)与终点(结束前Z_Range_MM区间)两个 X-Z 截面
// → 保存切片PCD + 二值图JPG + 合并对比图 lidar_slice_combined.jpg
// 4) 写 log.txt(Log_Flag 开启时)
// points 会被复制处理(内部可能做 Y 偏移),不修改调用方数据。
// out_dir:已创建或待创建的任务输出目录(如 data/20260902/143000_task1)。
// result:可选,回传各截面白色占比/Y统计(供 TCP 返回)。
void detect_analyze_slices(const std::vector<CountPoint>& points,
const std::string& out_dir,
DetectResult* result = nullptr);
#endif // DETECT_H