kopia lustrzana https://github.com/Aircoookie/WLED
Correction for "Percent with speed" (#642)
The speed slider defines the "size" of pixels that will be added or substracted each refresh. If this size is bigger than the last value and you quickly move the intensity slider to zero, then the effect shows 100% all the time until it will be changed.pull/660/head
rodzic
ac927d188b
commit
e4d5551f16
|
@ -3027,7 +3027,7 @@ uint16_t WS2812FX::mode_percent(void) {
|
|||
SEGENV.step += size;
|
||||
if (SEGENV.step > active_leds) SEGENV.step = active_leds;
|
||||
} else if (active_leds < SEGENV.step) {
|
||||
SEGENV.step -= size;
|
||||
if (SEGENV.step > size) SEGENV.step -= size; else SEGENV.step = 0;
|
||||
if (SEGENV.step < active_leds) SEGENV.step = active_leds;
|
||||
}
|
||||
|
||||
|
|
Ładowanie…
Reference in New Issue