FireFly Media Server › Firefly Media Server Forums › Firefly Media Server › General Discussion › Streaming mp3 files directly from external server
- This topic has 3 replies, 2 voices, and was last updated 18 years, 2 months ago by rpedde.
-
AuthorPosts
-
25/09/2006 at 9:31 PM #631twadGuest
I read about the http://wiki.mt-daapd.org/wiki/Streaming_Audio so I thought if I created an .url file with this:
64,Silly name,http://www.test.com/silly.mp3
I would get the soundbridge to stream this mp3 directly from the server – of course that would be to easy. What I wonder is this even possible to force the soundbridge to stream an internet radio directly via an url file?
Will it work to create an extra m3u with the url:
64,Silly name,http://www.test.com/silly.m3uI am trying to create a simple podcast function using only a soundbridge and the fireflymediaserver.
26/09/2006 at 4:01 AM #6599rpeddeParticipant@twad wrote:
I read about the http://wiki.mt-daapd.org/wiki/Streaming_Audio so I thought if I created an .url file with this:
64,Silly name,http://www.test.com/silly.mp3
I would get the soundbridge to stream this mp3 directly from the server – of course that would be to easy. What I wonder is this even possible to force the soundbridge to stream an internet radio directly via an url file?
Will it work to create an extra m3u with the url:
64,Silly name,http://www.test.com/silly.m3uI am trying to create a simple podcast function using only a soundbridge and the fireflymediaserver.
Your second example would work, but it would expect a .m3u/.pls file, not a raw mp3 stream. So yeah, if you made silly.m3u be a playlist pointing to /silly.mp3, that would work.
Find a working .mp3 radio station and wget the contents of the station url — it will be more obvious when you walk through the process manually and see what has to be returned.
— Ron
28/09/2006 at 8:07 PM #6600twadGuestI am still trying to enable my soundbridge to play rss directly from server, just as a small step toward a more complete podcast framework. Here are just my wild rants for your amusement. 🙂
It’s been 8 yeas ago since I programmed C last so I am little bit rusty, so I tried to stay away from the mt-daap source. I wrote a simple python script to download a feed and create lots of .url files. But since an url only could point to an external m3u I scrapped that plan.
First I thought it might work to create a local m3u with the link to the podcast (like this in m3u format with EXTINF and whatnot):
http://www.podcast.com/mypodcast/1But then I found that local m3u files could not have external urls, only link to local files and besides it imported a lot of playlists I did not even knew I had. So I went to the source, which look quite good and even got some comments in it.
I tried some modifications myself like in scan-url.c
//
// This is a “modification” to get podcast info as url:
//
char* ext = strstr(pmp3->url, “.mp3”);
if (ext != NULL && ext[4] == 0)
{
pmp3->codectype = “mpeg”;
pmp3->artist = “Magic Podcast”;
}and oh by magic my soundbridge is streaming mp3 podcasts like there is no tomorrow, but I see that this is not an optimal solution. Ok – just ranting here – what I need is support for a magic playlist file which support inserting urls into playlists.
So I was considering some solutions:
1. Add capability to read rss streams directly in scanner (maybe a feed downloaded by wget) – this would need a rss parser built into mt-daap and that seems like overkill.
2. Add an intermediate format – as simple as a m3u, but where mt-daap accepted external urls and imported fields like artis and such without need to lookup external server, but rather used the information in the playlist.
3. Extend the .url file scanner so I am able to import fields like artis, length, etcSo my question is would any of these 3 solutions be interesting to other than me and if the quality was ensured maybe be included in the original fireflymediaserver? Or are there some simpler way to achieve this?
29/09/2006 at 3:05 AM #6601rpeddeParticipant@twad wrote:
1. Add capability to read rss streams directly in scanner (maybe a feed downloaded by wget) – this would need a rss parser built into mt-daap and that seems like overkill.
And something that doesn’t belong inside the server, imho — it screams for a scripted solution, I think.
2. Add an intermediate format – as simple as a m3u, but where mt-daap accepted external urls and imported fields like artis and such without need to lookup external server, but rather used the information in the [/playlist.
Except this is not a one-time problem — there are other things that are very similar that could be done.
3. Extend the .url file scanner so I am able to import fields like artis, length, etc
That needs to be done anyway, to suport tag writeback.
At some point, we talked about a scripting interface that would allow someone to insert arbitrary info into the database. I saw it working something like this:
1. When scanning, when a server recognized a script (*.ffs – fireflyscript?) it would execute the script with a single argument: “index”. This would dump a list of items to be inserted into the database. The format would be something like:
fieldname vieldvalue
An “id” field would be the internal ID that the script recognized. So something like this:
id 1
artist some artist
album some album
item_kind 2
type .mp3
url http://some.server/song/whatever.mp3
bitrate 64
samplerate 44100
id 2
artist some other artist
...
The field names would be the same as the column names in the songs table, or the fields in the PMP3 structure.
When it came time to play one of those songs, then the firefly would execute the same script with two arguments, “stream” and the id of the song to stream. The script would dump the output to stdout.
That seemed like fairly flexible interface.
seem reasonable?
-
AuthorPosts
- The forum ‘General Discussion’ is closed to new topics and replies.