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

◆ geti16Previous()

int16_t fl::WaveSimulation2D_Real::geti16Previous ( size_t x,
size_t y ) const

Definition at line 199 of file wave_simulation_real.cpp.

199 {
200 if (x >= width || y >= height) {
201 FASTLED_WARN("Out of range: " << x << ", " << y);
202 return 0;
203 }
204 const int16_t *prev = (whichGrid == 0 ? grid2.data() : grid1.data());
205 return prev[(y + 1) * stride + (x + 1)];
206}
uint32_t x[NUM_LAYERS]
Definition Fire2023.ino:82
uint32_t y[NUM_LAYERS]
Definition Fire2023.ino:83
fl::vector< int16_t, fl::allocator_psram< int16_t > > grid2
fl::vector< int16_t, fl::allocator_psram< int16_t > > grid1
#define FASTLED_WARN
Definition warn.h:7

References FASTLED_WARN, grid1, grid2, height, stride, whichGrid, width, x, and y.