Commit Graph

3326 Commits

Author SHA1 Message Date
Frank
adb3a12129 small speedup: IRAM_ATTR_YN colorBalanceFromKelvin 2023-07-28 21:04:59 +02:00
Christian Schwinne
f966b17f5a Remove obsolete Visual Studio files 2023-07-28 21:00:24 +02:00
Titanium177
8b25e78a7c Edited Metadata for effect 5 & 8 to be availible on just 1 Pixel (PWM) (#3275) 2023-07-28 20:53:40 +02:00
Frank
d899192794 2D Drift: minor optimization
moving "t/20" out of the main loop gives some speedup.
2023-07-28 20:46:39 +02:00
Frank
9b7f690708 Minor correction (slider names)
"Time delay" is actually "speed" - bigger values make the effect run faster.
2023-07-28 20:46:39 +02:00
Frank
553ac7bd82 remove some over-optimizations (FASTPATH) 2023-07-28 20:37:37 +02:00
Frank
2393e86f11 build ++
increment build number
2023-07-28 10:41:34 +02:00
Frank
27d4128e2c lossless getPixelColor() where needed
after upstream PR https://github.com/Aircoookie/WLED/pull/3091, getPixelColor() does not restore brightness any more.

So all effects that rely on previous colors now need the LEDs buffer: getPixelColor, blenPixelColor, fade_out, blur, fadeToBlackBy

This change is an intermediate solution until upstream PR https://github.com/Aircoookie/WLED/pull/3280 is stable enough for merging.
2023-07-27 16:24:42 +02:00
Will Tatam
9d218299c4 Fix palette preview of Audio Responsive Ramp 2023-07-27 13:04:52 +01:00
Frank
39db568ca9 increase STACK_BUF_SIZE after PR#59
* increase buffer by 64 bytes (sting added in AR usermod)
* better diag message when buffer is full
* change "Arduino  max stack" to debug message
2023-07-27 12:45:14 +02:00
Frank
d23ca8beaf PSRAM: slightly reduce static JSON buffer size 2023-07-26 21:59:49 +02:00
Frank
03de8ac0ad ripple effects: bugfix for 1D
ripple effects were showing random crashes in 1D mode.
Root cause: negative and out-of-range index passed to getPixelColor(i, col).
2023-07-26 13:03:58 +02:00
Frank
90c4868c28 npm run build
yo-man
2023-07-26 12:47:01 +02:00
Frank
aff0e59ff0 cleanup and clarifications 2023-07-26 12:42:00 +02:00
Frank
e64aff28e7 (experimental) compiler optimization for speed instead of size
only for [env:esp32_4MB_S] and [env:esp32_16MB_V4_S]
2023-07-21 22:46:20 +02:00
Frank
4984c578cc minor speedups
* added IRAM_ATTR_YN to some frequently used color functions
* small optimization for fade_out: pixel already has "target color"
2023-07-21 15:59:32 +02:00
Frank
7a38f319dc npm run build
... needed to add correct version info into the the UI files.
2023-07-15 21:41:02 +02:00
Ewoud
54b321fb75 Release 0.14.0-b25.29 2023-07-15 14:14:09 +02:00
Frank
ead76be9a3 Update index.js
Small update for upcoming release
2023-07-15 13:19:08 +02:00
Frank
5f55f91ff0 debug message cleanup
changed some non-critical USER_PRINT debug messages into DEBUG_PRINT
2023-07-14 16:17:42 +02:00
Frank
423d3720b2 post-merge
* disabled FASTPATH breaking changes in normal builds
* _S builds for esp32 stay fully FASTPATH enabled
* full movie quote
* npm run build
2023-07-13 21:44:12 +02:00
Frank
9243b90345 max is faster than MAX 2023-07-13 21:14:43 +02:00
Frank
99def6458f live view: more updates in non-fastpath builds 2023-07-13 21:11:33 +02:00
Frank
9a3a97eff1 pre-merge
cleanup:
- version increase
- clean up debug messages
- minor fixes in platformio.ini
- fix compilation with -D WLED_DISABLE_2D

helping the compiler to optimize:
- a few more __attribute__((pure))
- fx.cpp marked a few local functions as "static"
2023-07-13 19:58:48 +02:00
Frank
3295579e05 jsonToPixels robustness
avoid string overflow when constructing filename
2023-07-13 18:36:11 +02:00
Frank
0fb5edc4a2 robustness improvements from upstream
(from upstream alt-buffer branch)
* prevent drawing into inactive segments
* robustness improvements for transitions
2023-07-13 18:34:46 +02:00
Frank
c22c92e3af preview at full brightness
* reverts global brightness in preview
* can NOT revert brightness reductions from auto brightness limiter.
2023-07-10 18:29:16 +02:00
Frank
9ed5dc7c02 npm run build 2023-07-08 23:12:55 +02:00
Frank
9a832ed4ab build number upgrade 2023-07-08 23:11:02 +02:00
Frank
c64f74a611 fix for random crashes on changing presets (UI)
Segments are created/deleted on-the-fly; it seems that "local leds" buffers did not follow properly.
* revise segment copy/move constructors
* de-optimize use of local leds (as they need to be re-allocated when segment size changes)
* minor stability improvements
2023-07-08 22:40:43 +02:00
Frank
a45306b141 blur speedup
it seems that SEGMENT.blur() is the main bottleneck for many 2D effects.

This change optimizes performance of the function:
* avoid to re-write unchanged pixels
* early exit when blur_amount == 0 (=nothing to do)
* use _fast_ types where possible

I've seen up to 20% speedup with this change.
2023-07-08 20:06:52 +02:00
Frank
a2e2eada1b npm run build 2023-07-08 20:01:40 +02:00
Frank
5fe12eef5a Merge branch 'mdev' into audio_fastpath 2023-07-08 19:23:36 +02:00
Frank
72b79608bf 2DPlasmaball - optimize out float 2023-07-08 19:13:20 +02:00
Frank
2562f308ca fix power calculation for NeoPixelBusLg
power estimation results from estimateCurrentAndLimitBri() were too low (example: estimated 1.3Amp, measured 1.6Amp). This change corrects the power calculation. Due to the changed behavior of getPixelColor, powerSum must be used as-is, not scaled down again by brightness.
2023-07-08 19:13:20 +02:00
Frank
601499b69b XY: minor bugfix
properly handle width=0 OR height=0
2023-07-06 10:02:01 +02:00
Frank
7e34781212 ABL optimization
this optimization avoids to apply brightness two times .

NeoPixelBusLg has already applied global brightness at sPC. Due to internal working of the Lg bus, its sufficient to only post-apply scaling, and set the new (scaled) brightness for the next frame.
2023-07-03 19:41:51 +02:00
Frank
a71be02b89 de-optimization
first version still cased some flickering.
This de-optimization makes LEDs more stable.
2023-07-03 19:41:51 +02:00
Frank
358f37b7ca optimization for ABL hotfix
* adding an optional parameter to setBrightness(). ApplyPostAdjustments() will only be called if `immediate=true`. Only ABL will use immediate=true, to ensure electrical safety of equipment.

This allows some optimizations of performance, as ApplyPostAdjustments() is time consuming.

* busses.setBrightness(bri) --> applied to all future pixels (fast, lossless)
* busses.setBrightness(bri, true) --> applied directly to all previously set pixels (slower, lossy)
2023-07-03 19:41:50 +02:00
Frank
29644ccf79 ABL optimization
this optimization avoids to apply brightness two times .

NeoPixelBusLg has already applied global brightness at sPC. Due to internal working of the Lg bus, its sufficient to only post-apply scaling, and set the new (scaled) brightness for the next frame.
2023-07-03 19:26:02 +02:00
Frank
ecf331792b de-optimization
first version still cased some flickering.
This de-optimization makes LEDs more stable.
2023-07-03 19:26:02 +02:00
Frank
a84c361fab build number ++ 2023-07-01 20:35:25 +02:00
Frank
3cc1d30090 optimization for ABL hotfix
* adding an optional parameter to setBrightness(). ApplyPostAdjustments() will only be called if `immediate=true`. Only ABL will use immediate=true, to ensure electrical safety of equipment.

This allows some optimizations of performance, as ApplyPostAdjustments() is time consuming.

* busses.setBrightness(bri) --> applied to all future pixels (fast, lossless)
* busses.setBrightness(bri, true) --> applied directly to all previously set pixels (slower, lossy)
2023-07-01 20:23:39 +02:00
Will Tatam
a0b913db27 Disable Animartrix by default 2023-06-29 12:17:55 +01:00
Ewoud
d53de3d82b Fix for GFX to stay in view (part 1) 2023-06-27 15:42:33 +02:00
Blaz Kristan
1c53f14bd5 Temporary bugfix for #3264 2023-06-25 17:21:49 +02:00
Blaz Kristan
2afad2cd66 Temporary bugfix for #3264 2023-06-25 17:06:54 +02:00
Frank
582b96f846 robustness improvements
* handling of stop = 0 when calculating sizes (avoid unsigned underflow)
* make sure groupLength() is never zero (to avoid div/0)
* gapmaps: check for "(gapSize > 0)" added.

not sure if all the checks are 100% needed, but they will improve robustness in corner cases.
2023-06-21 13:30:40 +02:00
Frank
310daa61a8 improve segment code robustness
* Avoid uint16 underflow in width() and height(): stop > start is possible, and means "inactive segment".

* use size_t for ledsrgbSize, _dataLen and _usedSegmentData -  uint16_t could overflow in some situations.

* try to catch attempts to allocate zero bytes (inactive segment => size 0)
2023-06-21 01:43:26 +02:00
Frank
708cd8e73d free udp receive buffers before parsePacket
robustness improvement - parsepacket() will fail if the udp handler still has an active receive buffer.
2023-06-21 00:29:16 +02:00