chore: cleanup debug

This commit is contained in:
psmyrdek 2025-03-15 12:51:15 +01:00
parent 56e044fcc9
commit 8fb1e1c504

View file

@ -1308,22 +1308,6 @@ const updateBoundPoint = (
pointDistanceSq(g, adjacentPoint) - pointDistanceSq(h, adjacentPoint), pointDistanceSq(g, adjacentPoint) - pointDistanceSq(h, adjacentPoint),
); );
// debugClear();
// debugDrawPoint(intersections[0], { color: "red", permanent: true });
// debugDrawLine(
// lineSegment<GlobalPoint>(
// adjacentPoint,
// pointFromVector(
// vectorScale(
// vectorNormalize(vectorFromPoint(focusPointAbsolute, adjacentPoint)),
// interceptorLength,
// ),
// adjacentPoint,
// ),
// ),
// { permanent: true, color: "green" },
// );
if (intersections.length > 1) { if (intersections.length > 1) {
// The adjacent point is outside the shape (+ gap) // The adjacent point is outside the shape (+ gap)
newEdgePoint = intersections[0]; newEdgePoint = intersections[0];
@ -1745,21 +1729,6 @@ const determineFocusDistance = (
) )
.sort((g, h) => Math.abs(g) - Math.abs(h)); .sort((g, h) => Math.abs(g) - Math.abs(h));
// debugClear();
// [
// lineSegmentIntersectionPoints(rotatedInterceptor, interceptees[0]),
// lineSegmentIntersectionPoints(rotatedInterceptor, interceptees[1]),
// ]
// .filter((p): p is GlobalPoint => p !== null)
// .forEach((p) => debugDrawPoint(p, { color: "black", permanent: true }));
// debugDrawPoint(determineFocusPoint(element, ordered[0] ?? 0, rotatedA), {
// color: "red",
// permanent: true,
// });
// debugDrawLine(rotatedInterceptor, { color: "green", permanent: true });
// debugDrawLine(interceptees[0], { color: "red", permanent: true });
// debugDrawLine(interceptees[1], { color: "red", permanent: true });
const signedDistanceRatio = ordered[0] ?? 0; const signedDistanceRatio = ordered[0] ?? 0;
return signedDistanceRatio; return signedDistanceRatio;