You are not logged in.

#1 2011-03-14 19:48:48

heptapod
Member
Registered: 2010-06-24
Posts: 35

Flash audio to jack

I would like to send all audio through jack (Because I need jack for music apps, and jack takes over the whole soundcard). For mplayer and vlc I just choose jack as audio output. But how do I send flash audio to jack? I have libflashsupport-jack installed. If I close down jack and run pulseaudio then flash audio gets sent there, if I run nothing but alsa, flash output gets sent through alsa. But if I have jack running I dont get any flash audio or even an error message. Where do I configure what output to use for flash?

So the situation is like this:
alsa <- flash : works
alsa <- pulseaudio <- flash : works
alsa <- jack <- mplayer/vlc : works
alsa <- jack <- flash : dosent work

Im running 64bit arch with these versions of the programs mentioned:
flashplugin 10.2.152.27-1
libflashsupport-jack 20110314-1
jack 0.120.1-1
lib32-jack 0.118.0-3 (lib32)
firefox 3.6.15-1
pulseaudio 0.9.22-2
alsa-firmware 1.0.24.1-1
alsa-lib 1.0.24.1-1
alsa-plugins 1.0.24-1
alsa-tools 1.0.23-1
alsa-utils 1.0.24.2-1
lib32-alsa-lib 1.0.24.1-1
lib32-alsa-plugins 1.0.24-1

Offline

#2 2011-03-15 09:07:04

jocheem67
Member
Registered: 2009-11-09
Posts: 243

Re: Flash audio to jack

# convert alsa API over jack API
# use it with
# % aplay foo.wav

# use this as default
pcm.!default {
type plug
slave { pcm "jack" }
}

ctl.mixer0 {
type hw
card 1
}

# pcm type jack
pcm.jack {
type jack
playback_ports {
0 system:playback_1
1 system:playback_2
}
capture_ports {
0 system:capture_1
1 system:capture_2
}
}

I would say, create an asound.conf, this included ot maybe just a bit modified for your hardware. Not sure if it'll help though...
Get rid of pulse, it's an unneeded layer. Not everybody will agree though....:)
For me, opera works better than firefox using the aur prerelease version of flash. Still it remains a bit unstable, but hey..that's flash..

Offline

#3 2011-03-15 11:59:58

heptapod
Member
Registered: 2010-06-24
Posts: 35

Re: Flash audio to jack

I tried that out with mplayer -ao alsa and it works for a couple of seconds then i get this:

AO: [alsa] 48000Hz 2ch s16le (2 bytes per sample)
Video: no video
Starting playback...
subgraph starting at alsa-jack.jackP.27643.0 timed out (subgraph_wait_fd=9, status = 0, state = Running, pollret = 0 revents = 0x0)

**** alsa_pcm: xrun of at least 0.784 msecs

But I can see that the audio gets routed through jack while its working. Trying youtube with the same settings gives no audio and dosent even connect to jack.

According to http://jackaudio.org/routing_flash the best way to do this is not to reroute flash->alsa->jack but instead to route flash->jack directly using libflashsupport-jack. The only instructions on that page is to install libflashsupport-jack and then create one symbolic link. Since libflashsupport.so are in a different place in arch I created this link in /usr/lib/firefox-3.6 instead: libflashsupport.so -> /usr/lib/libflashsupport.so

Am I supposed to do something more to get libflashsupport-jack to work in arch?

Offline

#4 2011-03-16 10:14:47

jocheem67
Member
Registered: 2009-11-09
Posts: 243

Re: Flash audio to jack

pacman -Qo /usr/lib/libflashsupport.so
/usr/lib/libflashsupport.so is owned by libflashsupport-jack 201103

From the comments in aur. It seems that  libflashsupport-jack takes control. Just automagically after installing from aur. No symlinking here...
As I said, firefox isn't the best piece of software for this flash-jack workaround. It's unstable with FF 4.0 RC, but more stable with opera 11.

Offline

Board footer

Powered by FluxBB