Apex › Storage & databases

Poisson-disk sampling — evenly-spaced randomness

Scatter points that look random but never clump: every pair at least r apart, yet the area stays evenly covered. This "blue noise" is what rendering, stippling, and procedural scattering want — uniform random points bunch up and leave holes, causing splotchy shadows and grainy antialiasing. Bridson's algorithm builds it in O(n) by firing candidate darts into the ring between r and 2r around active points, with an O(1) grid spacing-check. Flip blue vs white noise and watch the min distance.

More in Storage & databases