PDA

View Full Version : Sound is too fast. Zelda Classic Debian Wheezy



aaronvaldes
02-05-2013, 02:02 PM
I am testig out the latest release.
The sound sounds way too fast.
Can someone help?

I love this game.

Chris Miller
02-05-2013, 05:32 PM
Do you use ALSA or PulseAudio?

aaronvaldes
02-05-2013, 11:56 PM
PulseAudio

I installed ALSA drivers.

I have tried with both and no difference.

How can I make sure that Zelda Classic is using correct driver?

Which is correct? ALSA or Pulseaudio

Perhaps I need to configure Allegro to use the correct driver?

Chris Miller
02-06-2013, 12:53 PM
Well, I looked into it. The only thing I can think of, is use OSS.
Here's (https://bbs.archlinux.org/viewtopic.php?id=77727) the thread I found. It's for Arch, but the principle's the same.

aaronvaldes
02-06-2013, 01:45 PM
I don't understand.
I tried it in full screen and it speeds up the sound.
Changing resolution and it fixes it and then it happens again.
Not stable at all.
Why would changing resolution have anything to do with sound?

Chris Miller
02-06-2013, 03:09 PM
I'll try and do some more digging, but I do have a theory. ZC is most likely running at a very high priority, same as it does in Windows 7(strangely, XP escapes this problem). That can cause some weird stuff, and maybe even interfere with your sound. It's kind of hit-or-miss, mostly depending on what kind of hardware your system has. You might try running ZC, then switching back to the desktop while it's still running. Then open your task manager and see if you can set the priority to normal.

aaronvaldes
02-06-2013, 04:31 PM
I checked and PulseAudio and Zelda are definatley running.

There nice values seem normal.

I tried turning them down to -20 for lowest priority and still no change.

aaronvaldes
02-06-2013, 04:33 PM
I checked TOP

pulse audio is at about 1.4 percent CPU usage when working ok.

When it is not ok pulse audio is at 20 percent cpu usage?

What would cause pulse audio to think it had to do so much work?


Just Tested:

I was playing and then when I picked up a fairy, Pulseaudio went to 20 percent and sound went super fast again.

aaronvaldes
02-07-2013, 12:09 AM
./zelda-l -v0

I ran zelda with the v sync off.
And now it seems that the fast speed is matching the speed of the game.
Totally not playable.

Gleeok
02-07-2013, 12:18 AM
I'm not familiar with the linux builds but I believe Saffith was working on a similar issue a while back. Hopefully he can shed some light on this for you.

aaronvaldes
02-07-2013, 02:09 AM
Its like the sound keeps stopping then starting rapidly.
The counter on Pulseaudio manager keeps climbing.
This should remain the same while the sound card is being used.
Any idea why this is counter is rapidly climbing...
I can see this clearly in the pulseaudio manager.

Chris Miller
02-07-2013, 03:15 PM
I just had another idea. Try increasing the size of the buffer in the sound options.

aaronvaldes
02-07-2013, 04:11 PM
I just had another idea. Try increasing the size of the buffer in the sound options.

Tried it already, still happening.

Saffith
02-07-2013, 06:54 PM
Yeah, I was looking at this before, but I could never figure out for sure what the problem was. I could never reproduce it reliably enough, and it would always go away on its own pretty quickly. That doesn't seem to be the case for everyone, unfortunately.
I think playing with the framerate cap (hold ~ or press F1) made it stop faster, but I'm not too sure about that.

You could try changing the sound driver Allegro uses. In the [sound] section of ag.cfg:

digi_card=XXXX
Valid settings should be ALSA, OSSD, ESDD, JACK, ARTS, and SGIA.

There are also several settings specifically for ALSA. Those are all listed here: https://www.allegro.cc/manual/4/api/configuration-routines/
I haven't messed with them much, but perhaps one of those would help.

aaronvaldes
02-07-2013, 08:35 PM
Depending on how the game is launched.
The ag.cfg file is updated evertime.

Saffith
02-08-2013, 12:16 AM
It'll save settings you add, though, as long as you do it when the game isn't already running.

aaronvaldes
02-08-2013, 08:37 AM
It'll save settings you add, though, as long as you do it when the game isn't already running.

Another strange problem.
When using the zlaunch seems to work ok.
I play the game and sound is ok, then something triggers it to play the sound wrong.
It so frustrating.


I also see this error.
Is this related?

ALSA lib rawmidi_hw.c:233:(snd_rawmidi_hw_open) open /dev/snd/midiC0D0 failed: No such file or directory

aaronvaldes
02-08-2013, 08:52 AM
Another strange problem.
When using the zlaunch seems to work ok.
I play the game and sound is ok, then something triggers it to play the sound wrong.
It so frustrating.


I also see this error.
Is this related?

ALSA lib rawmidi_hw.c:233:(snd_rawmidi_hw_open) open /dev/snd/midiC0D0 failed: No such file or directory

I tried fixing with this...


[sound]
alsa_rawmidi_device = hw:2,0


error message went away but same thing is happening

Saffith
02-08-2013, 02:25 PM
You've got PulseAudio fully updated, right? Should be version 2.0-6. I haven't seen this happen once since my latest OS install, which uses that version. Might just be coincidence, but it's worth checking.

I'm pretty sure this started happening around the time PA 1.0 came out. I don't know for sure that any change in PA was responsible, but it seems reasonably likely.

aaronvaldes
02-09-2013, 12:39 AM
You've got PulseAudio fully updated, right? Should be version 2.0-6. I haven't seen this happen once since my latest OS install, which uses that version. Might just be coincidence, but it's worth checking.

I'm pretty sure this started happening around the time PA 1.0 came out. I don't know for sure that any change in PA was responsible, but it seems reasonably likely.

dpkg -l | grep pulseaudio
ii gstreamer0.10-pulseaudio:i386 0.10.31-3+nmu1 i386 GStreamer plugin for PulseAudio
ii liquidsoap-plugin-pulseaudio 1.0.1+repack1-1.1 i386 audio streaming language -- Pulseaudio plugin
ii projectm-pulseaudio 2.1.0+dfsg-1 i386 projectM PulseAudio module
ii pulseaudio 2.0-6 i386 PulseAudio sound server
ii pulseaudio-dbg 2.0-6 i386 PulseAudio sound server (debugging symbols)
ii pulseaudio-esound-compat 2.0-6 i386 PulseAudio ESD compatibility layer
ii pulseaudio-esound-compat-dbg 2.0-6 i386 PulseAudio ESD compatibility layer (debugging symbols)
ii pulseaudio-module-bluetooth 2.0-6 i386 Bluetooth module for PulseAudio sound server
ii pulseaudio-module-bluetooth-dbg 2.0-6 i386 Bluetooth module for PulseAudio sound server (debugging symbols)
ii pulseaudio-module-gconf 2.0-6 i386 GConf module for PulseAudio sound server
ii pulseaudio-module-gconf-dbg 2.0-6 i386 GConf module for PulseAudio sound server (debugging symbols)
ii pulseaudio-module-jack 2.0-6 i386 jackd modules for PulseAudio sound server
ii pulseaudio-module-jack-dbg 2.0-6 i386 jackd modules for PulseAudio sound server (debugging symbols)
ii pulseaudio-module-lirc 2.0-6 i386 lirc module for PulseAudio sound server
ii pulseaudio-module-lirc-dbg 2.0-6 i386 lirc module for PulseAudio sound server (debugging symbols)
ii pulseaudio-module-raop 2.0-6 i386 RAOP module for PulseAudio sound server
ii pulseaudio-module-raop-dbg 2.0-6 i386 RAOP module for PulseAudio sound server (debugging symbols)
ii pulseaudio-module-x11 2.0-6 i386 X11 module for PulseAudio sound server
ii pulseaudio-module-x11-dbg 2.0-6 i386 X11 module for PulseAudio sound server (debugging symbols)
ii pulseaudio-module-zeroconf 2.0-6 i386 Zeroconf module for PulseAudio sound server
ii pulseaudio-module-zeroconf-dbg 2.0-6 i386 Zeroconf module for PulseAudio sound server (debugging symbols)
ii pulseaudio-utils 2.0-6 i386 Command line tools for the PulseAudio sound server
ii pulseaudio-utils-dbg 2.0-6 i386 PulseAudio command line tools (debugging symbols)

aaronvaldes
02-09-2013, 01:38 PM
I think I got it to work.

I used the Pulse Audio manager and specifically set my soundcard to output ANALOG MONO OUTPUT.

I have been able to launch Zelda in full screen mode and toggle between modes and it working fine.

This is interesting.

Is there somthing we should note about how soundcards output the sound in Linux.

I am using Debian Wheezy Linux.

It does speed up a few time but recover.
I was able to play Zelda and pass the first 7 Levels without the sound speeding up.

Hopefully this will shed some light on getting Zelda working for all linux users.