Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

100% CPU usage and game crash on exit due to SDL sound frequency #3294

Closed
DorpsGek opened this issue Nov 2, 2009 · 3 comments
Closed

100% CPU usage and game crash on exit due to SDL sound frequency #3294

DorpsGek opened this issue Nov 2, 2009 · 3 comments
Labels
flyspray This issue is imported from FlySpray (https://bugs.openttd.org/)

Comments

@DorpsGek
Copy link
Member

DorpsGek commented Nov 2, 2009

Jafinto opened the ticket and wrote:

When I run any build > 17140 the game uses 100% of my CPU, while it otherwise hovers around the 12%. When I try to close the game, it hangs. Sounds do not play normally.

I can fix this by setting the SDL frequency to 11025 (I'm using the standard sounds).

My system:
Ubuntu 9.10 Karmic Koala
AMD Phenom II X4 810 Processor
4 GB RAM
AMD Radeon HD 3300 (integrated)
Creative X-Fi Platinum

Attachments

Reported version: trunk
Operating system: Linux


This issue was imported from FlySpray: https://bugs.openttd.org/task/3294
@DorpsGek
Copy link
Member Author

DorpsGek commented Nov 3, 2009

SmatZ wrote:

From known-bugs.txt:

Extreme CPU usage when using SDL and PulseAudio
OpenTTD can be extremely slow/use a lot of CPU when the sound is
played via SDL and then through PulseAudio's ALSA wrapper. This setup
seems to be the default configuration for Ubuntu 9.04 and later. This
issue can be solved by installing the 'libsdl1.2debian-pulseaudio'
package from Ubuntu's Universe repository.

(yes, I know it's not fair as this was added to known-bugs.txt today)

Does that help?


This comment was imported from FlySpray: https://bugs.openttd.org/task/3294#comment6901

@DorpsGek
Copy link
Member Author

DorpsGek commented Nov 3, 2009

Jafinto wrote:

It does fix the high CPU load and the crash on exit, but the sound quality is noticeably worse.

Anyway, thanks for workaround. I think I'll just keep the frequency on 11025 for now, until the new sound set will be ready.


This comment was imported from FlySpray: https://bugs.openttd.org/task/3294#comment6902

@DorpsGek
Copy link
Member Author

DorpsGek commented Nov 3, 2009

Rubidium closed the ticket.

Reason for closing: Bug in external library

libSDL->SDL-ALSA backend->PulseAudio virtual ALSA device->PulseAudio causes the problem. Switch to either the SDL-PulseAudio backend or remove PulseAudio.


This comment was imported from FlySpray: https://bugs.openttd.org/task/3294

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
flyspray This issue is imported from FlySpray (https://bugs.openttd.org/)
Projects
None yet
Development

No branches or pull requests

1 participant