Quad
Quadrilateral represented as a flat tuple of vertices. Vertices order is fixed: · left-top → right-top → left-bottom → right-bottom
Invariants: · x1 <= x2 (top edge goes left → right) · x3 <= x4 (bottom edge goes left → right) · y1 <= y3 (left edge goes top → bottom) · y2 <= y4 (right edge goes top → bottom)
Type
Object
Properties
| Name | Type | Description |
|---|---|---|
| 0 | pt | x1 (left top) |
| 1 | pt | y1 (left top) |
| 2 | pt | x2 (right top) |
| 3 | pt | y2 (right top) |
| 4 | pt | x3 (left bottom) |
| 5 | pt | y3 (left bottom) |
| 6 | pt | x4 (right bottom) |
| 7 | pt | y4 (right bottom) |