Commit Graph

627 Commits

Author SHA1 Message Date
David Reid a6d777f149 audioio: Fix a bug where the buffer size is set incorrectly. 2018-08-06 12:20:58 +00:00
David Reid 931d669ff9 Add support for setting the device's buffer size in milliseconds.
Setting the buffer size in frames is still supported. If
bufferSizeInFrames is set to 0, bufferSizeInMilliseconds will be used
instead. If both are zero, defaults are used.
2018-08-11 11:06:49 +10:00
David Reid d4916abdc9 Remove the experimental profiling based default buffer sizes.
The problem with this idea is that it complicates the buffer size
calculations in the backends. It also results in situations where
the buffer size is inconsistent which is annoying.

Future commits will be adding support for specifying the size of the
buffer in milliseconds which should offer more flexibility.
2018-08-11 08:56:59 +10:00
David Reid 176d5a3cc6 Add MAL_COINIT_VALUE. 2018-08-09 18:56:00 +10:00
David Reid f894b83e97 Fix a sinc resampling bug where too much data is read from the client. 2018-08-08 21:39:25 +10:00
David Reid 6e606e073f Bump version. 2018-08-06 22:07:26 +10:00
David Reid 22eee7160b Minor tweaks to sndio. 2018-07-30 07:14:14 +10:00
David Reid d0b8588b55 sndio: Clean up and restrict device enumeration to default devices. 2018-07-30 14:17:01 +10:00
David Reid 2b167eb199 audioio: Fix unnecessarily inefficient device enumeration. 2018-08-06 09:49:48 +00:00
David Reid af3f01ca6f sndio: Fix unnecessarily inefficient device enumeration. 2018-07-30 12:09:07 +10:00
David Reid 9690e3bb9e Update revision history. 2018-08-05 19:08:31 +10:00
David Reid 07410da499 Redefine formats to be native-endian instead of little-endian. 2018-08-05 18:16:51 +10:00
David Reid a0668a89cd Clean up to the sndio backend. 2018-07-30 03:00:24 +10:00
David Reid 4da8834ae4 Refactor the main loop. 2018-08-05 15:08:47 +10:00
David Reid 1a6a47af41 WASAPI: Try fixing a glitching bug with capture. 2018-08-05 14:11:46 +10:00
David Reid 28002a1ddc Prioritize s16 over f32 since it is better supported by hardware. 2018-08-05 12:30:36 +10:00
David Reid b213f5e05d sndio: Add some notes for future reference. 2018-07-30 03:07:38 +10:00
David Reid 68997e3b76 Restrict sndio to OpenBSD and update revision history. 2018-07-30 02:31:41 +10:00
David Reid 28d7086c24 Try fixing a few issues with sndio. 2018-07-29 22:00:00 +10:00
David Reid 15c6e48b4f Clean up to the sndio backend. 2018-07-30 01:49:16 +10:00
David Reid 4a7983680f sndio: Add support for runtime linking. 2018-07-29 21:07:13 +10:00
David Reid 7057f845c6 Initial work on sndio backend. 2018-07-29 23:15:04 +10:00
David Reid ab6c1b353c Update documentation. 2018-07-29 14:45:41 +10:00
David Reid 498f2610bb Disable the audioio backend on OpenBSD. 2018-07-28 14:29:29 +10:00
David Reid df0f5081b3 audioio: Whitespace and clean up. 2018-07-28 17:59:19 +00:00
David Reid 37c732b645 audioio: Clean up. 2018-07-28 16:01:01 +00:00
David Reid 7f18932c85 audioio: Clean up. 2018-07-28 15:36:31 +00:00
David Reid bbdd3f47f2 Get playback working with audioio. 2018-07-28 15:00:53 +00:00
David Reid 13675cc121 Work on the audioio backend. 2018-07-28 11:42:37 +00:00
David Reid b0a8df7f5c Add some infrastructure for audioio. 2018-07-28 09:33:18 +10:00
David Reid 049f46738b Fix some issues with CPUID. 2018-07-25 18:32:13 +10:00
David Reid e1d02f7640 Increase the default sinc window width for resampling. 2018-07-21 20:21:27 +10:00
David Reid 7a304dc599 Rearrange some stuff. 2018-07-18 22:20:38 +10:00
David Reid 48ecee6278 Add MAL_NO_DEVICE_IO option.
This option disables device playback and capture. This is useful if you
only need mini_al's decoding and/or decoding APIs.
2018-07-17 21:16:30 +10:00
David Reid 3f47df20ea Add support for detailed control over data conversion when decoding. 2018-07-17 20:45:12 +10:00
David Reid 0d6bcd1f48 Deprecate some APIs and add mal_src/dsp_set_sample_rate().
When dynamically adjusting the sample rate you must now set both the
input and output sample rates at the same time. This is required for
future support for specifying a ratio instead of in/out rates.
2018-07-17 20:18:57 +10:00
David Reid 2dc3776497 Merge branch 'callbacks' into dev 2018-07-16 19:22:23 +10:00
Clownacy 16438195f1 Stop warning about uninitialised variable
For some reason, the warning only appears for me if I set MAL_NO_OPENAL
and compile with -O3.
2018-07-15 15:00:17 +01:00
David Reid bf02f2774a Minor typo. 2018-07-15 22:23:06 +10:00
David Reid 205c3b0eb7 Integrate the new callback system. 2018-07-15 22:16:02 +10:00
David Reid 1bf3ab8b9c Setup callbacks for the ALSA backend. 2018-07-15 21:56:22 +10:00
David Reid 4543c724df Setup callbacks for the PulseAudio backend. 2018-07-15 21:53:32 +10:00
David Reid d54116fcc3 Setup callbacks for the OSS backend. 2018-07-15 21:32:04 +10:00
David Reid e04d4e61b6 Setup callbacks for the DirectSound backend. 2018-07-15 21:28:39 +10:00
David Reid e06aa2aaf8 Setup callbacks for the WinMM backend. 2018-07-15 21:26:19 +10:00
David Reid 6b3a8db3bf Setup callbacks for the OpenAL backend. 2018-07-15 21:23:44 +10:00
David Reid a063e379c0 Setup callbacks for the NULL backend. 2018-07-15 21:21:23 +10:00
David Reid c72a79f25c Clean up for asynchronous backends. 2018-07-15 21:18:10 +10:00
David Reid 73af94d28e Const correctness. 2018-07-15 21:14:18 +10:00
David Reid 051808d512 Start using the new callback system with the Core Audio backend. 2018-07-15 21:02:54 +10:00