25 0x000210, 0x000212, 0x000114, 0x000117,
26 0x000019, 0x00001C, 0x000026, 0x000031,
27 0x00003B, 0x000046, 0x14554B, 0x28AA50};
29 0x000210, 0x000212, 0x000114, 0x000117,
30 0x000019, 0x00001C, 0x000026, 0x000031,
31 0x00003B, 0x000046, 0x0C5F52, 0x19BE5F};
33 0x000820, 0x000927, 0x000B2D, 0x000C33,
34 0x000E39, 0x001040, 0x001450, 0x001860,
35 0x001C70, 0x002080, 0x1040BF, 0x2060FF};
38 u16 wavescale,
u8 bri, u16 ioff);
45 fl::u32 now = ctx.
now;
54 u16 speedfactor1 =
beatsin16(3, 179, 269);
55 u16 speedfactor2 =
beatsin16(4, 179, 269);
56 fl::u32 deltams1 = (deltams * speedfactor1) / 256;
57 fl::u32 deltams2 = (deltams * speedfactor2) / 256;
58 fl::u32 deltams21 = (deltams1 + deltams2) / 2;
89 u16 cistart, u16 wavescale,
93 u16 wavescale_half = (wavescale / 2) + 20;
96 u16 s16 = sin16(waveangle) + 32768;
97 u16 cs = scale16(s16, wavescale_half) + wavescale_half;
99 u16 sindex16 = sin16(ci) + 32768;
100 u8 sindex8 = scale16(sindex16, 240);
112 for (u16 i = 0; i <
mNumLeds; i++) {
113 u8 threshold = scale8(sin8(wave), 20) + basethreshold;
115 u8 l =
leds[i].getAverageLight();
117 u8 overage = l - threshold;
118 u8 overage2 = qadd8(overage, overage);
119 leds[i] +=
CRGB(overage, overage2, qadd8(overage2, overage2));
126 for (u16 i = 0; i <
mNumLeds; i++) {
127 leds[i].blue = scale8(
leds[i].blue, 145);
128 leds[i].green = scale8(
leds[i].green, 200);
void pacifica_deepen_colors()
void pacifica_add_whitecaps()
void draw(DrawContext context) override
void pacifica_deepen_colors(fl::span< CRGB > leds)
CRGBPalette16 pacifica_palette_1
CRGBPalette16 pacifica_palette_3
CRGBPalette16 pacifica_palette_2
void pacifica_one_layer(fl::span< CRGB > leds, CRGBPalette16 &p, u16 cistart, u16 wavescale, u8 bri, u16 ioff)
fl::string fxName() const override
void pacifica_add_whitecaps(fl::span< CRGB > leds)
LIB8STATIC u16 beat16(accum88 beats_per_minute, u32 timebase=0) FL_NOEXCEPT
Generates a 16-bit "sawtooth" wave at a given BPM.
LIB8STATIC u16 beatsin88(accum88 beats_per_minute_88, u16 lowest=0, u16 highest=65535, u32 timebase=0, u16 phase_offset=0) FL_NOEXCEPT
Generates a 16-bit sine wave at a given BPM that oscillates within a given range.
LIB8STATIC u8 beatsin8(accum88 beats_per_minute, u8 lowest=0, u8 highest=255, u32 timebase=0, u8 phase_offset=0) FL_NOEXCEPT
Generates an 8-bit sine wave at a given BPM that oscillates within a given range.
LIB8STATIC u8 beat8(accum88 beats_per_minute, u32 timebase=0) FL_NOEXCEPT
Generates an 8-bit "sawtooth" wave at a given BPM.
LIB8STATIC u16 beatsin16(accum88 beats_per_minute, u16 lowest=0, u16 highest=65535, u32 timebase=0, u16 phase_offset=0) FL_NOEXCEPT
Generates a 16-bit sine wave at a given BPM that oscillates within a given range.
void fill_solid(CRGB *targetArray, int numToFill, const CRGB &color)
Fill a range of LEDs with a solid color.
CRGB ColorFromPalette(const CRGBPalette16 &pal, fl::u8 index, fl::u8 brightness, TBlendType blendType)
Base definition for an LED controller.
#define FASTLED_SHARED_PTR(type)
Representation of an 8-bit RGB pixel (Red, Green, Blue)