2011-01-20

More on Jack...

Well, jack isn't working well with non jack applications. The jack-plug doesn't always work and I can't get it to be stable. I'll continue to look into it. If I find anything I'll post it here. For now I'll use jack with applications that support jack.

2011-01-19

Enhanced security in Chromium

I moved away from Firefox to Chromium (the open source part of Google Chrome). When I moved I search for all the extensions I used in Firefox. One of them was Flashblock. There is also a Flashblock for Google Chrome but I wanted to block all plugins until I say so.

Luckily, Google Chrome has that option. Just got to about:flags and enable on the Click to Play flag (this is available in the latest beta of Google Chrome 9, I don't know about the stable Google Chrome 8). Restart the Browser so the flag comes into use. Then enable click to play for the plugins as follows: Open the Preferences, go to "Under the Hood", Right under the "Privacy" click the button "Content Settings...". Then select "Plug-ins" and choose the brand new "Click to play" option.

When you open pages with plugins an icon will appear in the address bar indicating that plugins were blocked. You can use the icon and enable all the plugins for the page, but I prefer the Click to Play: Google Chrome will put a gray area with a large puzzle peace icon on it. When you hover the mouse on it the mouse changes and an indication appears saying "Click to run this plug-in" with the name of the plug-in under it. If you want just click it. You can also you the icon on the address bar to always allow plugins on certain domains (like Youtube).

Using jack to record telcos and screen

At my job we use VOIP regularly when making conferences or simply calling a colleague. We also have a screen sharing tool that we use to share the screen to remote participants. This is also used to make remote training sessions. What I've been missing is a way to record both the shared screen and sound for later viewing. I hacked jack a little in the past but didn't manage to get it working. I've been having some free time so I decided to hack it today and I finally got it working. So, from the start.

Gentoo's JACK guide on the wiki is not bad but I honestly didn't pay much attention to it. I have the jack use flag enabled globally so it was time to get it going.

First I emerged qjackctl. It is nice program that sits on the tray area (I have it default to hidden) that starts the jack daemon and that allows you to control what is connected to where. I also emerged alsa-plugins to get the alsa-jack plugin. Finally I emerge jamin. I need it just to be able to get the output back in :-)

I configured also to use the jack plug by default. This can be done by creating a ".asoundrc" file in your home folder with the following content:
pcm.!default {
        type plug
        slave { pcm "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 also keep a ".asound_nojack" file that has the jackplug but doesn't turn it to the default audio output for alsa.
pcm.jackplug {
        type plug
        slave { pcm "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
        }
}
With that in place any application that does not support jack but support alsa will still work.

qjackctl has several windows, one of them is the Connections. I use it to reroute sound before recording.

What I do is start jamin, redirect all the bits I want to record to jasmin and disconnect them from the system output. Then start qt-recordmydesktop and point it to use the jamin output as audio source when recording. Here are screenshots of the important bits.


Importante Note: recordmydesktop has a bug that makes it complain that it has no jack support, even though the use flag is turned on. This is fixed upstream and available in Gentoo as a backport but you will have to unmask the package (0.3.8.1-r4 works at the time I wrote this).

NOTE: This isn't working very well... see here