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

◆ setup()

void setup ( )

Definition at line 98 of file Downscale.h.

98 {
99 Serial.begin(115200);
100 auto screenmap = xyMap.toScreenMap();
101 screenmap.setDiameter(.2);
102 FastLED.addLeds<NEOPIXEL, 2>(leds, xyMap.getTotal())
103 .setScreenMap(screenmap);
104 auto screenmap2 = xyMap_Dst.toScreenMap();
105 screenmap.setDiameter(.5);
106 screenmap2.addOffsetY(-HEIGHT / 2);
107 FastLED.addLeds<NEOPIXEL, 3>(leds_downscaled, xyMap_Dst.getTotal())
108 .setScreenMap(screenmap2);
110 // Initialize wave simulation. Please don't use static constructors, keep it
111 // in setup().
112 trigger.click();
114}
CRGB leds[NUM_LEDS]
Definition Apa102.ino:11
#define HEIGHT
Definition Blur2d.ino:10
FL_DISABLE_WARNING_PUSH FL_DISABLE_WARNING_GLOBAL_CONSTRUCTORS CFastLED FastLED
Global LED strip management instance.
Definition FastLED.cpp:62
LED controller for WS2812 LEDs with GRB color order.
Definition FastLED.h:155
UIButton trigger("Trigger")
WaveEffect wave_fx
Definition Downscale.h:50
void setupUiCallbacks()
Definition Downscale.h:80
XYMap xyMap_Dst(WIDTH/2, HEIGHT/2, false)
CRGB leds_downscaled[NUM_LEDS/4]
Definition Downscale.h:40
WaveEffect NewWaveSimulation2D(const XYMap xymap)
Definition wave.cpp:42
XYMap xyMap
Definition gfx.cpp:8

References FastLED, HEIGHT, leds, leds_downscaled, NewWaveSimulation2D(), setupUiCallbacks(), trigger(), wave_fx, xyMap, and xyMap_Dst().

+ Here is the call graph for this function: