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

◆ calculateCorkscrewHeight()

fl::u16 fl::calculateCorkscrewHeight ( float totalTurns,
fl::u16 numLeds )
constexpr

Definition at line 55 of file corkscrew.h.

55 {
56 return (calculateCorkscrewWidth(totalTurns, numLeds) * static_cast<int>(ceil_constexpr(totalTurns)) > numLeds) ?
57 static_cast<fl::u16>(ceil_constexpr(static_cast<float>(numLeds) / static_cast<float>(calculateCorkscrewWidth(totalTurns, numLeds)))) :
58 static_cast<fl::u16>(ceil_constexpr(totalTurns));
59}
constexpr int ceil_constexpr(float value) FL_NOEXCEPT
Definition math.h:287
constexpr fl::u16 calculateCorkscrewWidth(float totalTurns, fl::u16 numLeds)
Definition corkscrew.h:51
Base definition for an LED controller.
Definition crgb.hpp:179

References calculateCorkscrewWidth(), and ceil_constexpr().

+ Here is the call graph for this function: