18 void push(uint32_t index, uint8_t alpha) {
32 for (
size_t i = 0; i <
mIndices.size(); i++) {
52 const uint32_t width =
waveSim.getWidth();
53 const uint32_t height =
waveSim.getHeight();
54 for (uint32_t
y = 0;
y < height;
y++) {
55 for (uint32_t
x = 0;
x < width;
x++) {
58 batch.push(idx, value8);
XYMap xymap(WIDTH, HEIGHT, SERPENTINE)
WaveSimulation1D waveSim(NUM_LEDS, SuperSample::SUPER_SAMPLE_2X)
fl::GradientInlined Gradient
void mapWaveToLEDs(const XYMap &xymap, WaveSimulation2D &waveSim, CRGB *leds) override
Implements the FastLED namespace macros.
Implements a simple red square effect for 2D LED grids.
static int32_t grad(uint8_t hash, int32_t x)
Representation of an RGB pixel (Red, Green, Blue)
static const size_t kMaxBatchSize
WaveCrgbGradientMap::Gradient * mGradient
BatchDraw(CRGB *leds, WaveCrgbGradientMap::Gradient *grad)
fl::FixedVector< uint32_t, kMaxBatchSize > ArrayIndices
void push(uint32_t index, uint8_t alpha)
fl::FixedVector< uint8_t, kMaxBatchSize > ArrayAlphas