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

◆ atan() [2/2]

template<typename Derived, int IntBits, int FracBits>
static FASTLED_FORCE_INLINE Derived fl::fixed_point_base< Derived, IntBits, FracBits >::atan ( Derived x)
inlinestatic

Definition at line 166 of file base.h.

166 {
167 constexpr Derived one(1.0f);
168 constexpr Derived pi_over_2(1.5707963f);
169 bool neg = x.mValue < 0;
170 Derived ax = abs(x);
172 if (ax <= one) {
174 } else {
176 }
177 return neg ? -result : result;
178 }
raw_type mValue
Definition base.h:41
static FASTLED_FORCE_INLINE Derived atan_unit(Derived t)
Definition base.h:485
constexpr FASTLED_FORCE_INLINE Derived abs() const
Definition base.h:266

References abs(), atan_unit(), FASTLED_FORCE_INLINE, and fl::x.

+ Here is the call graph for this function: