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

Function getRelativePosition

source/position.js:39–42  ·  view source on GitHub ↗
(position, corners)

Source from the content-addressed store, hash-verified

37// Corners... of a deeper screen
38// Return: Where the position would be, if it was inside the deeper screen (instead of the higher screen)
39export const getRelativePosition = (position, corners) => {
40 const relativePosition = bilerp(position, corners);
41 return relativePosition;
42};
43
44export const getRelativePositions = (positions, corners) => {
45 const relativePositions = positions.map((position) =>

Callers 1

getRelativePositionsFunction · 0.85

Calls 1

bilerpFunction · 0.90

Tested by

no test coverage detected