randpolygon
Returns the random coordinates of a point (or several points) inside a polygon, or on its perimeter.
randpolygon(
points,
[outline=true],
[count=1]
) -> LIST [x,y]
Returns the random coordinates of a point (or several points) inside a polygon, or on its perimeter.
Syntaxe
var pt = randpolygon(points=[x0,y0, x1,y1, x2,y2...], outline=true);
Arguments
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
points | yes | - | List for polygon'coords [x0,y0, x1,y1, x2,y2...] 3 points minimum | |
outline | - | true | true=perimeter, false=inside | |
count | - | 1 | number of points to return |