MCPcopy Create free account
hub / github.com/FastLED/FastLED / setupUiCallbacks

Function setupUiCallbacks

examples/XYPath/complex.h:79–95  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

77fl::TimeClampedTransition shapeProgress(TIME_ANIMATION);
78
79void setupUiCallbacks() {
80 speed.onChanged([](float value) { time_warp.setSpeed(speed.value()); });
81 maxAnimation.onChanged(
82 [](float value) { shapeProgress.set_max_clamp(maxAnimation.value()); });
83
84 trigger.onChanged([]() {
85 // shapeProgress.trigger(millis());
86 FL_WARN("Trigger pressed");
87 });
88 useWaveFx.onChanged([](bool on) {
89 if (on) {
90 FL_WARN("WaveFX enabled");
91 } else {
92 FL_WARN("WaveFX disabled");
93 }
94 });
95}
96
97void setup() {
98 Serial.begin(115200);

Callers 1

setupFunction · 0.70

Calls 4

set_max_clampMethod · 0.80
onChangedMethod · 0.45
setSpeedMethod · 0.45
valueMethod · 0.45

Tested by

no test coverage detected