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

◆ drawFireDance()

CRGB drawFireDance ( const RingCoord & coord,
uint32_t time_ms,
ColorPaletteManager & palette )

Definition at line 354 of file FxNoiseRing.h.

354 {
355 float vertical_component = sin(coord.angle) * 0.5f + 0.5f;
356
357 float flame_x = coord.x * 1500;
358 float flame_y = coord.y * 1500 + time_ms * 0.003f;
359
360 uint16_t turbulence = inoise16(flame_x, flame_y, time_ms);
361 float flame_intensity = (turbulence / 65536.0f) * (1.0f - vertical_component * 0.3f);
362
363 float fire_hue = flame_intensity * 0.15f; // Red to orange range
364 return palette.mapColor(fire_hue, flame_intensity);
365}
UINumberField palette("Palette", 0, 0, 2)
float angle
Definition FxNoiseRing.h:47
uint16_t inoise16(uint32_t x, uint32_t y, uint32_t z, uint32_t t)
16-bit, fixed point implementation of Perlin's noise.
Definition noise.cpp:420

References RingCoord::angle, inoise16(), palette(), RingCoord::x, and RingCoord::y.

Referenced by NoiseVariantManager::renderVariant().

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