Merge branch 'dev' into dev-0.12

This commit is contained in:
David Reid
2025-09-11 09:30:16 +10:00
11 changed files with 11605 additions and 3989 deletions
+11 -10
View File
@@ -1,6 +1,6 @@
/*
Audio playback and capture library. Choice of public domain or MIT-0. See license statements at the end of this file.
miniaudio - v0.11.23 - TBD
miniaudio - v0.11.23 - 2025-09-11
David Reid - mackron@gmail.com
@@ -14,7 +14,7 @@ GitHub: https://github.com/mackron/miniaudio
===============
To use miniaudio, just include "miniaudio.h" like any other header and add "miniaudio.c" to your
source tree. If you don't want to add it to your source tree you can compile and link to it like
any other library. Note that ABI compatiblity is not guaranteed between versions, even with bug
any other library. Note that ABI compatibility is not guaranteed between versions, even with bug
fix releases, so take care if compiling as a shared object.
miniaudio includes both low level and high level APIs. The low level API is good for those who want
@@ -295,7 +295,7 @@ The engine encapsulates both the resource manager and the node graph to create a
use high level API. The resource manager and node graph APIs are covered in more later sections of
this manual.
The code below shows how you can initialize an engine using it's default configuration.
The code below shows how you can initialize an engine using its default configuration.
```c
ma_result result;
@@ -383,7 +383,7 @@ Sounds are not started by default. Start a sound with `ma_sound_start()` and sto
`ma_sound_stop()`. When a sound is stopped, it is not rewound to the start. Use
`ma_sound_seek_to_pcm_frame(&sound, 0)` to seek back to the start of a sound. By default, starting
and stopping sounds happens immediately, but sometimes it might be convenient to schedule the sound
the be started and/or stopped at a specific time. This can be done with the following functions:
to be started and/or stopped at a specific time. This can be done with the following functions:
```c
ma_sound_set_start_time_in_pcm_frames()
@@ -529,7 +529,7 @@ you'll need to disable run-time linking with `MA_NO_RUNTIME_LINKING` and link wi
The Emscripten build emits Web Audio JavaScript directly and should compile cleanly out of the box.
You cannot use `-std=c*` compiler flags, nor `-ansi`.
You can enable the use of AudioWorkets by defining `MA_ENABLE_AUDIO_WORKLETS` and then compiling
You can enable the use of AudioWorklets by defining `MA_ENABLE_AUDIO_WORKLETS` and then compiling
with the following options:
-sAUDIO_WORKLET=1 -sWASM_WORKERS=1 -sASYNCIFY
@@ -872,7 +872,7 @@ read data within a certain range of the underlying data. To do this you can use
This is useful if you have a sound bank where many sounds are stored in the same file and you want
the data source to only play one of those sub-sounds. Note that once the range is set, everything
that takes a position, such as cursors and loop points, should always be relatvie to the start of
that takes a position, such as cursors and loop points, should always be relative to the start of
the range. When the range is set, any previously defined loop point will be reset.
Custom loop points can also be used with data sources. By default, data sources will loop after
@@ -880,7 +880,7 @@ they reach the end of the data source, but if you need to loop at a specific loc
the following:
```c
result = ma_data_set_loop_point_in_pcm_frames(pDataSource, loopBegInFrames, loopEndInFrames);
result = ma_data_source_set_loop_point_in_pcm_frames(pDataSource, loopBegInFrames, loopEndInFrames);
if (result != MA_SUCCESS) {
return result; // Failed to set the loop point.
}
@@ -46897,7 +46897,7 @@ static MA_INLINE void ma_pcm_s16_to_s32__reference(void* dst, const void* src, m
ma_uint64 i;
for (i = 0; i < count; i += 1) {
dst_s32[i] = src_s16[i] << 16;
dst_s32[i] = (ma_int32)src_s16[i] << 16;
}
(void)ditherMode;
@@ -63224,7 +63224,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 14
#define MA_DR_WAV_VERSION_REVISION 0
#define MA_DR_WAV_VERSION_REVISION 1
#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
@@ -63657,7 +63657,7 @@ extern "C" {
#define MA_DR_FLAC_XSTRINGIFY(x) MA_DR_FLAC_STRINGIFY(x)
#define MA_DR_FLAC_VERSION_MAJOR 0
#define MA_DR_FLAC_VERSION_MINOR 13
#define MA_DR_FLAC_VERSION_REVISION 0
#define MA_DR_FLAC_VERSION_REVISION 1
#define MA_DR_FLAC_VERSION_STRING MA_DR_FLAC_XSTRINGIFY(MA_DR_FLAC_VERSION_MAJOR) "." MA_DR_FLAC_XSTRINGIFY(MA_DR_FLAC_VERSION_MINOR) "." MA_DR_FLAC_XSTRINGIFY(MA_DR_FLAC_VERSION_REVISION)
#include <stddef.h>
#if defined(_MSC_VER) && _MSC_VER >= 1700
@@ -95593,6 +95593,7 @@ static ma_bool32 ma_dr_mp3_init_internal(ma_dr_mp3* pMP3, ma_dr_mp3_read_proc on
pMP3->pcmFramesRemainingInMP3Frame = 0;
pMP3->streamStartOffset += (ma_uint32)(firstFrameInfo.frame_bytes);
pMP3->streamCursor = pMP3->streamStartOffset;
ma_dr_mp3dec_init(&pMP3->decoder);
}
} else {
}