MCPcopy Create free account
hub / github.com/TheRealMJP/DeferredTexturing / Round

Function Round

SampleFramework12/v1.00/SF12_Math.h:573–576  ·  view source on GitHub ↗

Rounds a float

Source from the content-addressed store, hash-verified

571
572// Rounds a float
573inline float Round(float r)
574{
575 return (r > 0.0f) ? std::floorf(r + 0.5f) : std::ceilf(r - 0.5f);
576}
577
578// Returns a random float value between 0 and 1
579inline float RandFloat()

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected