With this change, dr_wav is now namespaced with "ma" which means dr_wav
can now be used alongside miniaudio.
In addition, some duplicate code has been removed, such as sized types,
result codes, allocation callbacks, etc. which reduces the size of the
file slightly.
This should address the following public issue:
https://github.com/mackron/miniaudio/issues/673
miniaudio is updating it's amalgamation of dr_wav, etc. so that it's
all namespaced with "ma" which will make the amalgamated versions of
dr_libs entirely independent. There's no longer any need to mention
the decoding backends.
Documentation regarding stb_vorbis is removed so as to discourage
new users from using it. Support will not be removed until a
replacement Vorbis decoder can be amalgamated, but new users should
instead be guided to the libvorbis custom decoder in the extras folder.
* Sized types will now use miniaudio's types.
* Architecture macros now use miniaudio's macros.
* The c89atomic namespace has been renamed to ma_atomic which makes
it so c89atomic can be used alongside miniaudio without naming
conflicts.
Public issue https://github.com/mackron/miniaudio/issues/673
This commit makes it so SetFilePointer/Ex() are dynamically loaded at
runtime which allows miniaudio to branch dynamically based on available
support.
This is necessary because versions of Windows prior to XP do not
support the Ex version which results in an error when trying to run the
program.
Public issue https://github.com/mackron/miniaudio/issues/672
Since the calling thread is waiting anyway, it's better to just do the
processing on the calling thread rather than posting it to the job
queue and waiting. This ensures the calling thread stays busy which
will improve performance, but it also makes it so the calling thread
doesn't get stalled while already-queued jobs are getting processed.
This is still not working on my machine. The device will initialize and
run, but the captured data is always silent for some reason. I have
been unable to figure out how to make this work.
This commit allows initialization of the device to complete at the very
least.
Public issue https://github.com/mackron/miniaudio/issues/484
The issue here is that it's possible for miniaudio to attempt to access
data from a WAVEFORMATEXTENSIBLE structure when the object is actually
only a WAVEFORMATEX structure which is smaller which can therefore
result in trying to access unallocated memory.
Public issue https://github.com/mackron/miniaudio/issues/660
Smoothing is disabled by default. To enable it, you must use
ma_sound_init_ex() and configure it via the volumeSmoothTimeInPCMFrames
member of ma_sound_config.
This commit also fixes a bug where ma_gainer is not properly applying
smoothing.
* ma_engine_get_time_in_pcm_frames() (replaces ma_engine_get_time())
* ma_engine_get_time_in_milliseconds()
* ma_engine_set_time_in_pcm_frames() (replaces ma_engine_set_time())
* ma_engine_set_time_in_milliseconds()
These changes are consistent with the naming of other time based
functions, eliminates ambiguity and just makes it clearer as to what
you're working with.
ma_engine_get_time() and ma_engine_set_time() have been deprecated.
This is not pre-initializing the variable that receives the number of
bytes read to 0 which can result in custom VFS implementations
returning an invalid value if they return early from an error or
whatnot.