jack plugin for the flash player

What other apps and distros do you use to round out your studio?

Moderators: MattKingUSA, khz

Pablo
Established Member
Posts: 1274
Joined: Thu Apr 17, 2008 9:57 pm
Been thanked: 3 times

jack plugin for the flash player

Post by Pablo »

Hi,
There is a jack plugin for the flash player. Youtube, vimeo, myspace etc. can be heard through jack without the need of the alsa-jack plugin or pulse-jack sink or the get-the-file-from-/tmp-directory-and-open-it-with-VLC workarounds.
I have tested it and it seems to work well although it is not oficially released afaik.

It was announced months ago,
http://old.nabble.com/-ANN--jack-enable ... 96276.html

To install:

git clone git://repo.or.cz/libflashsupport-jack.git
cd to the libflashsupport directory
sh bootstrap.sh
make
sudo make install

Needed packages (for ubuntu 9.04 / 9.10. YMMV):

libasound2-dev
libjack-dev
libsamplerate0-dev
libssl-dev
build-essential
git-core
autoconf
automake
libtool

Thanks Torben

EDIT:

For ubuntu lucid, with a new version of firefox, an extra step is needed:

sudo ln -s /usr/local/lib/libflashsupport.so /usr/lib/firefox-3.6.3/

If somethins goes wrong with firefox:
killall firefox
killall firefox-bin

And launch it again
Last edited by Pablo on Thu Apr 29, 2010 11:50 am, edited 1 time in total.
User avatar
Scary Hallo
Established Member
Posts: 280
Joined: Fri Oct 23, 2009 2:21 pm
Location: Germany / Pforzheim
Contact:

Re: jack plugin for the flash player

Post by Scary Hallo »

Hey, good to hear!
I was seaching for a tool like that for a while. I'm gonna test it tomorrow.
dakylla
Established Member
Posts: 28
Joined: Mon Jan 12, 2009 12:02 pm

Re: jack plugin for the flash player

Post by dakylla »

hi, this is really a good news :)
ok, time for jack to rule the world (and time to get ride of pulse :p)
Linux should get ride of oss/pulse/arts/whatever you want....
the Linux's audio world is such a mess....
JACK everywhere !!!
one universal audio interface.
JACK just need a very simple way (simple code) to allow an application to easily play a sound file
ok, enough, im going to compile that right away. Thx for the news ;)
dakylla
Established Member
Posts: 28
Joined: Mon Jan 12, 2009 12:02 pm

Re: jack plugin for the flash player

Post by dakylla »

im back,

the jack plugin is working perfectly.
there only one need : could it be possible after a jack restart not to have to restart the browser too ?
i think i'll make a bug report and see what the developper think about this :)

cia
thorgal
Established Member
Posts: 739
Joined: Mon Apr 07, 2008 6:04 pm

Re: jack plugin for the flash player

Post by thorgal »

seems quite difficult to achieve from the perspective of an output plugin.

If jack restarts, it means that jack has shut down. So all clients were destroyed on the way. The application becomes an "orphane" in that respect (if its non-jack parts survived the jack shutdown). If it does not have a mechanism that allows it to survive a collapse of the jack graph, there's no way it can reconnect after jack comes back to life. So I don't expect much. If the devs can implement such a thing, it would be cool though (we did this for guitarix 8) ).

On the other hand, even though this is deprecated, I still use oss2jack. Here, what the flash plugin expects is a /dev/dsp to talk to. When jack restarts and oss2jack is automatically launched with it (cf. qjackctl misc options where you can autolaunch whatever you want), the flash plugin will still find /dev/dsp as if nothing happened (therefore no need to restart the browser). Deprecated, yes, but still works :) (I am still wondering what will happen with the newer CUSE framework).
thorgal
Established Member
Posts: 739
Joined: Mon Apr 07, 2008 6:04 pm

Re: jack plugin for the flash player

Post by thorgal »

well, since 2.6.32, my oss2jack fix is no longer working (something changed with fuse and the rise of cuse). So I just tried the flashsupport-jack and it works nice, if you don't close and reopen jack as stated above. However, when I try the video in fullscreen, the whole iceweasel (firefox in debianese) blows up :D

it does not kill jackd and I see no xrun though ;)

EDIT: I looked at the code. It does not have a jack_on_shutdown() callback. Maybe I could hack into it when I am bored :)
SR
Established Member
Posts: 218
Joined: Wed May 07, 2008 6:01 pm
Location: Houston, Tx

Re: jack plugin for the flash player

Post by SR »

Any hints to getting the plugin to work on x86_64?
thorgal
Established Member
Posts: 739
Joined: Mon Apr 07, 2008 6:04 pm

Re: jack plugin for the flash player

Post by thorgal »

dakylla wrote:im back,

the jack plugin is working perfectly.
there only one need : could it be possible after a jack restart not to have to restart the browser too ?
i think i'll make a bug report and see what the developper think about this :)

cia
OK, I had time to look into it more carefully. No need to file a bug report. The jack_client_open() function is used with the "null" jack_option_t bit. This means for users that the plugin is allowed to start jackd if it is not already running. If you have a file called .jackdrc (mind the leading dot) in your home directory, then it will work :)

.jackdrc is usually created by qjackctl. Mine looks like this:

Code: Select all

$ cat ~/.jackdrc
#the file contains this command line:
/usr/bin/jackd -S -R -P70 -dalsa -dhw:1 -r96000 -p64 -n2 -s -Xseq
replace with your own setting.

Note: I tested with jack2. Don't know what jack1 will say.

Note2: If you don't have this file, it won't work at all.


PS: no idea about 64bit. Try it and see if you can compile it. Jack@64bit can accept 32bit clients and vice-versa.
dakylla
Established Member
Posts: 28
Joined: Mon Jan 12, 2009 12:02 pm

Re: jack plugin for the flash player

Post by dakylla »

hi,
thx for your time.
i have my jackrc file.
i think the plug-in tries to open a jack connection only when the browser starts, or when the first flash file is processed.
if after this, you stop the jack server, libflash won't reconnect.
thorgal
Established Member
Posts: 739
Joined: Mon Apr 07, 2008 6:04 pm

Re: jack plugin for the flash player

Post by thorgal »

you don't need to kill the browser. Only the tab containing the video. Reopen the tab again and it should be fine. But it's true a simpler page reload would be nice :)
larz
Established Member
Posts: 16
Joined: Thu Jun 04, 2009 12:30 pm

Re: jack plugin for the flash player

Post by larz »

Thanks. It works! This made me a much happier man. Been looking for something like this for months. As you probably know the RME HDSP 9632 doesn't work well with pulseaudio.
Now that's a happy first post.
studio32

Re: jack plugin for the flash player

Post by studio32 »

larz wrote:Thanks. It works! This made me a much happier man. Been looking for something like this for months. As you probably know the RME HDSP 9632 doesn't work well with pulseaudio.
Now that's a happy first post.
welcome :)

What distro + version do you use?
What problems do you have with pulse?
larz
Established Member
Posts: 16
Joined: Thu Jun 04, 2009 12:30 pm

Re: jack plugin for the flash player

Post by larz »

Thanks.

Well it's a long story. But the modules can't load with pulseaudio. Here's my talk with alsa-dev, that unfortunately soon got to technical for me, and I gave up: http://mailman.alsa-project.org/piperma ... 22642.html

People on ubuntforums seem to have the same problem. Didn't see anyone who had solved the problem. Only very strang workarounds. I have more info from when I was talking to Colin Guthrie from pulseaudio. He states that there is a problem with the way ALSA handles this card, therefore it can't load the pulse module.

That's why I have now set up my system to route sound to jack. On the other hand I'm kind of happy with that. Especially after the fix I found in this thread. But I wouldn't mind solving my pulseaudio-problem.

I'm on ubuntu 9.10 64bit kernel 2.6.31-16.

I also have a rt-kernel installed, but it doesn't work with my NVIDIA card (GeForce 7800 GS on the nvidia-185 drivers from ubuntu-repos).
thorgal
Established Member
Posts: 739
Joined: Mon Apr 07, 2008 6:04 pm

Re: jack plugin for the flash player

Post by thorgal »

larz wrote: I also have a rt-kernel installed, but it doesn't work with my NVIDIA card (GeForce 7800 GS on the nvidia-185 drivers from ubuntu-repos).
get the beta driver from the nvidia website and compile it yourself (195.22).
I have a GeForce 9500 GT and had no problem with 2.6.31 and now 2.6.32. But I install from the nvidia installer, I don't rely on the debian package.
larz
Established Member
Posts: 16
Joined: Thu Jun 04, 2009 12:30 pm

Re: jack plugin for the flash player

Post by larz »

Thanks. Does it matter which kernel I'm running while compiling? And does it work with dkms when I compile myself?
Post Reply