From 3475b17ce9f48ccacc561cfd915bcebb4612e5aa Mon Sep 17 00:00:00 2001 From: Gold87 <91761103+Gold872@users.noreply.github.com> Date: Fri, 24 Jan 2025 10:39:17 -0500 Subject: [PATCH] Fix vision messages --- vision.proto | 25 +++++++++++++++++-------- 1 file changed, 17 insertions(+), 8 deletions(-) diff --git a/vision.proto b/vision.proto index d114494..1776159 100644 --- a/vision.proto +++ b/vision.proto @@ -4,6 +4,7 @@ syntax = "proto3"; import "geometry.proto"; import "video.proto"; +import "version.proto"; enum DetectedObjectType { DETECTION_TYPE_UNDEFINED = 0; @@ -13,25 +14,33 @@ enum DetectedObjectType { } message PnpResult { - Pose3d pose = 1; - double error = 2; + Pose3d cameraToTarget = 1; + double reprojectionError = 2; } message DetectedObject { // What was detected DetectedObjectType objectType = 1; int32 arucoTagId = 2; - CameraName camera = 3; // Where it was detected float xPosition = 4; // -1 to +1 (left to right) float relativeSize = 5; // 0 to 1 (percent of frame) - // Experimental: Use pinhole model to find the object's position - float yaw = 6; - float pitch = 7; + int32 centerX = 6; + int32 centerY = 7; + + // Experimental: Use pinhole camera model to find the object's position + float yaw = 8; + float pitch = 9; // Experimental: Use PnP to determine the 3D pose - PnpResult bestPnpResult = 8; - PnpResult alternatePnpResult = 9; + PnpResult bestPnpResult = 10; + PnpResult alternatePnpResult = 11; +} + +message VisionResult { + Version version = 1; + CameraName name = 2; + repeated DetectedObject objects = 3; }