Taos API Reference
    Preparing search index...

    Function declutter

    • Greedy declutter: in ascending rank order, keep a label if its (padded) box doesn't overlap any already-kept box; otherwise drop it. Returns the kept ids in placement order. O(n²) — fine for the few-hundred candidates a viewport holds after frustum culling; swap for a grid if it ever isn't. Ties on rank break by id for deterministic output.

      Parameters

      Returns number[]