static L pixelSetBoundsByColumn(PixelSet set) { final Rect rect = pixelSetBounds(set); L l = repFunc(func -> IntRange { IntRange(rect.y+rect.h, rect.y) }, rect.w); for (Pixel p : set) { IntRange r = l.get(p.x-rect.x); int y = p.y-rect.y; r.start = min(y, r.start); r.end = max(y+1, r.end); } ret l; }