Cover.line.push: def of gralha-coverage@0.1.0.1 Import: import gralha-coverage@0.1.0.1/cover.bend as Cover Lines 189-195 of gralha-coverage@0.1.0.1/cover.bend: https://jend.leeeet.dev/read.txt?path=gralha-coverage@0.1.0.1/cover.bend&start_line=189&end_line=195 import Base import gralha-text-scan@0.1.0.1/scan.bend as U # One pass over the lines: shift by the mask's origin, split at the grid's # left and right edges and clamp the pieces to it, counting them. Pieces # left of 0 or right of w become vertical lines on that edge, which keeps # the winding of every cell inside intact. def line.push(+ax: F32, +ay: F32, +bx: F32, +by: F32, +w: F32, st: List<&2, CovLine> & U32) -> List<&2, CovLine> & U32: (acc, n) = st (Con{CovLine{U.clamp(ax, 0.0, w), ay, U.clamp(bx, 0.0, w), by}, acc}, (n + 1 : U32)) Uses (8): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=F32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Pair https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Sigma https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.add https://jend.leeeet.dev/definition.txt?path=gralha-coverage@0.1.0.1/cover.bend&name=CovLine https://jend.leeeet.dev/definition.txt?path=gralha-text-scan@0.1.0.1/scan.bend&name=clamp