import type {Point} from "./Point"; import type {Rect} from "./Rect"; /** * The Quadrilateral class represents a quadrilateral shape in 2D space, * which contains an array of four points, representing the vertices of the quadrilateral. * */ export interface Quadrilateral { /** * Vertex coordinates of the quadrilateral. */ points: Point[]; /** * The center point of the quadrilateral. */ centrePoint: Point; /** * The bounding rectangle of the quadrilateral. */ boundingRect: Rect; /** * The area of the quadrilateral calculated with the shoelace formula. */ area: number; }