summaryrefslogtreecommitdiffhomepage
path: root/tracker-trackhat
diff options
context:
space:
mode:
Diffstat (limited to 'tracker-trackhat')
-rw-r--r--tracker-trackhat/frame.cpp3
-rw-r--r--tracker-trackhat/trackhat.hpp2
2 files changed, 3 insertions, 2 deletions
diff --git a/tracker-trackhat/frame.cpp b/tracker-trackhat/frame.cpp
index d8fae002..0e97ed0e 100644
--- a/tracker-trackhat/frame.cpp
+++ b/tracker-trackhat/frame.cpp
@@ -114,9 +114,10 @@ void trackhat_frame::init_points(const trackHat_ExtendedPoints_t& points_, doubl
if (pt.m_area >= min_size && pt.m_area <= max_size)
p.ok = true;
+ constexpr f c = (f)2941/trackhat_camera::sensor_size;
p.brightness = pt.m_averageBrightness;
- p.area = pt.m_area;
+ p.area = pt.m_area * c;
p.W = std::max(1, pt.m_boundryRigth - pt.m_boundryLeft);
p.H = std::max(1, pt.m_boundryDown - pt.m_boundryUp);
p.x = trackhat_camera::sensor_size-1-pt.m_coordinateX;
diff --git a/tracker-trackhat/trackhat.hpp b/tracker-trackhat/trackhat.hpp
index 1494d994..04da69cb 100644
--- a/tracker-trackhat/trackhat.hpp
+++ b/tracker-trackhat/trackhat.hpp
@@ -155,7 +155,7 @@ struct trackhat_camera final : pt_camera
f deadzone_amount() const override { return 10; }
- static constexpr int sensor_size = 4095;
+ static constexpr int sensor_size = 4096;
static constexpr int sensor_fov = 52;
static constexpr int point_count = TRACK_HAT_NUMBER_OF_POINTS;
static constexpr bool debug_mode = true;