HOWTO: Record streaming video and sound (target: NRK.no)

Many of my co-workers are frequently in the media patting the public on the back, saying: "There’s nothing to see here, move along" or "CHECK THIS DATA OUT OMFG!". Some of them are too nervous or drawn into the debate to actually realize how they behave, so they come to me and ask for help to retrieve this media. Thanks to the upshot of news agencies streaming audio and video they have an online option. But how about saving that media locally?

My testing-ground was Norwegian broadcaster NRK, and according to a pdf I just re-discovered, I found a way to record streaming audio from live web radio using Hi-Net Recorder back in December 2005. With WebTV on the rise this simply won’t do any longer. We need both audio and moving images, kittens and mesmerizing colors. Today I found a way by accident..

What you’ll need:
Mozilla Firefox 2.0.0.11
Windows Media Player 11 (’cause the stream was .wmv)
VLC Media Player
– the stream you want to capture

Step one is to get the software you’ll need. Step two is to find the mms stream. This might seem difficult if you don’t understand HTML, but you’ll get there without any such knowledge. Here’s what I did in my case: right-clicked the streaming video playing in Windows Media Player, select Options and copy the entire ramble after Location to the clipboard. In my case the end of the URL said &browser=Firefox which you don’t need.

Head over to TinyUrl.com and paste into their URL-shortening field. Right-click the new URL and select Save As.. and save to some place you’ll remember. (Thanks for the tip, Bl00n!) You’ve now saved the file which usually/hopefully links directly to the media being streamed. To find out, open the file you downloaded in a text-editor (in my case the file was called asx.aspx) and locate the media reference, typically starting with mms:// but this may differ. Sometimes you’ll need to dig further, but eventually you’ll see something leading to a media file.

Now fire up your VLC Media Player and do CTRL+N to open a network stream.
Paste your mms url to the Media Resource Locator.
Under the Network tab, select HTTP/HTTPS/FTP/MMS and paste the URL in the text-field.
Check the Stream Output box and click Settings.
Under Output Options check Play Locally (if you want it to) and File, then Browse, to set the filename and destination of your recorded file.
Choose ASF as your encapsulation method, and under transcoding options check:
– Video codec [set what options you prefer]
– Audio codec [same here]
Click OK and OK, and the media should be played back while streaming to local file.

6 thoughts on “HOWTO: Record streaming video and sound (target: NRK.no)”

  1. Apparently mplayer is available for windows as well. For mplayer users see: 3.4. Streaming from network or pipes. The command below worked for me although there was no live replay (just let it stream finish and watch the file grow..) and the output.asf file was not seekable (I got the "stream not seekable" error):

    mplayer mms://server.extension:port/whatever_url/that_may/belong/wmv.asf -idx -dumpstream -dumpfile OUTPUTNAME.asf

    You will be finished when you get this message:

    Core dumped ;)
    Exiting… (End of file)

Leave a Reply

Your email address will not be published. Required fields are marked *


This site uses Akismet to reduce spam. Learn how your comment data is processed.