Clean up math functions

- Remove checking for standard functions from the build system
- Prefix all invocations with std::
- Replace suffixed functions with unprefixed versions
- Include <cmath> in all files that use it and remove the global include

e.g. floorf(x) -> std::floor(x)
This commit is contained in:
Martin Natano
2023-04-19 19:31:40 +02:00
parent f39ed52dbf
commit b68ca517e6
111 changed files with 1831 additions and 1785 deletions
+3 -1
View File
@@ -2,6 +2,8 @@
#include "RageSoundMixBuffer.h"
#include "RageUtil.h"
#include <cmath>
#if defined(MACOSX)
#include "archutils/Darwin/VectorHelper.h"
#ifdef USE_VEC
@@ -79,7 +81,7 @@ void RageSoundMixBuffer::read( int16_t *pBuf )
{
float iOut = m_pMixbuf[iPos];
iOut = clamp( iOut, -1.0f, +1.0f );
pBuf[iPos] = lrintf(iOut * 32767);
pBuf[iPos] = std::lrint(iOut * 32767);
}
m_iBufUsed = 0;
}