Commit Graph

1302 Commits

Author SHA1 Message Date
David Reid f1625a02ae Return a more accurate error code from ma_device_init(). 2019-10-22 17:31:20 +10:00
David Reid d7cefd29bc Merge branch 'master' into dev 2019-10-19 07:48:54 +10:00
David Reid 1ca6f80698 Fix some tests.
These compilation errors are a result of the recent change to dr_wav to
add support for allocation callbacks.
2019-10-19 07:46:44 +10:00
David Reid 98792caeaa Resampling testing. 2019-10-19 07:40:46 +10:00
David Reid b69f366793 Update dr_mp3. 2019-10-08 19:46:20 +10:00
David Reid c9a3b0800c Version 0.9.8 2019-10-07 09:11:57 +10:00
David Reid 268abad8d2 Update external libraries. 2019-10-07 08:34:42 +10:00
David Reid 154bb46bab Update dr_wav. 2019-10-07 07:24:03 +10:00
David Reid 25b8d2e47c Merge pull request #98 from mgambrell/master
remove a stray garbage byte (0x10) from the source file which makes visual studio unable to open it sometimes :o
2019-10-04 07:23:19 +00:00
mgambrell 7ead49dba3 remove a stray garbage byte (0x10) from the source file which makes visual studio unable to open it sometimes :o 2019-10-03 17:19:44 -04:00
David Reid 508e9b60a5 WASAPI: Relax low-latency shared mode restrictions.
This change enabled the use of low-latency shared mode if the desired
sample rate matches the native sample rate.
2019-10-03 19:37:31 +10:00
David Reid ff5d4e615e WASAPI: Fix errors with the use of AUDCLNT_STREAMFLAGS_AUTOCONVERTPCM.
AUDCLNT_STREAMFLAGS_AUTOCONVERTPCM is incompatible in exclusive mode
and low-latency shared mode.
2019-10-03 19:29:44 +10:00
David Reid 3f5aebfadb [WASAPI] Try fixing indefinitely repeating glitches in duplex mode. 2019-10-02 19:21:25 +10:00
David Reid 68ffbb3e07 WASAPI: Try reducing the playback start threshold in duplex mode. 2019-09-30 20:42:18 +10:00
David Reid ed8135610a WASAPI: Fix a wrong-way-around conditional. 2019-09-30 20:31:39 +10:00
David Reid 43bf6a1a97 WASAPI: Properly detect and report overruns in duplex mode. 2019-09-30 20:27:20 +10:00
David Reid a38fe4a042 WASAPI: Correctly handle AUDCLNT_BUFFERFLAGS_SILENT. 2019-09-30 20:21:56 +10:00
David Reid c69b1e48c4 Clarify that changing volume does not change the system volume. 2019-09-29 21:14:39 +10:00
David Reid 9043985ce6 Fix some issues with dithering. 2019-09-29 17:11:27 +10:00
David Reid 6cf6f3f9d8 Possible fix for some atomic exchange errors. 2019-09-29 15:49:16 +10:00
David Reid d1f70beba4 Fix some Clang warnings. 2019-09-29 15:03:14 +10:00
David Reid 0d89891118 Add support for per-device master volume control.
New Device APIs:
  * ma_device_set_master_volume()
  * ma_device_get_master_volume()
  * ma_device_set_master_gain_db()
  * ma_device_get_master_gain_db()

New Helper APIs
  * ma_copy_and_apply_volume_factor_u8()
  * ma_copy_and_apply_volume_factor_s16()
  * ma_copy_and_apply_volume_factor_s24()
  * ma_copy_and_apply_volume_factor_s32()
  * ma_copy_and_apply_volume_factor_f32()
  * ma_apply_volume_factor_u8()
  * ma_apply_volume_factor_s16()
  * ma_apply_volume_factor_s24()
  * ma_apply_volume_factor_s32()
  * ma_apply_volume_factor_f32()
  * ma_copy_and_apply_volume_factor_pcm_frames_u8()
  * ma_copy_and_apply_volume_factor_pcm_frames_s16()
  * ma_copy_and_apply_volume_factor_pcm_frames_s24()
  * ma_copy_and_apply_volume_factor_pcm_frames_s32()
  * ma_copy_and_apply_volume_factor_pcm_frames_f32()
  * ma_copy_and_apply_volume_factor_pcm_frames()
  * ma_apply_volume_factor_pcm_frames_u8()
  * ma_apply_volume_factor_pcm_frames_s16()
  * ma_apply_volume_factor_pcm_frames_s24()
  * ma_apply_volume_factor_pcm_frames_s32()
  * ma_apply_volume_factor_pcm_frames_f32()
  * ma_apply_volume_factor_pcm_frames()
  * ma_factor_to_gain_db()
  * ma_gain_db_to_factor()
2019-09-29 13:45:38 +10:00
David Reid b733bf2530 Add support for clipping.
This only applies when the playback sample format is configured as
ma_format_f32. Clipping is enabled by default and can be disabled by
setting ma_device_config.noClip to true.
2019-09-29 10:07:01 +10:00
David Reid 606ee927da Add information on allowable ranges for sample formats. 2019-09-29 08:47:18 +10:00
David Reid 757a4d617d Improvements to pre-init of the output buffer in the data callback.
This commit makes it well defined as to whether or not the output
buffer passed in to the data callback is initialized to zero or left
undefined. By default it's initialized to zero, but can be changed to
undefined by setting noPreZeroedOutputBuffer in the device config.
2019-09-29 08:46:29 +10:00
David Reid 23319083ce No longer maintaining a list of third party decoders. 2019-09-29 07:29:20 +10:00
David Reid f74ff5fd0e Update dr_flac. 2019-09-29 07:23:06 +10:00
David Reid c26544bafd Fix some full duplex issues for asynchronous backends. 2019-09-28 18:41:37 +10:00
David Reid 39edf6d8ff Core Audio: Fix some issues with full duplex. 2019-09-28 17:26:25 +10:00
David Reid 1860292da6 Merge branch 'dev' of https://github.com/dr-soft/miniaudio into dev 2019-09-28 12:37:18 +10:00
David Reid 575009daa0 Core Audio: Fix bugs with automatic stream routing. 2019-09-28 12:21:19 +10:00
David Reid 677f6887fa Typo. 2019-09-28 07:31:37 +10:00
David Reid 6c5119f0b3 Update dr_flac. 2019-09-28 07:23:10 +10:00
David Reid ef1b32a89a Update revision history. 2019-09-19 22:03:52 +10:00
David Reid 3961c3e9e1 WASAPI: Only enable SRC_DEFAULT_QUALITY with AUTOCONVERTPCM. 2019-09-19 21:56:05 +10:00
David Reid d56171d861 WASAPI: Add support for configuring automatic SRC. 2019-09-19 21:24:40 +10:00
David Reid 81a65ce67f WASAPI: Disable auto-SRC when requesting default sample rate. 2019-09-18 17:47:46 +10:00
David Reid 1d04f03a85 WASAPI: Get WASAPI to perform automatic resampling. 2019-09-18 17:39:50 +10:00
David Reid 4ad67a666f Fix potential warnings when compiling with GCC. 2019-09-18 17:35:43 +10:00
David Reid 662246ce0b Update revision history. 2019-09-16 21:04:10 +10:00
David Reid 6ca22eb980 WASAPI: Fix a potential deadlock when starting a full duplex device. 2019-09-16 19:53:24 +10:00
David Reid 363f659351 Add yet more debug output to WASAPI. 2019-09-16 18:42:35 +10:00
David Reid 5645419cf3 Add more debug output for WASAPI. 2019-09-16 18:28:11 +10:00
David Reid ce05e5ed22 Add some debug output to the WASAPI backend. 2019-09-16 18:19:07 +10:00
David Reid bb22d85a71 Add an example for handling fixed sized callbacks. 2019-09-10 19:59:13 +10:00
David Reid c394fde2d9 Add some helper APIs for ring buffers.
* ma_rb_reset()
* ma_rb_available_read()
* ma_rb_available_write()
* ma_pcm_rb_reset()
* ma_pcm_rb_available_read()
* ma_pcm_rb_available_write()
2019-09-10 19:47:39 +10:00
David Reid 345ae4c288 Fix some find and replace errors. 2019-09-08 08:16:43 +10:00
David Reid 54a0d28f71 Update dr_wav. 2019-08-31 10:48:08 +10:00
David Reid a83175378b Update the ma_duplex test. 2019-08-31 10:42:32 +10:00
David Reid cc685b88ca Experimental optimzations to mono/stereo channel conversion. 2019-08-31 08:02:25 +10:00