mirror of
https://github.com/mackron/miniaudio.git
synced 2026-04-22 00:06:59 +02:00
Integrate the new data converter into playback devices.
This commit is contained in:
+443
-387
File diff suppressed because it is too large
Load Diff
+4
-4
@@ -603,10 +603,10 @@ int do_format_conversion_test(ma_format formatIn, ma_format formatOut)
|
|||||||
if (allowSmallDifference) {
|
if (allowSmallDifference) {
|
||||||
if (formatOut == ma_format_f32) {
|
if (formatOut == ma_format_f32) {
|
||||||
switch (formatIn) {
|
switch (formatIn) {
|
||||||
case ma_format_u8: allowedDifference = 1.0f / 255 * 2; break;
|
case ma_format_u8: allowedDifference = (float)(1.0 / 255 * 2); break;
|
||||||
case ma_format_s16: allowedDifference = 1.0f / 32767 * 2; break;
|
case ma_format_s16: allowedDifference = (float)(1.0 / 32767 * 2); break;
|
||||||
case ma_format_s24: allowedDifference = 1.0f / 8388608 * 2; break;
|
case ma_format_s24: allowedDifference = (float)(1.0 / 8388608 * 2); break;
|
||||||
case ma_format_s32: allowedDifference = 1.0f / 2147483647 * 2; break;
|
case ma_format_s32: allowedDifference = (float)(1.0 / 2147483647 * 2); break;
|
||||||
case ma_format_f32: allowedDifference = 0; break;
|
case ma_format_f32: allowedDifference = 0; break;
|
||||||
default: break;
|
default: break;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user