When launching the game with no audio device available, there is a long (ca. 40 seconds) unresponsive wait with a black screen, before the loading/logo screen appears.
Upon reaching the main menu, the usual and familiar message "could not initialize audio" appears.
In 1.1, when no audio devices are available, the game launches near-instantly to the loading/logo screen regardless, and then shows that message in the main menu. There is no long wait with black screen!
Please fix this.
I am often required to play the game without sound (USB Loudspeakers switched off, USB Headphone Amp switched off, Windows 11 showing "no audio device installed" in taskbar).
[Donion] [2.0.11] Long black screen wait before loading screen when no audio device available
[Donion] [2.0.11] Long black screen wait before loading screen when no audio device available
Last edited by Usul on Sun Nov 03, 2024 9:25 pm, edited 1 time in total.
Re: [2.0.11] Long black screen wait before loading screen when no audio device available
I saw this as well and reported it during the beta. The logfile shows a series of five "Failed to open audio device X. Retrying with default audio device". Which makes no sense because it was the default device that failed the last four times too.
My mods: Multiple Unit Train Control, Smart Artillery Wagons
Maintainer of Vehicle Wagon 2, Cargo Ships, Honk
Maintainer of Vehicle Wagon 2, Cargo Ships, Honk
-
- Burner Inserter
- Posts: 5
- Joined: Sun Oct 27, 2024 3:00 am
- Contact:
Re: [2.0.11] Long black screen wait before loading screen when no audio device available
I'd like to note that I alt-tabbed to change audio device in bottom right with windows 10 and crashed my factorio. Possibly unrelated, but worth mentioning, imo.
Re: [2.0.11] Long black screen wait before loading screen when no audio device available
Looking at the logic - the issue is coming from SDL's audio system specifically I found this part:
Which suggests to me that it's working as intended however the intent is that - you have an audio device installed - and if you don't, you get to wait for this crazy timeout. I don't have a nice answer for that. You could always pass --disable-audio which will skip all of this logic and just start with audio disabled.
Code: Select all
const Uint64 timeout = SDL_GetTicks64() + 8000; /* intel's audio drivers can fail for up to EIGHT SECONDS after a device is connected or we wake from sleep. */
If you want to get ahold of me I'm almost always on Discord.
Re: [2.0.11] Long black screen wait before loading screen when no audio device available
Thanks but nah, I will not use a start parameter to bypass a 40 second wait, that simply was non-existant before 2.0. To accept this as intended behaviour and a workaround instead of a fix is sadly a step backwards.Rseding91 wrote: ↑Sun Nov 03, 2024 12:52 pmLooking at the logic - the issue is coming from SDL's audio system specifically I found this part:
Which suggests to me that it's working as intended however the intent is that - you have an audio device installed - and if you don't, you get to wait for this crazy timeout. I don't have a nice answer for that. You could always pass --disable-audio which will skip all of this logic and just start with audio disabled.Code: Select all
const Uint64 timeout = SDL_GetTicks64() + 8000; /* intel's audio drivers can fail for up to EIGHT SECONDS after a device is connected or we wake from sleep. */
Re: [Donion] [2.0.11] Long black screen wait before loading screen when no audio device available
Thanks for the report, the issue is fixed for the next release, 2.0.15.
When there is no audio device found, the game will no longer try to initialize one anyway.
When there is no audio device found, the game will no longer try to initialize one anyway.