Commit e32cc9ff authored by David Reid's avatar David Reid

Update dr_wav and dr_mp3.

parent babd7fb0
......@@ -59830,7 +59830,7 @@ extern "C" {
#define MA_DR_WAV_XSTRINGIFY(x) MA_DR_WAV_STRINGIFY(x)
#define MA_DR_WAV_VERSION_MAJOR 0
#define MA_DR_WAV_VERSION_MINOR 13
#define MA_DR_WAV_VERSION_REVISION 14
#define MA_DR_WAV_VERSION_REVISION 16
#define MA_DR_WAV_VERSION_STRING MA_DR_WAV_XSTRINGIFY(MA_DR_WAV_VERSION_MAJOR) "." MA_DR_WAV_XSTRINGIFY(MA_DR_WAV_VERSION_MINOR) "." MA_DR_WAV_XSTRINGIFY(MA_DR_WAV_VERSION_REVISION)
#include <stddef.h>
#define MA_DR_WAVE_FORMAT_PCM 0x1
......@@ -60537,7 +60537,7 @@ extern "C" {
#define MA_DR_MP3_XSTRINGIFY(x) MA_DR_MP3_STRINGIFY(x)
#define MA_DR_MP3_VERSION_MAJOR 0
#define MA_DR_MP3_VERSION_MINOR 6
#define MA_DR_MP3_VERSION_REVISION 38
#define MA_DR_MP3_VERSION_REVISION 39
#define MA_DR_MP3_VERSION_STRING MA_DR_MP3_XSTRINGIFY(MA_DR_MP3_VERSION_MAJOR) "." MA_DR_MP3_XSTRINGIFY(MA_DR_MP3_VERSION_MINOR) "." MA_DR_MP3_XSTRINGIFY(MA_DR_MP3_VERSION_REVISION)
#include <stddef.h>
#define MA_DR_MP3_MAX_PCM_FRAMES_PER_MP3_FRAME 1152
......@@ -81716,7 +81716,7 @@ MA_API void ma_dr_wav_f32_to_s32(ma_int32* pOut, const float* pIn, size_t sample
return;
}
for (i = 0; i < sampleCount; ++i) {
*pOut++ = (ma_int32)(2147483648.0 * pIn[i]);
*pOut++ = (ma_int32)(2147483648.0f * pIn[i]);
}
}
MA_API void ma_dr_wav_f64_to_s32(ma_int32* pOut, const double* pIn, size_t sampleCount)
......@@ -91204,8 +91204,8 @@ static ma_int16 ma_dr_mp3d_scale_pcm(float sample)
s32 -= (s32 < 0);
s = (ma_int16)ma_dr_mp3_clip_int16_arm(s32);
#else
if (sample >= 32766.5) return (ma_int16) 32767;
if (sample <= -32767.5) return (ma_int16)-32768;
if (sample >= 32766.5f) return (ma_int16) 32767;
if (sample <= -32767.5f) return (ma_int16)-32768;
s = (ma_int16)(sample + .5f);
s -= (s < 0);
#endif
......@@ -91591,9 +91591,9 @@ MA_API void ma_dr_mp3dec_f32_to_s16(const float *in, ma_int16 *out, size_t num_s
for(; i < num_samples; i++)
{
float sample = in[i] * 32768.0f;
if (sample >= 32766.5)
if (sample >= 32766.5f)
out[i] = (ma_int16) 32767;
else if (sample <= -32767.5)
else if (sample <= -32767.5f)
out[i] = (ma_int16)-32768;
else
{
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment