TeamRizu / OutFox

The Bug Reporting Repository for OutFox LTS 0.4, Alpha V and Steam Early Access Builds
https://projectoutfox.com
Apache License 2.0
178 stars 3 forks source link

[BUG] Raspberry Pi LTS armv8 no sound when autostart or when TV wakes up #714

Open funjup opened 6 months ago

funjup commented 6 months ago

Is there an existing issue for this?

Operating System

Raspberry Pi 4/5 OS Debian 12

CPU

aarch64

GPU

No response

Storage

4Gb

Game Version

4.19.1

Game Mode

dance

Theme

Fresh install of the latest RPi4 OS with Debian 12.1, and fresh install of OutFox 0.4.19. Default theme. No changes. Connected to TV with HDMI cable for video and audio. No additional sound devices. Outfox starts into a regular window instead of full screen.

Describe the problem

Maybe this type of sound issue is fixed with all the 0.5 upgrades. However since 0.5+ doesn't yet have a build for arm chips, RPi users are stuck with 0.4.19 LTS. So please either get us a working 0.5+, or fix the below issue with 0.42. Thank you for all the time you've already put into this project, we really appreciate it!

Here's the scenario: Created the OutFox.desktop shortcut on the Desktop, which loads Outfox with double-click and everything works fine. However to have Outfox autostart when machine boots up, I've copied the OutFox.desktop shortcut to /etc/xdg/autostart/ (or can copy to /home/pi/.config/autostart/). During bootup, the game autostarts an instance, but no sound on title screen, or wheel, nor inside a song which doesn't start playing or scrolling notes. Happens every time with autostart.

Trying to kick the autostart version to have sound, I've tried to then double-click the desktop shortcut, which creates a second instance with sound, yet the first will still be quiet. I can also start playing an .mp3 and sound works. Since autostart never has sound, I've since removed the command and manually start after machine boot. Which is ok for home use, however I'm creating an arcade machine for the public, so need it to boot with sound when powered on.

I've also found the exact behavior of loosing sound when I turn my TV off but let a working Outfox instance keep playing, then after about 10 minutes turn TV back on, Outfox is still exactly where it was but the sound is lost and can't be recovered. I suspect with this issue, either the TV or Pi is telling the other to turn off and save power, which resets what sound driver to use or something similar.

When I compare the logs of the autostart instance, to the working double-clicked instance, they are practically identical. Even the part of ALSA being busy so not loading, and PulseAudio taking over. So it seems that PulseAudio is the driver on the working instance also. I have not tried to force sound through the jack or another device cause I want to use the TV sound. If no solution is on the horizon, I'm hoping that an autostart program that delays 10 seconds then runs OutFox will create an instance with sound.

Describe what should happen

Outfox autostarts when machine boots up, and have working sound and song files. Not loose sound if TV is turned off for 10 minutes.

Relevant Log output

ProjectOutfox.Crash.2023-12-19--04.00.35.log ProjectOutfox-default.ThemeLua.2023-12-19--04.00.37.log ProjectOutfox.MainLog.2023-12-19--04.00.35.log