David Reid
67389d29ec
Remove an unnecessary COM initialization routine.
2026-01-03 11:20:10 +10:00
David Reid
c314eb0fa5
Add a new errored status.
...
This allows a backend to put the device into an errored state to
indicate that it is no longer usable and needs to be reinitialized.
2026-01-03 11:01:46 +10:00
David Reid
c64a5c7457
A rule change for stop notifications.
2026-01-03 07:16:26 +10:00
David Reid
e81a11e725
DirectSound: Stop logging an error when stopping.
...
This would result in an error being logged when a capture device is
unplugged.
2026-01-03 07:16:09 +10:00
David Reid
3b2af39864
DirectSound: Fix an error when stopping the device.
...
If the capture side fails to stop it would result in the function
returning early thereby not giving the playback side a chance to also
stop which would result in a looping glitch.
2026-01-03 06:42:57 +10:00
David Reid
d0392288c4
Remove an old device job thread object.
...
This was used by AAudio for dealing with rerouting, but with the new
backend architecture it is no longer needed.
2026-01-01 19:04:49 +10:00
David Reid
a5ef023cee
Remove some global variables.
...
These are replaced by functions. The problem is that declaring a
variable as MA_API will result in errors when it's declared as static.
2026-01-01 18:39:43 +10:00
David Reid
db6bc371eb
WebAudio: Remove dependency on -sASYNCIFY for the Audio Worklets path.
...
Public issue https://github.com/mackron/miniaudio/issues/863
2026-01-01 13:10:15 +10:00
David Reid
1f2e59548b
Web Audio: Minor change for multi-threaded mode.
2026-01-01 10:47:39 +10:00
David Reid
1d0a598485
Rename MA_THREADING_MODE_MULTITHREADED.
...
This not having an underscore while SINGLE_THREADED did was driving me
crazy.
2026-01-01 09:19:43 +10:00
David Reid
e086de4eb3
Web Audio: Get single-threaded mode working to spec.
2025-12-30 14:54:36 +10:00
David Reid
07af5ea6f7
Remove an unnecessary function.
...
The naming of this function is now a bit misleading with the new changes
to the backend system.
2025-12-30 10:32:09 +10:00
David Reid
d04c1985d6
Fix an error with the Web Audio backend.
2025-12-30 10:13:44 +10:00
David Reid
350cc0be1f
Fix a bug with starting and stopping a device in single-threaded mode.
2025-12-30 09:25:37 +10:00
David Reid
7483e55aee
Add ma_device_get_threading_mode().
2025-12-29 19:39:29 +10:00
David Reid
0f4bc3ca9a
Add support for configuring the threading mode for a device.
2025-12-29 19:12:34 +10:00
David Reid
b0894c34b1
Add ma_device_step() in preparation for single-threaded mode.
2025-12-29 19:02:18 +10:00
David Reid
fa2c1b49b3
Remove unused callbacks from the device backend system.
2025-12-29 18:02:51 +10:00
David Reid
3d79043d7d
WASAPI: Move thread characteristic stuff from start/stop to init/uninit.
...
All audio functions now run from the same thread, so this feels like a
more appropriate location for these functions to me.
2025-12-29 15:43:27 +10:00
David Reid
9df9b19a59
WASAPI: Refactoring of the device rerouting system.
...
This now performs rerouting from the step callback which is always done
from the main thread. This should address issues relating to COM
initialization and some rerouting race conditions.
There is a very slight change in behaviour here. Previously when a
device is detached (such as headphones being unplugged), the device
would actually be stopped proper, but now it is no longer stopped and
the stop notification is not fired when the device is deactivated.
2025-12-29 15:32:23 +10:00
David Reid
d72811c127
WASAPI: Remove some unnecessary variables.
2025-12-29 10:35:00 +10:00
David Reid
aaf868f92a
WASAPI: Refactoring for the new backend architecture.
2025-12-29 10:31:25 +10:00
David Reid
d0b8b07c49
DirectSound: Refactoring for the new backend architecture.
2025-12-28 19:55:59 +10:00
David Reid
a4406088f4
WinMM: Refactoring for the new backend architecture.
2025-12-28 11:07:55 +10:00
David Reid
c6d44b67e1
PulseAudio: Stop firing the stop callback in response to a suspension.
2025-12-26 19:26:43 +10:00
David Reid
521c224b02
JACK: Stop double-posting the stop callback.
2025-12-26 19:16:55 +10:00
David Reid
5d1c089d15
OpenSL: Stop double-posting the stop callback.
2025-12-26 19:16:43 +10:00
David Reid
f270f515e4
AAudio: Stop double-posting the stop callback.
2025-12-26 19:15:03 +10:00
David Reid
d10526fb3a
Core Audio: Stop double-posting stop callbacks.
2025-12-26 19:04:10 +10:00
David Reid
ef59b93a4d
Fix a bug with asynchronous style backends.
...
This was resulting in glitching in duplex mode when internal sample
rates differ.
2025-12-26 18:36:11 +10:00
David Reid
f932077982
Core Audio: Refactoring for the new backend architecture.
2025-12-26 12:02:57 +10:00
David Reid
5296384289
ALSA: Fix an error with non-blocking mode.
2025-12-25 11:29:10 +10:00
David Reid
4cb0851ccc
sndio: Refactoring for the new backend architecture.
2025-12-25 11:28:14 +10:00
David Reid
7cb349fc60
audio(4): Refactoring for the new backend architecture.
2025-12-24 19:16:39 +10:00
David Reid
8c735da4eb
OSS: Refactoring for the new backend architecture.
2025-12-24 17:43:20 +10:00
David Reid
a2c7e697d1
ALSA: Refactoring for the new backend architecture.
2025-12-24 14:35:06 +10:00
David Reid
61fd14955a
PulseAudio: Minor restructure in preparation for the new backend system.
2025-12-24 06:31:40 +10:00
David Reid
5eafc0e9c1
Merge branch 'dev' into dev-0.12
2025-12-23 19:07:52 +10:00
David Reid
364844231d
Fix an bug with error recovery when failing to initialize a decoder.
...
Public issue https://github.com/mackron/miniaudio/issues/1080
2025-12-23 19:04:53 +10:00
David Reid
631bc047d8
Minor C89 compatibility fix.
2025-12-23 14:47:48 +10:00
David Reid
bd35758b87
AAudio: Try fixing a glitch when starting a device.
...
This is only happening when the device is started after being stopped.
The initial start does not glitch.
2025-12-23 13:08:39 +10:00
David Reid
737fb79aae
AAudio: Simplify device rerouting.
...
This now does rerouting in the step which runs on the audio thread,
which is the same thread that init, uininit, start and stop runs on, and
no longer goes through the job system.
2025-12-23 10:17:38 +10:00
David Reid
fd6ee4711b
Generalize some backend stepping logic for the new backend architecture.
2025-12-22 17:10:03 +10:00
David Reid
e6922b360c
Minor refactor the AAudio backend.
2025-12-22 13:41:37 +10:00
David Reid
1bb2180005
Minor refactor the OpenSL backend.
2025-12-22 11:50:53 +10:00
David Reid
e598eb7fe6
Minor refactor to the null backend.
2025-12-22 11:50:44 +10:00
David Reid
ad7084c9ef
SDL2: Add wakeup callback.
2025-12-20 18:21:31 +10:00
David Reid
d6487d0569
Make ma_blocking_mode public in preparation for some changes.
2025-12-17 07:34:51 +10:00
David Reid
6931d7d159
Cleanup.
2025-12-17 07:34:31 +10:00
David Reid
38a543caa4
Try fixing some glitching with the AAudio backend.
2025-12-17 06:46:50 +10:00