FastLED 3.9.15
Loading...
Searching...
No Matches

◆ drawGradient()

void fl::XYPath::drawGradient ( const Gradient & gradient,
float from,
float to,
Leds * leds,
int steps = -1 )

Definition at line 268 of file xypath.cpp.

269 {
270 XYRasterU8Sparse &raster = tls_raster.access();
271 raster.clear();
272 steps = steps > 0 ? steps : calculateSteps(from, to);
273 rasterize(from, to, steps, raster);
274 raster.drawGradient(gradient, leds->xymap(), leds->rgb());
275}
CRGB leds[NUM_LEDS]
Definition Apa102.ino:11
XYRaster raster(WIDTH, HEIGHT)
int calculateSteps(float from, float to)
Definition xypath.cpp:277
void rasterize(float from, float to, int steps, XYRasterU8Sparse &raster, AlphaFunction *optional_alpha_gen=nullptr)
Definition xypath.cpp:48
ThreadLocal< XYRasterU8Sparse > tls_raster
Definition xypath.cpp:19

References calculateSteps(), leds, raster, and rasterize().

+ Here is the call graph for this function: