Tuesday, January 23, 2007

Configure Realplayer on linux and play various media-players simultaniously and smoooooothly ;)

Well folks, here is an important tip related to multimedia stuff in Fedora Core 6 (FC6) what I have learned based on my experience with the OS. I hope you will find it useful.

Things related to installation of mplayer, kaffeine, realplayer etc. are available everywhere on internet but there is more to be done as far as realplayer is concerned. Realplayer seems to be co-operating least with other media-players and here is an workaround....lets begin anyway !!

* Login as root first using $ su ;)


* Install RealPlayer from www.real.com. I would recommend to download .bin file for the GOLD version. Once the download is complete:


1. # cd
2. # chmod 755 ./RealPlayer10GOLD.bin
3. # ./RealPlayer10GOLD.bin

This will lead you to installation. Follow the instructions and install it in "/usr/local/RealPlayer" folder and give "/usr/local" as option for creating links. Now, switch to the /usr/local/bin folder using "# cd /usr/local/bin" and check if there is a symbolic link created there as "realplay" pointing to "/usr/local/RealPlayer/realplay" by using the command "# ls -l". If you find no link, create one as follows:

4. # ln -s /usr/local/RealPlayer/realplay

With these steps, you are done with the installation.

* Install the package alsa-oss using yum [# yum -y install alsa-oss]. This establishes a kind of negotiation between oss and alsa. This is a must by the way. (Here, I am assuming that u have set the yum correctly and you are having repos for livna, freshrpms, fedora update, extras etc. already included).



* Now, it's time to edit the realplay script. Do # vim /usr/local/bin/realplay and add the lines:

LD_PRELOAD="$LDPRELOAD:/usr/lib/libaoss.so.0.0.0"
export LD_PRELOAD

Add the above lines just after the section:
if [ -n "$LD_PRELOAD" ]; then
echo "Warning: LD_PRELOAD=\"$LD_PRELOAD\""
fi

Save and exit. Switch back to normal user (no superuser anymore).

Of course, if the library libaoss.so.0.0.0 is located to somewhere else, use that path instead. Sometimes, depending on the version of the alsa-oss package, the libaoss.so.0.0.0 library may not be available. In those cases, try to replace it by libaoss.so.0 or libaoss.so. Use # updatedb; locate libaoss.so to find out which one is available to you.

* Now run realplay as a normal user and follow the instruction what comes with first time run of the realplayer. Once you are done with these instructions, quit the realplayer and edit the file ~/.realplayer. Add the line SoundDriver=2 to it below the [helix] section as it is mentioned at FC6 Tips & Tricks.


* One more thing, go to KDE Control Center -----> Sound System ------> General -------> Auto-suspend if idle after 1 seconds.


Now, it's time to check if things work properly or not. Open realplayer and other media players (e.g. mplayer, kaffeine etc.). After the aforementioned procedure, I didnt have any problem with sound on FC6 anymore.

Also, I would like to mention (my personal choice) that don't install mplayerplug-in. It sucks. Rather, there are many marvelous extensions available with Firefox to deal with online media. I would recommend mediaplayer connectivity. It does excellent job. It redirects online streams to your local media player and so you can use mplayer, kaffeine, realplayer etc. to watch/listen all those streaming stuffs.


Good Luck ;) This is working well on my FC6 box and I hope this would work well on other distros as well. If need any further information in this regard, please leave your comments below.