Convert UnWarpContour to use a vector<Vector2f>
This makes it so we don't risk multiple points being rounded to the same
pixel. It does the float conversion slightly earlier in the process.
Change-Id: Ic6288854ebddc17e020e839c1d2e5cc22394522a
diff --git a/y2019/vision/target_sender.cc b/y2019/vision/target_sender.cc
index f322aeb..80a47e0 100644
--- a/y2019/vision/target_sender.cc
+++ b/y2019/vision/target_sender.cc
@@ -312,8 +312,10 @@
for (const RangeImage &blob : imgs) {
// Convert blobs to contours in the corrected space.
ContourNode* contour = finder_.GetContour(blob);
- finder_.UnWarpContour(contour);
- std::vector<Segment<2>> polygon = finder_.FillPolygon(contour, verbose);
+ const ::std::vector<::Eigen::Vector2f> unwarped_contour =
+ finder_.UnWarpContour(contour);
+ ::std::vector<Segment<2>> polygon =
+ finder_.FillPolygon(unwarped_contour, verbose);
if (!polygon.empty()) {
raw_polys.push_back(polygon);
}