FastLED 3.10.10
Loading...
Searching...
No Matches

◆ tryEncodeManagedSpi()

FL_NO_INLINE bool fl::anonymous_namespace{channel.cpp.hpp}::tryEncodeManagedSpi ( Channel & channel,
PixelIterator & pixels,
bool managed,
fl::vector_psram< u8 > & output,
SpiChipset chipset )

Shared color-managed SPI override check.

Keeping it out of the per-chipset leaves avoids duplicating the optional pipeline hook in every writer.

Definition at line 673 of file channel.cpp.hpp.

676 {
677#if FL_COLOR_PROFILE_RUNTIME
678 if (!managed) {
679 return false;
680 }
681 const ColorPipelineHooks& hooks = colorPipelineHooks();
682 return hooks.encodeManagedSpi != nullptr &&
683 hooks.encodeManagedSpi(pixels, &output, chipset, channel);
684#else
685 FL_UNUSED(channel);
686 FL_UNUSED(pixels);
687 FL_UNUSED(managed);
688 FL_UNUSED(output);
689 FL_UNUSED(chipset);
690 return false;
691#endif
692}
ColorPipelineHooks & colorPipelineHooks() FL_NO_EXCEPT
The installed hooks.
bool(* encodeManagedSpi)(PixelIterator &pixels, vector_psram< u8 > *out, SpiChipset chip, const Channel &controller)
Unscaled (full-brightness) power demand of leds as the pipeline will drive them, in mW,...
#define FL_UNUSED(x)

References fl::colorPipelineHooks(), fl::ColorPipelineHooks::encodeManagedSpi, fl::FL_NO_EXCEPT, FL_UNUSED, and tryEncodeManagedSpi().

Referenced by tryEncodeManagedSpi().

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