Delay w/ new AudioTap API when system device is a BL device

I'm capturing audio from other applications on macOS to mix them with other sources in a real time streaming application.

I noticed that audio data captured via the new tapping mechanism introduced in macOS 14.2 arrives delayed in my app, when the macOS system device is a Bluetooth headphone, e.g. Apple AirPods.

Sometimes this delay is about 300-400 milliseconds, which makes it unusable for live streaming, because the audio is out of sync with the video and also audio captured from other devices.

What is confusing to me, is that this also happens when my app does not even use that output device.

Is this a known issue? Is there a way around this?

Hello @iljawascoding, thank you for your post.

What is confusing to me, is that this also happens when my app does not even use that output device.

Are you including the Bluetooth device in the same aggregate device as your tap? If so, it would be expected for the tap's latency to increase.

Delay w/ new AudioTap API when system device is a BL device
 
 
Q