NodeLayers
fun NodeLayers(nodes: List<Node>, myNodeNum: Int?, showPrecisionCircles: Boolean, onNodeClick: (Int) -> Unit, onClusterZoom: (Position, Double) -> Unit, onClusterMembers: (List<ClusterMember>) -> Unit, visibleBounds: BoundingBox? = null, zoom: Int = 0)(source)
The mesh node layers: ground-truth precision circles underneath, then clusters, then individual node chips.
Clustering is MapLibre's own — point_count is computed inside the source — which is why the OSMdroid clustering code has no counterpart here.
Parameters
onClusterZoom
invoked with the cluster centre and the zoom that breaks it apart; the caller owns the camera. MapLibre reports a sentinel when a cluster cannot compute an expansion zoom, so the caller must clamp against the current zoom rather than trusting the value.
visibleBounds
what the camera can see, padded. Chips are only drawn for nodes inside it — see NodeChipLayer.