import { pointFrom } from "./point"; import type { GlobalPoint, Line, LocalPoint } from "./types"; /** * Create a line from two points. * * @param points The two points lying on the line * @returns The line on which the points lie */ export function line
(a: P, b: P): Line
{ return [a, b] as Line
;
}
/**
* Determines the intersection point (unless the lines are parallel) of two
* lines
*
* @param a
* @param b
* @returns
*/
export function linesIntersectAt