MCPcopy Create free account
hub / github.com/FastLED/FastLED / fmod_impl_double

Function fmod_impl_double

src/fl/math/math.cpp.hpp:413–422  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

411}
412
413double fmod_impl_double(double x, double y) {
414#if FL_MATH_USE_LIBM
415 return ::fmod(x, y);
416#else
417 if (y == 0.0) return 0.0;
418 const double q = x / y;
419 const double t = q >= 0.0 ? floor_impl_double(q) : ceil_impl_double(q);
420 return x - t * y;
421#endif
422}
423
424// Inverse tangent 2 implementations (atan2).
425//

Callers 1

fmod<double>Function · 0.85

Calls 3

fmodFunction · 0.85
floor_impl_doubleFunction · 0.85
ceil_impl_doubleFunction · 0.85

Tested by

no test coverage detected