Instead of fill_rainbow treating my project with how the LEDs are wired how can

fastled-support
gplus
(Brian Lewis) #1

Instead of fill_rainbow treating my project with how the LEDs are wired how can I get it to use one of the many maps that I’ve created?

(Chris Parton) #2

I don’t think FastLED supports this, bit if you look at the fill_rainbow implementation at https://github.com/FastLED/FastLED/blob/dbd2d8b8ca037f9d2d5e743785abac28b125c947/colorutils.cpp, you’ll see it’s quite a simple thing to implement.

I’d take a copy of that function and paste it in your code with a different name, and replace the i in pFirstLed[i] with the index you want.

Good luck!

(Brian Lewis) #3

@Chris_Parton Thanks Chris. Your suggestion worked great.

(Chris Parton) #4

No problem at all! You should share some photos or video of your project at some point :slight_smile:

(Brian Lewis) #5

@Chris_Parton I’ll try to get some decent photos and video taken. I’m using a thin sheet of white acrylic as a diffuser, which so far has made everything look blurry in photos.