MCPcopy Create free account
hub / github.com/TodePond/ScreenPond / getZeroedCorners

Function getZeroedCorners

source/corners.js:62–67  ·  view source on GitHub ↗
(corners)

Source from the content-addressed store, hash-verified

60};
61
62export const getZeroedCorners = (corners) => {
63 const [a] = corners;
64 const [ax, ay] = a;
65 const zeroedCorners = corners.map(([x, y]) => [x - ax, y - ay]);
66 return zeroedCorners;
67};
68
69export const getCornersPosition = (corners, number = 0) => {
70 const corner = corners[number];

Callers 1

getScaledPositionFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected