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

Function floor_impl_double

src/fl/math/math.cpp.hpp:52–58  ·  view source on GitHub ↗

Standalone floor implementation for double

Source from the content-addressed store, hash-verified

50
51// Standalone floor implementation for double
52double floor_impl_double(double value) {
53 if (value >= 0.0) {
54 return static_cast<double>(static_cast<long long>(value));
55 }
56 long long i = static_cast<long long>(value);
57 return static_cast<double>(i - (value != static_cast<double>(i) ? 1 : 0));
58}
59
60// Standalone ceil implementation for float
61float ceil_impl_float(float value) {

Callers 2

fmod_impl_doubleFunction · 0.85
floorFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected