voronoid WASM API
    Preparing search index...

    Class Cell2D

    Index

    Properties

    edge_neighbors: Int32Array

    The indices of the neighboring generators for each edge.

    id: number

    The index of the generator corresponding to this cell.

    vertices: Float64Array

    The vertices of the cell as a flat array [x0, y0, x1, y1, ...].

    Methods

    • Returns void

    • Calculates the area of the cell.

      Returns number

    • Calculates the centroid of the cell.

      Returns Float64Array

    • Returns void