FastLED 3.10.10
Loading...
Searching...
No Matches

◆ polyABFillRun()

template<typename PixelT>
void fl::gfx::detail::polyABFillRun ( PixelT * pixels,
int py,
int width,
int x0,
int x1,
const PixelT & color,
fl::u8 br,
bool overwrite )
inline

Fill a run of [x0, x1) pixels of row py with color at alpha br.

The caller guarantees br > 0.

Definition at line 251 of file poly_abuffer.h.

253 {
254 if (x1 <= x0) return;
255 PixelT c = color;
256 if (br < 255u) c.nscale8(br);
257 PixelT* row = pixels + py * width + x0;
258 if (overwrite) {
259 for (int i = 0; i < x1 - x0; ++i) row[i] = c;
260 } else {
261 for (int i = 0; i < x1 - x0; ++i) row[i] += c;
262 }
263}
u8 width
Definition blur.h:186

References fl::FL_NO_EXCEPT, and fl::width.

Referenced by drawPolygonABufferCore().

+ Here is the caller graph for this function: