fill_circles_aa
Mojo function 🡭
fill_circles_aa
fn def fill_circles_aa(mut canvas: Canvas, centers: List[FPoint], radius: Float64, color: Color)Fill many equal-radius anti-aliased disks in one call.
Output is identical to calling fill_circle_aa once per center in
the same order, including where translucent markers overlap: each
band walks the batch in submission order, and bands own disjoint
rows.
A radius past the closed-form limit, a canvas transform that is not a similarity, or too little total work each fall back to per-marker calls.
Args:
- canvas (
Canvas): Canvas to fill into. - centers (
List[FPoint]): Sub-pixel center of each marker, in draw order. - radius (
Float64): Radius shared by every marker, in pixels. - color (
Color): Fill color shared by every marker.
Raises:
fn def fill_circles_aa(mut canvas: Canvas, centers: List[FPoint], radius: Float64, colors: List[Color])fill_circles_aa with a color per marker – a scatter whose points carry a color scale.
Args:
- canvas (
Canvas): Canvas to fill into. - centers (
List[FPoint]): Sub-pixel center of each marker, in draw order. - radius (
Float64): Radius shared by every marker, in pixels. - colors (
List[Color]): One color per center, same length ascenters.
Raises:
Error: If colors is not the same length as centers.