I'm confused about the multiple possibilities of setting the brightness so first this to

I’m confused about the multiple possibilities of setting the brightness

so first this to lines are possible is there any difference?:
LEDS.setBrightness(currentBrigthness);
CFastLED.setBrightness(currentBrigthness);

then the CHSV(part->Hue, 200, 255); tells me the third value is also brightness. But for a single pixel, which makes sense, but is this in the bounds of the general brightness?

anyway would someone be Interessted in doing a little code review of my code? I’m not so familiar with C++ and would be happy to show somone more experienced my code. It works in general (some anymations don’t, are not tested or are not made for a single strip) but the logic is tested and works. It allows to update different led parts easy with different animations.

Yes, those first two will do the same for setting master brightness. Could also be written as FastLED.setBrightness(currentBrightness);

This master brightness is applied on top of whatever an individual pixel has been set to. For example, if you set a pixel to a “half” bright red using either CHSV(0,255,128) or CRGB(128,0,0) and then set setBrightness(128) this would result in the data sent out to the strip being 50% less bright, and the RGB data sent out would be R 64, G 0, B 0.

However, it doesn’t actually change the value of the pixel in memory on the controller. It only changes the data value sent out to the strip at the time FastLED.show() is called.

//So if we set pixel[0] as
pixel[0] = CHSV(0,255,128);

// and set master brightness
FastLED.setBrightness(255);
FastLED.show();
// pixel[0] displays a “half” bright red

// and then changed master brightness
FastLED.setBrightness(128);
FastLED.show();
// pixel[0] displays a “quarter” bright red now but it’s value hasn’t been changed.

// and then again back to
FastLED.setBrightness(255);
FastLED.show();
// pixel[0] displays a “half” bright red again without ever changing it’s assigned value.

Don’t use the CFastLED version - that’s the name of the class, not an object. LEDS and FastLED refer to the same object (historical naming convention).

Think of this like a mixer. On a mixer, you can set the volume of individual channels (or, in FastLED, the brighntess of a single LED with the third value in CHSV) but you can also set a global volume (the master volume, or in FastLED, LEDS.setBrightness) that will allow you to dim everything all at once.

If you want folks to check out your code - post it to http://gist.github.com and share the link here.

Okay thanks you guys…

@marmil ​ thank you for the very specific and detailed answer
@Daniel_Garcia ​ i added the Clasdname becsuse i could have called thr object anyway i liked… so i just wanted to ve sure we are talking about the same…but probably this was more confusing than helpfull. i will upload it to git then…