Commit Graph

625 Commits

Author SHA1 Message Date
Damian Schneider
6b70c6ae91 Remove FRAMETIME return value from all FX (#5314)
* remove "return FRAMETIME" from all FX, fix timing for some FX

- all FX now render every frame, no more "speed up" during transitions

* fix missing return by adding FS_FALLBACK_STATIC macro

* add FX_FALLBACK_STATIC also to user_fx

* remove obsolete seg.next_time
2026-02-09 07:57:49 +01:00
Damian Schneider
e95450b318 replace cos8 with cos8_t correcting an oversight 2026-01-03 15:45:44 +01:00
Damian Schneider
dd3edf1a3c improved 2D collisions, fixed duplicate line in fireworks 1D, remove additional dimming if gamma is active
Adding symmetrical but random pushing leads to better stacking, also pushing more if large particles are too close helps to separate them better. Pushing them every frame also helps.
Pushing only particle1 as it was tends to lead to more collapsing and some random movement within a pile. There was also a bug which applied way to much velocity unnecessarily.
2025-12-16 20:25:24 +01:00
BobLoeffler68
bb6114e8aa PacMan effect (#4891)
* PacMan effect added
2025-12-14 12:36:51 +01:00
Damian Schneider
9094b3130d Display gaps in peek, fix segment overflow bug (#5105)
- display gaps in peek 
- fix segment overflow bug when loading preset with larger bounds than current setup
2025-12-14 10:26:38 +01:00
Damian Schneider
19bc3c513a lots of tweaks, updated 1D rendering and collisions
- bugfix in mass based 2D collisions
- added improved and faster large size rendering to 1D system
- added per-particle size rendering to 1D system
- improved and simplified collision handling in 1D system
- removed local blurring functions in PS as they are not needed anymore for particle rendering
- adapted FX to work with the new rendering
- fixed outdated AR handling in PS FX
- fixed infinite loop if not enough memory
- updated PS Hourglass drop interval to simpler math: speed / 10 = time in seconds and improved particle handling
- reduced speed in PS Pinball to fix collision slip-through
- PS Box now auto-adjusts number of particles based on matrix size and particle size
- added safety check to 2D particle rendering to not crash if something goes wrong with out-of bounds particle rendering
- improved binning for particle collisions: dont use binning for small number of particles (faster)
- Some code cleanup
2025-12-13 19:05:21 +01:00
Damian Schneider
6f6ac066c9 replaced blur-rendering with ellipse rendering
- better size control as size is now exactly mappable to pixels so it can be matched exactly to the collision distance
- no more gaps due to collision distance mismatch
- much faster: saw up to 30% improvement in FPS
- also adjusted some of the FX to make better use of the new rendering
2025-12-06 14:27:15 +01:00
Damian Schneider
6b607fb545 refined PS replacement ifdefs (#5103)
* refined PS replacement ifdefs

* bugfixes, added glitter and sparkle as they a lightweight (1k of flash)
2025-11-26 22:25:10 +01:00
Damian Schneider
fca921ee82 Adding "Complete" mode to Dissolve FX: always fades completely (#5016)
This allows for much slower speed setting to not turn into "twinkle" effect
2025-11-26 22:22:13 +01:00
Damian Schneider
1e081a7f0d PS 1D Firwork bugfixes and improvements 2025-11-23 19:15:17 +01:00
Damian Schneider
8348089b50 speed improvements to Aurora FX (#4926)
* improvements to Aurora FX

- converted to integer math, increasing speed on all ESPs, also shrinks code size
- caching values to avoid repeated calculations
- CRGBW instead or CRGB, adds white channel support when not using palette
- fix for new brightness/gamma handling

* overflow & unsigned fix
2025-11-16 21:20:14 +01:00
Frank
6581dd6ff9 add blur option 2025-11-09 17:33:04 +01:00
Will Tatam
1fff61b726 Merge pull request #4995 from Brandon502/GoLRework
Game of Life Rework
2025-10-21 20:43:28 +01:00
Benjam Welker
ca5debef32 Fix blank area issue with Twinkle (#5005)
* Fix blank area issue with Twinkle
2025-10-17 07:31:00 +02:00
Brandon502
cc0230f83f Game of Life Optimizations
Adjust mutation logic. Use 1D get/set. Reduce code size.
2025-10-14 22:58:22 -04:00
Brandon502
65b91762fd Game of Life Rework
RAM and speed optimizations. Better repeat detection. Mutation toggle. Blur option added.
2025-10-08 22:48:53 -04:00
Damian Schneider
359d46c3e1 Bugfix for gif playback and segment destruction, bugfix in copy FX
- if a segment is destroyed or turned inactive, disable the gif player: only one gif player instance can run at a time, if a inactive or destroyed segment uses it, the effect is broken for other segments.
- copy FX ironically copied the source segment on each call, should use reference not a copy!
2025-10-02 20:06:01 +02:00
Damian Schneider
2b73a349dd Bugfix for FX: Tri Fade
Bugfix for FX: Tri Fade
2025-09-28 19:52:20 +02:00
Damian Schneider
daa833f33d Adding Shimmer FX (#4923)
Sends a shimmer across the strip at defined (or random) intervals
Optional brightness modulators: sine or perlin noise
Can be used as an overlay to other effects.
2025-09-24 20:49:40 +02:00
Damian Schneider
4b1b0fe045 Adding center bin selection to 2D GEQ (#4764)
* adding center bin selection to 2D GEQ: this makes it possible to use subsets of the GEQ on distributed strips

setting custom3 to 0 gives the "old" behaviour, this is the default. existing presets will have the custom3 slider at the center, changing presets that do not use the full width so this is a breaking change for those but I assume theser are rare.
2025-09-22 20:01:54 +02:00
Benjam Welker
762d4433d8 Add reverse checkmark for Twinklecat (#4728)
reverse slowly fades in random lights, and then instantly turns them off.
2025-09-20 10:58:37 +02:00
Damian Schneider
75f6de9dc2 bugfix in Colortwinkles
thx @blazoncek
2025-09-09 07:31:19 +02:00
Blaž Kristan
649d43b581 Bugfix for FX: Tri Fade
- incorrectly calculated counter and progress
2025-09-08 11:37:43 +02:00
Damian Schneider
385504e6db fix ancient UI bug that hides the speed slider in percent FX 2025-09-05 19:53:15 +02:00
Damian Schneider
d5d7fde30f use video scaling instead of NPB luminance & new ABL (#4798)
* updated color scaling to preserve hue at low brightness resulting in much better colors
* replace NPBlg with NPB, moved brightness scaling to bus manager
* improved gamma table calculation: fixed mismatch in inverting gamma table calculation: inversion should now be as good as it gets
* code cleanup, fixed gamma being applied in unnecessary places

Improvements to ABL handling:
- removed strip level handling, ist now all done on bus level
- limiter now respects pixel mapping
- proper handling of white channel
- improved current estimation
- current is now always correctly reported to UI
- minimal FPS impact if the ABL is not limiting but slighly higher impact for global ABL limit due to double-scaling

- moved brightness scaling to BusDigital
- created new header file colors.h to be able to access color functions in bus-manager.
- updated colo_fade() with better video scaling to preserve hue's at low brightness
- added IRAM_ATTR to color_fade (negligible speed impact when compared to inline and benefits other functions)
- added IRAM_ATTR to color_blend as it is used a lot throughout the code, did not test speed impact but adding it to color_fade made it almost on-par with an inlined function

Additional changes:
- fixes for properly handling `scaledBri()` (by @blazoncek)
- also use bit-shift instead of division in blending for ESP8266
- improvements for faster "softlight" calculation in blending
- changed some variables to uint8_t to maybe let the compiler optimize better, uint8_t can be faster if read, store and set are all done in uint8_t, which is the case in the ones I changed
- various minor code formatting changes
2025-08-29 17:12:10 +02:00
Damian Schneider
ab5b6f9b7d fix change that got lost 2025-07-24 18:30:51 +02:00
Damian Schneider
4fd1b393a8 Bugfix in Aurora FX and fixed compiler warning in PS Impact 2025-07-24 18:27:03 +02:00
Damian Schneider
71301ddc57 using segment buffer instead of local buffer for PS (#4776)
- using segment buffer instead of local buffer to save FX ram
- fix rendering if gamma correction is disabled
- some code cleanup
- Fix for low RAM: reduce number of particles dynamically
- updated add and scale color functions to not use references
- FPS is now more consistent and on average about 15% faster
2025-07-22 22:26:13 +02:00
Damian Schneider
b7bfd6fc67 Copy Segment FX (#4124)
* Added FX to copy a segment in 1D or 2D

- copies the source segment
- brightness of segment is relative to source segment
- optionally shifts the color hue, saturation and brightness
- invert, transpose, mirror work
- if source or targets do not match in size, smallest size is copied
- unused pixels fade to black (allows overlapping segments)
- if invalid source ID is set, segment just fades to black
- added a rgb2hsv conversion function as the fastled variant is inaccurate and buggy
- 1D to 2D and vice versa are supported
2025-07-12 07:40:18 +02:00
Damian Schneider
cc81cc27b0 enhancement & bugfixes in scrolling text (#4742)
* enhancement & bugfixes in scrolling text

- function now evaluates full string: allows custom text plus multiple tokens in any order
- fixed evaluation order to prevent early exit(s)
- fixed day strings (argument must be weekday() )
2025-06-28 09:42:52 +02:00
netmindz
728b1e8ad4 Merge pull request #4723 from DedeHai/Flow_Stripe_FX_fix
Fixed "Flow Stripe" FX and added palette support
2025-06-14 20:20:30 +01:00
Damian Schneider
05f0630b9c add inverse gamma 32 function and fix colors in pride (#4722)
* add inverse gamma 32 function and fix for colors in pride
2025-06-11 08:30:25 +02:00
Damian Schneider
ea231cbea8 Fixed "Flow Stripe" FX and added palette support 2025-06-10 19:29:53 +02:00
Damian Schneider
9805ae59d5 PS Fire: added sparks for better looks (#4714)
also added some smear-blurring if "smooth" (motion blur) is not used
2025-06-08 13:02:44 +02:00
Damian Schneider
a87b562bc2 update to distortionwave FX (#4693)
- fixed "jumpyness" by improving offset calculation resolution
- added palette support
- added two rendering modes for use with palette: one uses hue-mapping, one uses brightness mapping
- added alternate animation mode (from initial source)
- extended scaling: zoom checkmark (depends on matrix size)
2025-06-06 17:05:16 +02:00
Blaž Kristan
23a51e0982 Merge pull request #4658 from wled/layers
Segment layers and better effect transitions (blending)
2025-06-01 12:28:11 +02:00
Damian Schneider
25223c446f fixed bouncing bug (#4694) 2025-05-19 20:48:00 +02:00
Damian Schneider
d9ad4ec743 improved & refactored Android FX (#4522)
- returns FRAMETIME -> no more flickering in transitions and overlay
- no more double-painting of pixels
2025-05-19 19:50:48 +02:00
Damian Schneider
608aff1e17 slight speed improvement, fixed indentation 2025-05-10 09:11:07 +02:00
Damian Schneider
5fe766399b comment 2025-05-09 19:06:38 +02:00
Damian Schneider
891115ecee bugfix 2025-05-09 19:06:06 +02:00
Damian Schneider
0fe722e478 add new effect: PS Galaxy
- parameters tuned to make it look good on most settings
2025-05-09 18:53:16 +02:00
Damian Schneider
d9b086cbe9 Bugfixes in PS, improvements to PS Fireworks 1D (#4673)
- fixed inconsitencies in size rendering
- fixed palette being wrapped in color by position and color by age modes
- Fixed bug in memory layout: for some unknown reason, if flags come before particles, last flag is sometimes overwritten, changing memory laout seems to fix that
- New color modes in PS Fireworks 1D:
 - custom3 slider < 16: lower saturation (check1: single color or multi-color explosions)
 - custom3 slider <= 23: full saturation (check1: single color or multi-color explosions)
 - custom3 slider > 23: color by speed (check 1 has not effect here)
 - custom slider = max: color by age or color by position (depends on check1)
2025-05-01 13:39:23 +02:00
Damian Schneider
f721efca1e fixed wrong gravity setting, added option for no trail (#4665) 2025-04-28 21:12:27 +02:00
Blaž Kristan
ee9ac947a1 Segment layering & effect blending improvements
- Photoshop-style segment/layer blending
- return of strip ABL
- remove global LED buffer in favour of segment-local buffer
- new effect blending modes/transitions
- custom palettes moved out of WS2812FX class
- increased limits (matrix size, LED RAM)
- added "rainbow"-mode colorwheel
- replaced palettes with gamma unmodified ones
- move gamma adjustment to last step before sending to LEDs
- Segment & WS2812FX class reorganisation (mutable members, reordered members, protected members)
2025-04-22 22:37:18 +02:00
Damian Schneider
353868414a Removed PS memory manager and some minor improvements (#4651)
* Removed memory manager from PS

- reverted all changes related to memory manager
- moved local buffer into effect data memory
- some RAM issues may occur on larger setups: tested on S3 it works fine up to 32x32 but runs into memory issues at 64x32

* fixed ifdef, improved readability, add optimize "o2" flags to improve speed

- added struct for x and y coordinates, thx to @blazoncek

* cleanup and minor improvements

- removed local buffer for ESP8266 in 1D system to save on RAM
- increased particle brightness in PS Impact
- minor tweak in collision binning (might improve speed)
- removed comments and some other unused stuff
- fixed a few compiler wranings

* fixed init sequence bug
2025-04-20 11:38:32 +02:00
Damian Schneider
02f14baad4 Updates to particle system (#4630)
* added Sonic Boom AR FX, some tweaks to Sonic Stream
* added white color option to Sonic Stream
* improvements to collisions (speed look-ahead)
* code prettified
* added "playful" mode to PS Chase plus some minor speed optimizations
* Adding new FX: PS Springy with many config options
2025-04-15 19:07:21 +02:00
Damian Schneider
e76e9a3e1f Merge pull request #4594 from DedeHai/perlin_noise
Adding perlin noise replacement for fastled functions
2025-03-26 07:40:40 +01:00
Blaž Kristan
a70bfa0c89 Merge pull request #4596 from Dschogo/patch-1
Fix wipe effect smoothness
2025-03-16 10:58:02 +01:00
Damian Schneider
d2b7e474d6 add legacy defines for compatibility, reverted test changes in rotozoomer 2025-03-14 06:48:18 +01:00