kabeldag has asked for the wisdom of the Perl Monks concerning the following question:

G'day folks,

Can anybody shed any light on how one would go about dynamically adding meta-data to
an Ice/Shout Cast MP3 stream ? I really want to be able to read from a waveaudio device,
encode it, and add meta-data whilst simultaniously outputting the encoded MP3 data. ?

In regard to the reading of waveaudio raw data from a wave input device, I have been trudging around msdn, looking at MCI (Media Controller Interface) documentation (but I think one would need to go to a lower API for exact control).
There is of course a Perl module that interfaces with the Windows MCI layer : Win32::MCI::Basic, but I can't seem to see anything on msdn that would enable constant reading from a waveaudio device, at least I couldn't see it.

In regard to dynamically adding meta-data to an MP3 encoded output (my main issue), there are plenty of Perl modules to modify meta-data information on files, but I couldn't find anything on modification of a data chunk via a hardware device. I believe you have to insert the meta-data into the MP3 encoded output stream, and I want to do this dynamically (when and if required - which I don't think is uncommon, just I don't know how to do it) ... How would one go about doing that ... ?

Anybody ever done this type of thing before, or have a possible solution, has sufficient knowledge of Shout/Ice Cast streaming protocol, created meta-data audio streams before, been there done that ?

Thought I might probe the PerlMonk community before heading off on a network application protocol examination process ...

Cheers.

PS: The IceCast Perl module is NOT relevant. Thanking you.
  • Comment on Dynamically inserting meta-data to an MP3 output stream

Replies are listed 'Best First'.
Re: Dynamically inserting meta-data to an MP3 output stream
by zentara (Cardinal) on Dec 21, 2006 at 13:43 UTC
    This is just a long shot, but check out gstreamer It will probably be a PITA to get going on windows, but there is a Perl module for it, and the maillist there may be quite helpful.

    I'm not really a human, but I play one on earth. Cogito ergo sum a bum
      I had a bit of a look, before I investigate gstreamer any further, I think I may be able get the audio via MCI, just been looking at win32-api-prototype, Then I guess it's a matter of encoding and dynamically inserting the meta-data ID tag on the fly, one way or another.

      Heads back to msdn ... :P

      Update: MCI doesn't seem to provide an accessible output buffer of the audio...I think (gah). Lower lower lower ...