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

◆ ease16InOutQuad()

LIB8STATIC uint16_t ease16InOutQuad ( uint16_t i)

16-bit quadratic ease-in / ease-out function.

C implementation at this point.

Definition at line 607 of file lib8tion.h.

608{
609 uint16_t j = i;
610 if( j & 0x8000 ) {
611 j = 65535 - j;
612 }
613 uint16_t jj = scale16( j, j);
614 uint16_t jj2 = jj << 1;
615 if( i & 0x8000 ) {
616 jj2 = 65535 - jj2;
617 }
618 return jj2;
619}
LIB8STATIC uint16_t scale16(uint16_t i, fract16 scale)
Scale a 16-bit unsigned value by an 16-bit value, which is treated as the numerator of a fraction who...
Definition scale8.h:546

References LIB8STATIC, and scale16().

+ Here is the call graph for this function: