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

◆ lerp8()

FASTLED_FORCE_INLINE CRGB CRGB::lerp8 ( const CRGB & other,
fract8 frac ) const

Return a new CRGB object after performing a linear interpolation between this object and the passed in object.

Definition at line 176 of file crgb.hpp.

177{
178 CRGB ret;
179
180 ret.r = lerp8by8(r,other.r,frac);
181 ret.g = lerp8by8(g,other.g,frac);
182 ret.b = lerp8by8(b,other.b,frac);
183
184 return ret;
185}
LIB8STATIC uint8_t lerp8by8(uint8_t a, uint8_t b, fract8 frac)
Linear interpolation between two unsigned 8-bit values, with 8-bit fraction.
Definition lib8tion.h:455
FASTLED_FORCE_INLINE CRGB()=default
Default constructor.

References CRGB(), FASTLED_FORCE_INLINE, and lerp8by8().

+ Here is the call graph for this function: