To put to rest the notion that this is "not a direct sound issue".
Microsoft reports 48ms round trip latency (around 30ms for output) in their documentation
https://docs.microsoft.com/en-us/windows-hardware/drivers/audio/low-latency-audio
I was able to achieve ~30ms latency by capturing on the driver output directly in an ESXI VM. However, Microsoft also defaults to a 10ms hardware buffer. This will realistically put audio latency at around 40ms under *ideal* circumstances, which is terrible. Considering CoreAudio, ALSA, ASIO, etc... can all reasonably achieve <5ms.
Here are some measurements of actual latencies (internal timers, does not include kb latency):
Realtek ALC1220 DirectSound -
42 ms
Realtek ALC1220 DirectSound + REAL -
34 ms
Realtek ALC1220 WASAPI -
25 ms
Realtek ALC1220 CoreAudio 32 sample buffer -
3 ms
Cirrus CS42L83A DirectSound -
38 ms
Cirrus CS42L83A DirectSound + REAL -
31 ms
Cirrus CS42L83A WASAPI -
24 ms
Cirrus CS42L83A CoreAudio 32 sample buffer -
3 ms
Note: The hardware buffer can be reduced using REAL
https://github.com/miniant-git/REAL
The 70-80 ms latencies people are reporting are likely not due to directsound alone, though in any case, directsound is a significant contribution. Directsound has not had a direct interface to the driver since windows XP. It was deprecated in Windows Vista and has since ran as an emulated device in WASAPI. There should be reason to use directsound other than that the code for it already exists (and I entirely understand not wanting to change a "mostly working" system).