Tuesday, October 2, 2007

Mplayer and Sopcast in Slackware 12.0

From the website, SopCast is a simple, free way to broadcast video and audio or watch the video and listen to radio on the Internet by adopting P2P technology. It needs media player such as vlc or mplayer on top of it. Basically, from my understanding, it only provides streams of data in a certain format (i.e. wmv3) that is readable, and thus viewable, by the media players. Since vlc doesn't support wmv3 format, we'll have to rely on mplayer for this particular case.
I downloaded the Slackware package for mplayer from here.
Then, I downloaded these 2 files for SopCast:
http://download.sopcast.com/download/sp-auth.tgz
http://www.sopcast.com/download/libstdcpp5.tgz
From the readme file :
SopCast client version 1.0.2 library dependency
If you don't have stdc++ 5 in your system, please download the libstdcpp5.tgz from
www.sopcast.com, and copy the
libstdc++.so.5
libstdc++.so.5.0.1
to /usr/lib/

The copy command must be:
cp -a libstdc++.so.5* /usr/lib
With '-a' parameter, and you must login as root.

1. sp-sc-auth

A simple example of sp-sc command line.
./sp-sc-auth sop://broker.sopcast.com:3912/6098 3908 8908 > /dev/null &
Start to transfer channel 6098, and you can play it on 8908 with VLC or mplayer
by open the url: http://localhost:8908/tv.asf
Then, from konsole:
mplayer -zoom http://localhost:8908/tv.asf
What's interesting from the Linux version of vlc is that here we could stream several channels at the same time, which is not possible in that of Windows XP's.
From konsole:
Start streaming channel 1(Channel ID:6001, Port: 8908)
./sp-sc-auth sop://broker.sopcast.com:3912/6001 3908 8908 > /dev/null &
Show the channel at mplayer:
mplayer http://localhost:8908/tv.asf
Start streaming channel 2:(Channel ID:6002, Port 8909)
./sp-sc-auth sop://broker.sopcast.com:3912/6002 3908 8909 > /dev/null &
Show the channel at mplayer: (Note, now the TCP port is 8909)
mplayer http://localhost:8909/tv.asf
etc

No comments: