Tux Guitar

Open Discussion

Subject The "pulseaudio + timidity" problem   Post Reply Post New Topic



Author Message
gnumm
Post: Aug 8th 2008 at 8:48 AM   Post Reply

Hi,

I noticed that playing tuxguitar files with timidity causes some problems with pulseaudio. For example, playing tuxguitar files with timidity and watching a youtube clip at the same time is not really possible, either the youtube clip or timidity will be muted. I guess I also had this problem when I played tuxguitar files with timidity and listened to music with rhythmbox.
Now I use kde and have not any problem. (pulseaudio comes with gnome)

I wanted to ask if you have the same problem and if you found a possibility to solve that annoying problem? Or did you find a possibility to completely remove pulseaudio? (I tried to replace pulseaudio with esd but it didn't work for me, maybe I did something wrong.)

Or are there plans for the future?


Back to Top
 
Johnny
Post: Aug 8th 2008 at 12:17 PM   Post Reply

This is not a TuxGuitar problem actually.

But one thing occures to me. Try changing sequencer to "TuxGuitar sequencer" (default is "Real Time Seq."), because it uses OSS which your PulseAudio might be using.

Works for me to resolve OSS conflict.


Back to Top
 
gnumm
Post: Aug 8th 2008 at 12:48 PM   Post Reply

I know it's not a tuxguitar problem, it's a problem of a wrong configured pulseaudio. But I often read in this forum that people have the same problem.

I finally found a workaround for this problem. In fact, you just have to configure pulseaudio, that ALSA uses it. :)
This tutorial is for ubuntu, but it should work on other distributions, maybe the names of the packages are different.

For all of you having similar problems, do this:

Install timidity from your repository and tuxguitar(e.g. the ubuntu package from this website, or from your repository)

go to this website: http://www.pulseaudio.org/wiki/PerfectSetup

1. Scroll down to "Alsa Applications"

Create a ~/.asoundrc with

pcm.!default {
type pulse
}
ctl.!default {
type pulse
}

save it and close it.

2. Scroll down to "libao Applications"
Do what they say.
But install libao-pulse from your repository.

3. Now install the package "libasound2-plugins"

4. Run timidity -iA -Os, it should open some ports 129. In tuxguitar, go to tools>settings>sound and choose TiMidity port 1 [129:1]

The sound should now go trough pulseaudio.


Back to Top
 
gnumm
Post: Aug 8th 2008 at 1:02 PM   Post Reply

I forgot:

In gnome, go to System>Preferences>Sessions and add this:

Name: Timidity
Command: timidity -iA -Os


Back to Top
 
Julian
Post: Aug 8th 2008 at 3:09 PM   Post Reply

gnumm, yes i know there are some problems with pulseaudio and midi (not only timidity).
unfortunatly, i couldn't reproduce the timidity problem.
well yes, but restarting timidity problem was solved (not for other users)
yes i could confirm fluidsynth don't work if pulseaudio is running.

I'm not really sure what pulse audio is for, and why it was included on some distributions so early.

The only fix i know, is disable pulseaudio, and back to alsa as allways.
i think pulseaudio developers know about this, and will solve the problem.

> timidity -iA -Os
it don't should be needed on debian based distributions.
timidity deb package, has an init script on:
/etc/init.d/timidity

you can exec:
/etc/init.d/timidity start
/etc/init.d/timidity stop

start is executed when system startup.
but again, pulseaudio problem causes timidity don't start fine.

when you run "timidity -iA -Os"
you are running a new instance of timidity (while there is another running) that's why it open port 129

Take a look to: aconnect -o
or look for a PID process: ps ax | grep timidity

you'll see the startup process is still running.

So you should to restart it, instead of start a new instance:
/etc/init.d/timidity restart

Or:
killall -9 timidity
timidity -iA -Os


Back to Top
 
gnumm
Post: Aug 8th 2008 at 3:24 PM   Post Reply

Thanks, good to know that.


Back to Top
 

Post Reply