Add extra-long lines for directions on field view
Add long lines coming out of the camera results, turret, and robot on
the field view webpage so that it is easy to see whether it looks like
things are pointing at the target.
Change-Id: I3d025d8cb746ddb86e97e8960e14628bcfbca7e5
Signed-off-by: James Kuszmaul <jabukuszmaul@gmail.com>
diff --git a/y2020/www/field_handler.ts b/y2020/www/field_handler.ts
index 4aaa05f..1a0b56a 100644
--- a/y2020/www/field_handler.ts
+++ b/y2020/www/field_handler.ts
@@ -191,6 +191,8 @@
ctx.beginPath();
ctx.moveTo(0.5, 0.5);
ctx.lineTo(0, 0);
+ ctx.lineTo(100.0, 0);
+ ctx.lineTo(0, 0);
ctx.lineTo(0.5, -0.5);
ctx.stroke();
ctx.beginPath();
@@ -218,13 +220,13 @@
// Draw line in circle to show forwards.
ctx.beginPath();
ctx.moveTo(0, 0);
- ctx.lineTo(turretRadius, 0);
+ ctx.lineTo(1000.0 * turretRadius, 0);
ctx.stroke();
ctx.restore();
}
ctx.beginPath();
ctx.moveTo(0, 0);
- ctx.lineTo(ROBOT_LENGTH / 2, 0);
+ ctx.lineTo(100.0 * ROBOT_LENGTH / 2, 0);
ctx.stroke();
ctx.restore();
}