figureone
    Preparing search index...

    Interface OBJ_RectangleCloudShapes

    Options object to generate shapes at random positions within a rectangle.

    • width number — width of rectangle (1)
    • height number — height of rectangle (1)
    • position TypeParsablePoint — center position of rectangle ([0, 0])
    • shape (position: [number, number], size: number) => number[] — By default a square of two triangles is created (six vertices). Use a number to create a regular polygon with number sides. Use a custom function to make a custom shape. The function takes as input the [x, y] position of the point to build the shape around, and size. It outputs an array of interlaced x and y coordinates of triangle vertices - i.e.: [x1, y1, x2, y2, x3, y3, ....]