rm_vision/tasks/omniperception/detection.hpp
2025-12-15 02:33:20 +08:00

33 lines
781 B
C++

#ifndef OMNIPERCEPTION__DETECTION_HPP
#define OMNIPERCEPTION__DETECTION_HPP
#include <chrono>
#include <list>
#include "tasks/auto_aim/armor.hpp"
namespace omniperception
{
//一个识别结果可能包含多个armor,需要排序和过滤。armors, timestamp, delta_yaw, delta_pitch
struct DetectionResult
{
std::list<auto_aim::Armor> armors;
std::chrono::steady_clock::time_point timestamp;
double delta_yaw; //rad
double delta_pitch; //rad
// Assignment operator
DetectionResult & operator=(const DetectionResult & other)
{
if (this != &other) {
armors = other.armors;
timestamp = other.timestamp;
delta_yaw = other.delta_yaw;
delta_pitch = other.delta_pitch;
}
return *this;
}
};
} // namespace omniperception
#endif