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

◆ updatef()

float fl::TimeClampedTransition::updatef ( u32 now)
inlineoverridevirtual

Reimplemented from fl::TimeAlpha.

Definition at line 151 of file time_alpha.h.

151 {
152 bool not_started = (mEnd == 0) && (mStart == 0);
153 if (not_started) {
154 return 0;
155 }
156 float out = time_alphaf(now, mStart, mEnd);
157 if (mMaxClamp > 0.f) {
158 out = fl::min(out, mMaxClamp);
159 }
160 return out;
161 }
FL_DISABLE_WARNING_PUSH U constexpr common_type_t< T, U > min(T a, U b) FL_NOEXCEPT
Definition math.h:71
float time_alphaf(u32 now, u32 start, u32 end) FL_NOEXCEPT
Definition time_alpha.h:25

References FL_NOEXCEPT, mEnd, fl::min(), mMaxClamp, mStart, and fl::time_alphaf().

+ Here is the call graph for this function: