def visibility
import bend-visgraph@2.0.0.0/parallel.bend as Parallelimport Base
import bend-visgraph@2.0.0.0/visgraph.bend as VG
158# VG.build on every thread: the stack runs on blocks, then the sweeps on
159# chunks of equal work.
160def visibility(+g: VG.Visibility, +dir: VG.Direction, +k: VG.Weight, +lo: F32, +hi: F32, ys: Array<F32>, xs: VG.Xs, +n: U32) -> VG.Edges:
161 match xs:
162 case VG.Index{}:
163 built(True{}, g, dir, k, lo, hi, ys, VG.no_xs(), n)
164 case VG.At{a}:
165 built(False{}, g, dir, k, lo, hi, ys, a, n)