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

◆ setupUiCallbacks()

void setupUiCallbacks ( )

Definition at line 80 of file Downscale.h.

80 {
81 speed.onChanged([](UISlider& slider) {
82 time_warp.setSpeed(slider.value());
83 });
84 maxAnimation.onChanged(
85 [](UISlider& slider) {
86 shapeProgress.set_max_clamp(slider.value());
87 });
88
89 trigger.onClicked([]() {
90 // shapeProgress.trigger(millis());
91 FASTLED_WARN("Trigger pressed");
92 });
93 useWaveFx.onChanged([](fl::UICheckbox &checkbox) {
94 if (checkbox.value()) {
95 FASTLED_WARN("WaveFX enabled");
96 } else {
97 FASTLED_WARN("WaveFX disabled");
98 }
99 });
100}
uint16_t speed
Definition Noise.ino:63
bool value() const
Definition ui.h:239
UIButton trigger("Trigger")
UISlider maxAnimation("Max Animation", 1.0f, 5.0f, 20.0f, 1.f)
TimeWarp time_warp
Definition Downscale.h:54
TimeClampedTransition shapeProgress(TIME_ANIMATION)
UICheckbox useWaveFx("Use WaveFX", true)
UISlider slider("Speed", 0.18f, 0.0f, 1.0f)
#define FASTLED_WARN
Definition warn.h:7

References FASTLED_WARN, maxAnimation(), shapeProgress(), slider(), speed, time_warp, trigger(), useWaveFx(), and fl::UICheckbox::value().

Referenced by setup().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: