mirror of
https://github.com/mackron/miniaudio.git
synced 2026-04-24 09:14:04 +02:00
Merge branch 'dev' into dev-0.12
This commit is contained in:
+46
-45
@@ -1,52 +1,53 @@
|
|||||||
\#docs/
|
\#docs/
|
||||||
_private/
|
/_private/
|
||||||
build/
|
/build/
|
||||||
debugging/
|
/debugging/
|
||||||
evaluations/
|
/evaluations/
|
||||||
examples/build/bin/
|
/examples/build/bin/
|
||||||
examples/build/codelite/
|
/examples/build/codelite/
|
||||||
examples/build/vc6/
|
/examples/build/vc6/
|
||||||
examples/build/vc15/
|
/examples/build/vc15/
|
||||||
examples/build/vc17/
|
/examples/build/vc17/
|
||||||
examples/simple_playback_sine.cpp
|
/examples/simple_playback_sine.cpp
|
||||||
external/ogg/
|
/external/ogg/
|
||||||
external/vorbis/
|
/external/vorbis/
|
||||||
external/opus/
|
/external/opus/
|
||||||
external/opusfile/
|
/external/opusfile/
|
||||||
extras/osaudio/tests/build/bin/
|
/extras/osaudio/tests/build/bin/
|
||||||
extras/osaudio/tests/build/vc17/
|
/extras/osaudio/tests/build/vc17/
|
||||||
extras/osaudio/tests/build/watcom-dos/
|
/extras/osaudio/tests/build/watcom-dos/
|
||||||
extras/backends/pipewire/a.out
|
/extras/backends/pipewire/a.out
|
||||||
extras/decoders/litewav/
|
/extras/decoders/litewav/
|
||||||
research/_build/
|
/research/_build/
|
||||||
tests/_build/bin/
|
/tests/_build/bin/
|
||||||
tests/_build/res/output/
|
/tests/_build/res/output/
|
||||||
tests/_build/tcc/
|
/tests/_build/tcc/
|
||||||
tests/_build/vc6/
|
/tests/_build/vc6/
|
||||||
tests/_build/vc15/
|
/tests/_build/vc15/
|
||||||
tests/_build/vc17/
|
/tests/_build/vc17/
|
||||||
tests/_build/watcom/
|
/tests/_build/watcom/
|
||||||
tests/_build/capture.wav
|
/tests/_build/capture.wav
|
||||||
tests/_build/a.out
|
/tests/_build/a.out
|
||||||
tests/_build/a.exe
|
/tests/_build/a.exe
|
||||||
tests/test_stress/
|
/tests/debugging/archive/
|
||||||
tests/*.c
|
/tests/test_stress/
|
||||||
tests/*.cpp
|
/tests/*.c
|
||||||
tools/_build/
|
/tests/*.cpp
|
||||||
website/docs/
|
/tools/_build/
|
||||||
|
/website/docs/
|
||||||
*.vcxproj.user
|
*.vcxproj.user
|
||||||
.vs/
|
.vs/
|
||||||
.idea/
|
.idea/
|
||||||
.vscode/
|
.vscode/
|
||||||
|
|
||||||
# Below are individual files that I may start version controlling later or delete outright.
|
# Below are individual files that I may start version controlling later or delete outright.
|
||||||
examples/build/COSMO.txt
|
/examples/build/COSMO.txt
|
||||||
research/ma_fft.c
|
/research/ma_fft.c
|
||||||
research/ma_hrtf.c
|
/research/ma_hrtf.c
|
||||||
research/ma_atomic.c
|
/research/ma_atomic.c
|
||||||
research/miniaudio_engine.c
|
/research/miniaudio_engine.c
|
||||||
tools/codegen/miniaudio_amalgamator.c
|
/tools/codegen/miniaudio_amalgamator.c
|
||||||
tools/codegen/miniaudio_codegen_utils.c
|
/tools/codegen/miniaudio_codegen_utils.c
|
||||||
tools/codegen/miniaudio_docgen.c
|
/tools/codegen/miniaudio_docgen.c
|
||||||
tools/codegen/miniaudio_hrtfgen.c
|
/tools/codegen/miniaudio_hrtfgen.c
|
||||||
tools/codegen/miniaudio_splitter.c
|
/tools/codegen/miniaudio_splitter.c
|
||||||
+7
-4
@@ -26,7 +26,7 @@ option(MINIAUDIO_NO_OPENSL "Disable the OpenSL|ES backend"
|
|||||||
option(MINIAUDIO_NO_WEBAUDIO "Disable the Web Audio backend" OFF)
|
option(MINIAUDIO_NO_WEBAUDIO "Disable the Web Audio backend" OFF)
|
||||||
option(MINIAUDIO_NO_CUSTOM "Disable support for custom backends" OFF)
|
option(MINIAUDIO_NO_CUSTOM "Disable support for custom backends" OFF)
|
||||||
option(MINIAUDIO_NO_NULL "Disable the null backend" OFF)
|
option(MINIAUDIO_NO_NULL "Disable the null backend" OFF)
|
||||||
option(MINIAUDIO_ENABLE_ONLY_SPECIFIC_BACKENDS "Only enable specific backends. Backends can be enabled with MINIAUDIO_ENABLE_[BACKEND]" OFF)
|
option(MINIAUDIO_ENABLE_ONLY_SPECIFIC_BACKENDS "Only enable specific backends. Backends can be enabled with MINIAUDIO_ENABLE_[BACKEND]." OFF)
|
||||||
option(MINIAUDIO_ENABLE_WASAPI "Enable the WASAPI backend" OFF)
|
option(MINIAUDIO_ENABLE_WASAPI "Enable the WASAPI backend" OFF)
|
||||||
option(MINIAUDIO_ENABLE_DSOUND "Enable the DirectSound backend" OFF)
|
option(MINIAUDIO_ENABLE_DSOUND "Enable the DirectSound backend" OFF)
|
||||||
option(MINIAUDIO_ENABLE_WINMM "Enable the WinMM backend" OFF)
|
option(MINIAUDIO_ENABLE_WINMM "Enable the WinMM backend" OFF)
|
||||||
@@ -51,8 +51,8 @@ option(MINIAUDIO_NO_DEVICEIO "Disable audio playback and captu
|
|||||||
option(MINIAUDIO_NO_RESOURCE_MANAGER "Disable the resource manager API" OFF)
|
option(MINIAUDIO_NO_RESOURCE_MANAGER "Disable the resource manager API" OFF)
|
||||||
option(MINIAUDIO_NO_NODE_GRAPH "Disable the node graph API" OFF)
|
option(MINIAUDIO_NO_NODE_GRAPH "Disable the node graph API" OFF)
|
||||||
option(MINIAUDIO_NO_ENGINE "Disable the high-level engine API" OFF)
|
option(MINIAUDIO_NO_ENGINE "Disable the high-level engine API" OFF)
|
||||||
option(MINIAUDIO_NO_THREADING "Disable threading. Must be used with MINIAUDIO_NO_DEVICEIO" OFF)
|
option(MINIAUDIO_NO_THREADING "Disable threading. Must be used with MINIAUDIO_NO_DEVICEIO." OFF)
|
||||||
option(MINIAUDIO_NO_GENERATION "Disable generation APIs such as ma_waveform" OFF)
|
option(MINIAUDIO_NO_GENERATION "Disable generation APIs such as ma_waveform and ma_noise" OFF)
|
||||||
option(MINIAUDIO_NO_SSE2 "Disable SSE2 optimizations" OFF)
|
option(MINIAUDIO_NO_SSE2 "Disable SSE2 optimizations" OFF)
|
||||||
option(MINIAUDIO_NO_AVX2 "Disable AVX2 optimizations" OFF)
|
option(MINIAUDIO_NO_AVX2 "Disable AVX2 optimizations" OFF)
|
||||||
option(MINIAUDIO_NO_NEON "Disable NEON optimizations" OFF)
|
option(MINIAUDIO_NO_NEON "Disable NEON optimizations" OFF)
|
||||||
@@ -525,11 +525,14 @@ if(MINIAUDIO_BUILD_TESTS)
|
|||||||
target_link_libraries(${name} PRIVATE miniaudio_common_options)
|
target_link_libraries(${name} PRIVATE miniaudio_common_options)
|
||||||
endfunction()
|
endfunction()
|
||||||
|
|
||||||
|
# The debugging test is only used for debugging miniaudio itself. Don't do add_test() for this, and do not include it in in any automated testing.
|
||||||
|
add_miniaudio_test(miniaudio_debugging debugging/debugging.cpp)
|
||||||
|
|
||||||
add_miniaudio_test(miniaudio_test_deviceio test_deviceio/ma_test_deviceio.c)
|
add_miniaudio_test(miniaudio_test_deviceio test_deviceio/ma_test_deviceio.c)
|
||||||
add_test(NAME miniaudio_test_deviceio COMMAND miniaudio_test_deviceio --auto)
|
add_test(NAME miniaudio_test_deviceio COMMAND miniaudio_test_deviceio --auto)
|
||||||
|
|
||||||
# This is just to test the C++ build. Don't do add_test() for this.
|
|
||||||
add_miniaudio_test(miniaudio_test_cpp test_cpp/ma_test_cpp.cpp)
|
add_miniaudio_test(miniaudio_test_cpp test_cpp/ma_test_cpp.cpp)
|
||||||
|
add_test(NAME miniaudio_test_cpp COMMAND miniaudio_test_cpp --auto) # This is just the deviceio test.
|
||||||
|
|
||||||
add_miniaudio_test(miniaudio_test_automated test_automated/ma_test_automated.c)
|
add_miniaudio_test(miniaudio_test_automated test_automated/ma_test_automated.c)
|
||||||
add_test(NAME miniaudio_test_automated COMMAND miniaudio_test_automated)
|
add_test(NAME miniaudio_test_automated COMMAND miniaudio_test_automated)
|
||||||
|
|||||||
@@ -10,8 +10,7 @@ Custom backends are identified with the `ma_backend_custom` backend type. For th
|
|||||||
backends would actually get hit. By default, the `ma_backend_custom` backend is the second-lowest priority backend, sitting just above
|
backends would actually get hit. By default, the `ma_backend_custom` backend is the second-lowest priority backend, sitting just above
|
||||||
`ma_backend_null`.
|
`ma_backend_null`.
|
||||||
*/
|
*/
|
||||||
#define MINIAUDIO_IMPLEMENTATION
|
#include "../miniaudio.c"
|
||||||
#include "../miniaudio.h"
|
|
||||||
|
|
||||||
/* We're using SDL for this example. To use this in your own program, you need to include backend_sdl.h after miniaudio.h. */
|
/* We're using SDL for this example. To use this in your own program, you need to include backend_sdl.h after miniaudio.h. */
|
||||||
#include "../extras/backends/sdl/backend_sdl.h"
|
#include "../extras/backends/sdl/backend_sdl.h"
|
||||||
|
|||||||
@@ -19244,6 +19244,11 @@ static void ma_device__handle_data_callback(ma_device* pDevice, void* pFramesOut
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
ma_device_restore_denormals(pDevice, prevDenormalState);
|
ma_device_restore_denormals(pDevice, prevDenormalState);
|
||||||
|
} else {
|
||||||
|
/* No data callback. Just silence the output. */
|
||||||
|
if (pFramesOut != NULL) {
|
||||||
|
ma_silence_pcm_frames(pFramesOut, frameCount, pDevice->playback.format, pDevice->playback.channels);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,10 @@
|
|||||||
|
/* This is just a sandbox for debugging miniaudio. Do not run this as part of some automated testing process. */
|
||||||
|
#include "../../miniaudio.c"
|
||||||
|
|
||||||
|
int main(int argc, char** argv)
|
||||||
|
{
|
||||||
|
(void)argc;
|
||||||
|
(void)argv;
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user