[Icecast] Metadata Swapping: How do they do it?

oddsock oddsock at oddsock.org
Fri May 6 07:29:06 PDT 2005

At 03:52 PM 5/5/2005, you wrote:

>This would be expected to appear in iTunes / WinAmp as:
>"PulverRadio - Raw Rock Radio - 128K"
>...but this makes Icecast VERY unhappy.  Returns a 404.
>So the questions are:
>A)      What is the format of the metadata-on-connect that is expected by 
>most clients?
>B)      As is my usual question, how do we set this data where the 
>broadcaster isn't using ices?
>C)      If there is no such format, maybe this is the time to define a 
>defacto standard and hope it sticks?

First off, I'm going to assume that you are talking MP3 only, as it's 
different with Ogg Vorbis streams.  The actual Mp3 metadata "protocol" is 
quite simple, and is pretty well documented in various places (you probably 
know this).    This metadata comes at regular intervals in the stream and 
is what stations are using to "continually update" what's being shown in 
winamp.  Also, keep in mind that how metadata is actually displayed to the 
user is *player specific*.. I'll use Winamp as an example here, as that 
sounds like what you are using as a reference.

So what you are calling "metadata" actually comes in two forms :

1. The HTTP response headers sent by icecast when winamp first 
connects.  There is quite a bit of information contained in this header, of 
which winamp uses only "Stream Name".  Note that if stream name isn't 
provided (this Stream name is actually provided by the source client - 
ices/oddcast/etc) then winamp will default to displaying the 
mountpoint.   Note that there may be some other special winamp handling 
that is done depending on your mountpoint extension (Winamp works based off 
your extensions, which means if you name it .ogg it will feed your stream 
into the ogg vorbis decoder).  All shoutcast-based streams have a 
mountpoint of "/" (i.e. no extension) and winamp knows that these are true 
mp3 streams.  If you feed winamp a URL with a .mp3 extension (as you are 
doing) I'm not entirely sure what winamp will do.  By looking at your 
status page, it looks like you are sending the Stream Title, so why don't 
you try to change your mountpoint to /high and /low, and see what happens.

2. The in-stream metadata protocol.  This is what the stations you mention 
are using for the dynamic update of what's being shown in winamp.  This is 
modified via a simple URL call to icecast (see the docs for 
/admin/metadata).  All you need is a simple external script that alternates 
between your current song title and your stream name in that call, and you 
have the effect you are looking for.

>If C) is a valid interest then this would be an opportunity to send a 
>whole plethora of stuff with the stream, including ID3 tags for both the 
>stream itself and each song within it.  There's probably no reason not to 
>be ambitious in this regard.

you are highly encouraged to do so, however, keep in mind that we've been 
trying to do this for years in various forms without any real luck.  Heck, 
the vorbis protocol was designed *specifically* to handle metadata in a 
good and proper way, but vorbis is the only one that uses it.  My guess is 
that we could have accomplished something if we only got cooperation from 
the folks over at Nullsoft, not that it's really they're fault - it's 
really just an organizational problem.


More information about the Icecast mailing list