0 votes

How would I go about using ASIO audio drivers with Godot? For example using ASIO4ALL with Godot? I tried setting the audio driver in Project Settings > Audio > Driver to ASIO from the default WASAPI but this does not work. For some reason the AudioServer will only list the WASAPI devices and no ASIO devices. Do I have to provide the specific ASIO driver name?

I'm working on a rhythm style game and would like to see if using a lower latency ASIO driver would help.

Godot version 3.4.2
in Engine by (21 points)

1 Answer

0 votes

Godot only supports WASAPI for audio output on Windows, not ASIO. Regardless of this, keep in mind Godot currently can't schedule audio events to be played at an absolute time.

I'm working on a rhythm style game and would like to see if using a lower latency ASIO driver would help.

In Godot 4.0, the Output Latency project setting will affect WASAPI – this hasn't been backported to Godot 3.x yet.

by (11,901 points)

Thank you for the clarification. I understand Godot currently can not schedule real time audio events through it's API as I've struggled with this for way to long now. However I am very close to real time after many days of research and work.

I'm currently using a Windows Multimedia Timer as a clock source. It's so far accurate to ~1ms. For each sound sample I am using AudioStreamGenerator as this is a bit faster than AudioStreamPlayer.Play(). Each sound is processed in it's own thread with a AudioStreamGenerator for each. This is the best I've comes up with so far. Playing a standard 4 on the floor drum beat sounds great but every once in a while it will trigger to late or too early and so I'm trying to eliminate as many things that can cause latency.

I've been waiting for version 4.0 for year(s) now lol. I hope the output latency setting gets back ported as this would help a lot.

Edit: So it does look like it was back ported some time ago. I might have a look and compile Godot myself with the change.

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to webmaster@godotengine.org with your username.