Compare commits

..

1 Commits

Author SHA1 Message Date
Matt M
099a4eb58c Backport maven changes 2024-08-02 08:18:23 -07:00
4 changed files with 3 additions and 7 deletions

View File

@@ -102,7 +102,7 @@ const downloadCalibBoard = () => {
const yPos = chessboardStartY + squareY * squareSizeIn.value;
// Only draw the odd squares to create the chessboard pattern
if (squareY % 2 != squareX % 2) {
if ((xPos + yPos + 0.25) % 2 === 0) {
doc.rect(xPos, yPos, squareSizeIn.value, squareSizeIn.value, "F");
}
}

View File

@@ -395,7 +395,6 @@ public class USBCameraSource extends VisionSource {
// Sort by resolution
var sortedList =
videoModesList.stream()
.distinct() // remove redundant video mode entries
.sorted(((a, b) -> (b.width + b.height) - (a.width + a.height)))
.collect(Collectors.toList());
Collections.reverse(sortedList);

View File

@@ -408,8 +408,8 @@ public class PhotonPoseEstimator {
return Optional.empty();
}
if (estimatedPose.isPresent()) {
lastPose = estimatedPose.get().estimatedPose;
if (estimatedPose.isEmpty()) {
lastPose = null;
}
return estimatedPose;

View File

@@ -186,9 +186,6 @@ std::optional<EstimatedRobotPose> PhotonPoseEstimator::Update(
ret = std::nullopt;
}
if (ret) {
lastPose = ret.value().estimatedPose;
}
return ret;
}