COMPARAISON_PRECISION
COMPARAISON_PRECISION
Precision of size comparison
Represents a polygon (geometric form)
$_points : array<mixed,\Tazorax\MathUtils\TwoD\Point2d>
addPoint(\Tazorax\MathUtils\TwoD\Point2d $point) : \Tazorax\MathUtils\TwoD\Polygon
Add point
\Tazorax\MathUtils\TwoD\Point2d | $point |
getPoint(integer $index) : \Tazorax\MathUtils\TwoD\Point2d
Get point at index
integer | $index |
setPoint(integer $index, \Tazorax\MathUtils\TwoD\Point2d $point) : \Tazorax\MathUtils\TwoD\Polygon
Add or set a point for the given index
integer | $index | |
\Tazorax\MathUtils\TwoD\Point2d | $point |
translate(\Tazorax\MathUtils\TwoD\Vector2d $vector) : \Tazorax\MathUtils\TwoD\Polygon
Apply a vector on each point and return a new instance of Polygon
\Tazorax\MathUtils\TwoD\Vector2d | $vector |