DaemonForums  

Go Back   DaemonForums > OpenBSD > OpenBSD General

OpenBSD General Other questions regarding OpenBSD which do not fit in any of the categories below.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 24th August 2009
J65nko J65nko is offline
Administrator
 
Join Date: May 2008
Location: Budel - the Netherlands
Posts: 4,125
Default Playing internet radio streams under OpenBSD

At this moment I am listening to http://www.zappa.com/zapparadio/ under Ubuntu (long story). This Zappa audio stream from live365.com is played by the Gnome Totem movie player.

Would that player work under OpenBSD? I don't mind installing Gnome on one of my snapshot machines.

Does anybody have experiences with the audio/aqualung port? It is the only port/package I could find via http://openports.se/audio

PS. Yes I have read the FAQ (http://openbsd.org/faq/faq13.html#streaming)
__________________
You don't need to be a genius to debug a pf.conf firewall ruleset, you just need the guts to run tcpdump

Last edited by J65nko; 24th August 2009 at 11:03 PM. Reason: Added FAQ remark
Reply With Quote
  #2   (View Single Post)  
Old 25th August 2009
Oko's Avatar
Oko Oko is offline
Rc.conf Instructor
 
Join Date: May 2008
Location: Kosovo, Serbia
Posts: 1,102
Default

J65nko,

I am so happy you asked that question. Just couple of days ago I was playing with similar things. Namely, I want to listen to Moskva.fm radio as well as Radio Television Serbia live program.


Moskva.fm uses flash to deliver radio as many other internet radio stations. So I was unable to play it. Recently swfdec-plugin was updated to the latest 8.2 for 4.6 release. The reason the port was stale is the lack of support for OSS audio by swfdec which was dropped around 6.8. I heard good reports about latest swfdec. It should be as good as Flash 9. Unfortunately I have no clue if there is work around for OSS problem. I know that Jake has submitted some patches to swfdec but they refuse because they want to support only ALSA.

Speaking of RTS it is RAM file. Theoretically mplayer plugin should play it without any problems. I had no luck on OpenBSD. I tested with SLAX. Plays without any problems.The Mplayer, ffmpeg, and similar ports are badly outdated for OpenBSD. However as we speak the MAJOR effort is under way to bring those ports to the latest releases. Just look the versions in current.

I absolutely have no experience with audio/Aqualung. Please let me know when you test it.

I found shell-fm which is the shell client for British Last.fm radio. It is FANTASTIC. I am speechless how good are both
the client and Last.fm station.

xmms has fm plugin. It didn't work for me.

There is also something called /net/flvstreamer for streaming media content. The problem with that is that you have to supply rtmp url which means you have to see the source code of the web-site.
It looks like /multimedia/get_iplayer should help but I have not played enough with it.

I am all ears and eyes to see posts on this thread.

Thank you,
OKO

Last edited by Oko; 25th August 2009 at 01:07 AM.
Reply With Quote
  #3   (View Single Post)  
Old 25th August 2009
BSDfan666 BSDfan666 is offline
Real Name: N/A, this is the interweb.
Banned
 
Join Date: Apr 2008
Location: Ontario, Canada
Posts: 2,223
Default

You can play this stream with mplayer.. vlc.. or even ffmpeg, it is MP3 encoded.

http://www.live365.com/cgi-bin/play....o&filename.pls

This file is a text play list, copy the link from within it into any program and.. wait.
Reply With Quote
  #4   (View Single Post)  
Old 25th August 2009
Oko's Avatar
Oko Oko is offline
Rc.conf Instructor
 
Join Date: May 2008
Location: Kosovo, Serbia
Posts: 1,102
Default

Quote:
Originally Posted by BSDfan666 View Post
You can play this stream with mplayer.. vlc.. or even ffmpeg, it is MP3 encoded.

http://www.live365.com/cgi-bin/play....o&filename.pls

This file is a text play list, copy the link from within it into any program and.. wait.
Absolutely correct!!! I have not checked before posting. However I clam that Lat.FM radio http://www.last.fm/
is far better. You do have to register for free account however.

BSDfan666 could you check if you can play the following link?

http://www.rts.rs/page/live/ci.html

The RAM file contains
rtsp://helix.beotel.net/encoder/rts1.rm

How do you play that crap?

Last edited by Oko; 25th August 2009 at 03:43 AM.
Reply With Quote
  #5   (View Single Post)  
Old 25th August 2009
Oko's Avatar
Oko Oko is offline
Rc.conf Instructor
 
Join Date: May 2008
Location: Kosovo, Serbia
Posts: 1,102
Default

Quote:
Originally Posted by Oko View Post

The RAM file contains
rtsp://helix.beotel.net/encoder/rts1.rm

How do you play that crap?
I am a moron. I was blocking port 554 used by rtsp service. I can play it without any problems with MPlayer

This is how you can even record the file

Code:
mplayer -noframedrop -dumpfile out.rm -dumpstream rtsp://url/to/file.rm
I want to mention that RTSP service by default uses UDP protocol. To force it to use TCP

Code:
mplayer -rtsp-stream-over-tcp rtsp://url/to/file.rm

Last edited by Oko; 25th August 2009 at 03:44 AM.
Reply With Quote
  #6   (View Single Post)  
Old 28th August 2009
J65nko J65nko is offline
Administrator
 
Join Date: May 2008
Location: Budel - the Netherlands
Posts: 4,125
Default

I am able to play http://live365.com streams with mplayer. My problem was that firefox didn't offer to save a play.pls file.
After creating an live365 account, you can configure not to use the default Flash player.
Now firefox offered to save a play.pls file.

My first stage was to copy the url from the play.pls file and feed it to mplayer
Code:
$ mplayer 'http://www.live365.com/play/304512?auth=d16b3e911d9de95d3b0dedcfff6
4c6f8-1251516247-compaxx&ss=major_j65%3AREH00CtMQNt4L5F&tag=
live365&token=660e15ffc46c9233b349666b0788788c-2419280080601
251&sid=xxx.xxx.xxx.xxx-1251418953547076&lid
=nh-nld&from=pls'
Note that you have to use single quotes to prevent the shell from doing weird things with characters like '&'. Be warned that I replaced my IP address with 'xxx.xxx.xxx.xxx' .

After reading the mplayer manual I found you can pass it the name of a playlist file. So it is as simple as
Code:
$ mplayer -playlist Desktop/play.pls
Code:
MPlayer 1.0rc2-3.3.5 (C) 2000-2007 MPlayer Team
CPU: Intel(R) Pentium(R) 4 CPU 2.00GHz (Family: 15, Model: 2, Stepping: 4)
CPUflags:  MMX: 1 MMX2: 1 3DNow: 0 3DNow2: 0 SSE: 1 SSE2: 1
Compiled with runtime CPU detection.

Playing http://www.live365.com/play/191432?auth=a29fa8004035f62b6793f59de4a33b71
-1251521875-joerockusa&ss=major_j65%3AREH00CtMQNt4L5F&tag=live365&token
=bdfa0d1bd6f35d927ee9249ebcd96abd-5720280080701251&sid=xxx.xxx.xxx.xxx
-1251418953547076&lid=nh-nld&from=pls.
Resolving www.live365.com for AF_INET6...
Couldn't resolve name for AF_INET6: www.live365.com
Resolving www.live365.com for AF_INET...
Connecting to server www.live365.com[216.235.95.145]: 80...
Resolving 216.235.94.11 for AF_INET6...
Couldn't resolve name for AF_INET6: 216.235.94.11
Connecting to server 216.235.94.11[216.235.94.11]: 80...
Cache size set to 320 KBytes
Cache fill: 15.00% (49152 bytes)   
Audio file file format detected.
==========================================================================
Opening audio decoder: [mp3lib] MPEG layer-2, layer-3
AUDIO: 44100 Hz, 2 ch, s16le, 128.0 kbit/9.07% (ratio: 16000->176400)
Selected audio codec: [mp3] afm: mp3lib (mp3lib MPEG layer-2, layer-3)
==========================================================================
AO: [sndio] 44100Hz 2ch s16le (2 bytes per sample)
Video: no video
Starting playback...
Blocktype == 0 and window-switching == 1 not allowed.
A:2351.8 (39:11.8) of 0.0 (unknown)  0.9% 35%
I used an 4.6 I386 current snapshot and precomiled binary snapshot packages for firefox and mplayer.

The stream is over TCP as shown by netstat
Code:
$ netstat -an -f inet

Active Internet connections (including servers)
Proto Recv-Q Send-Q  Local Address          Foreign Address        (state)
tcp    15560      0  192.168.222.244.33004  216.235.94.11.80       ESTABLISHED
tcp        0      0  *.6000                 *.*                    LISTEN
tcp        0      0  127.0.0.1.587          *.*                    LISTEN
tcp        0      0  127.0.0.1.25           *.*                    LISTEN
tcp        0      0  *.22                   *.*                    LISTEN
tcp        0      0  *.37                   *.*                    LISTEN
tcp        0      0  *.13                   *.*                    LISTEN
tcp        0      0  *.113                  *.*                    LISTEN
Active Internet connections (including servers)
Proto Recv-Q Send-Q  Local Address          Foreign Address        (state)
udp        0      0  192.168.222.244.19487  94.23.144.15.123
udp        0      0  192.168.222.244.1923   194.109.64.200.123
udp        0      0  192.168.222.244.33484  145.24.129.5.123
udp        0      0  192.168.222.244.37586  82.98.234.142.123
udp        0      0  192.168.222.244.19194  194.171.167.130.123
udp        0      0  127.0.0.1.512          *.*
udp        0      0  *.514                  *.*
__________________
You don't need to be a genius to debug a pf.conf firewall ruleset, you just need the guts to run tcpdump

Last edited by J65nko; 28th August 2009 at 11:49 PM. Reason: netstat output added
Reply With Quote
  #7   (View Single Post)  
Old 29th August 2009
unicyclist unicyclist is offline
Real Name: Mike
Fdisk Soldier
 
Join Date: May 2008
Location: Alaska
Posts: 63
Default

Great info. Thanks guys.
Reply With Quote
Reply

Tags
audio stream, live365.com, mplayer, radio, rtsp

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Playing a CD. maxrussell FreeBSD General 2 22nd July 2009 07:24 PM
Internet Access Problem OpenBSD 4.3 alcy OpenBSD General 3 19th September 2008 06:00 PM
OSS , playing a sound via command line.. scotsman FreeBSD General 7 29th August 2008 08:01 PM
playing songs in text mode rex FreeBSD General 4 27th August 2008 08:48 PM
Playing DVDs drhowarddrfine FreeBSD Ports and Packages 9 30th May 2008 02:46 PM


All times are GMT. The time now is 05:10 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick