[Icecast] Updating MetaData at the Relay

oddsock oddsock at oddsock.org
Tue Feb 15 14:45:37 UTC 2005


At 08:24 AM 2/15/2005, you wrote:
>Sending again .... is this thing on?

sorry, meant to respond, been very busy of late....

>On 11-Feb-05, at 9:20 PM, oddsock wrote:
>
>>no...at the moment, only "song" is supported.  All other stream info 
>>details (URL, Genre, etc) is not currently update-able via the admin 
>>interface.  The must be supplied by the source client on connect.
>
>Okay, so this actually injects it into the stream as shoutcast metadata, 
>not just into the server's admin interface?  Someone just emailed me to 
>say that this simply updates currently-playing data on the admin pages.

Currently, when you set the metadata via the server's admin interface, that 
metadata will then be injected into the outgoing stream (i.e. that sent to 
listeners) using the shoutcast metadata protocol (I'm only going to be 
talking about MP3 here).  It does NOT just update the currently playing 
data.  It USED to do this pre-2.2, but only for Vorbis streams...

>>back to your question about shoutcast-metadata, the metadata protocol 
>>only supports two fields StreamTitle and StreamUrl.  Virtually ALL 
>>players (with the exception of winamp) ignore StreamUrl.  Winamp will use 
>>this information in the event that you actually open the winamp 
>>mini-browser while listening to a stream, it will open to the default 
>>page of the StreamUrl (or at least, that was the way it used to 
>>work).  So, for shoutcast-metadata, you really only have StreamTitle 
>>(which is usually just the song title).   This is actually, why the 
>>admin/metadata call only takes "song", and it was created back when we 
>>only supported updates for mp3 streams.  Now, one could aruge that you 
>>should also be able to update the genre and maybe the url, but since 
>>these fields are used mainly for YP listing, they tend not to be fields 
>>that people want to update.
>
>For the static YP variables (genre, url) I'd at least like to be able to 
>modify these at runtime in the Icecast config file, which is as I

Currently, we do not have a mechanism for specifying (or overriding) these 
parameters in the icecast config.  I welcome you to post something to 
http://trac.xiph.org as an enhancement.  Alternatively, in do_yp_add() line 
344 of yp.c, you will find the following line :
     ret = snprintf (s, len, "action=add&sn=%s&genre=%s&cpswd=%s&desc="
                     "%s&url=%s&listenurl=%s&type=%s&stype=%s&b=%s&%s\r\n",
                     yp->server_name, yp->server_genre, yp->cluster_password,
                     yp->server_desc, yp->url, yp->listen_url,
                     yp->server_type, yp->subtype, yp->bitrate, 
yp->audio_info);
a simple hard coding of your parameters there will also suit your 
needs.  Note doing it properly via config overrides takes a bit more work :)

>seem to remember how Shoutcast behaves.  Try finding my servers on the 
>xiph.org yellow pages. :)
>
>...and I presume that when we update the song title using the method I 
>specified above it causes Icecast to spark a GET to the xiph Yellow Pages 
>to update song data, as well... correct?

Not sure, I'd have to look closer at the YP code..it used to, but Karl 
re-wrote how the YP communication was done with icecast.  He may have 
pulled it out into a "periodic" update rather than an immediate trigger update.


oddsock 





More information about the Icecast mailing list