MCPcopy Create free account
hub / github.com/fogleman/primitive / Rasterize

Method Rasterize

primitive/rectangle.go:71–78  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

69}
70
71func (r *Rectangle) Rasterize() []Scanline {
72 x1, y1, x2, y2 := r.bounds()
73 lines := r.Worker.Lines[:0]
74 for y := y1; y <= y2; y++ {
75 lines = append(lines, Scanline{y, x1, x2, 0xffff})
76 }
77 return lines
78}
79
80type RotatedRectangle struct {
81 Worker *Worker

Callers

nothing calls this directly

Calls 1

boundsMethod · 0.95

Tested by

no test coverage detected