20090328 streaming audio with vlc - plembo/onemoretech GitHub Wiki
title: streaming audio with vlc link: https://onemoretech.wordpress.com/2009/03/28/streaming-audio-with-vlc/ author: lembobro description: post_id: 348 created: 2009/03/28 06:58:05 created_gmt: 2009/03/28 06:58:05 comment_status: open post_name: streaming-audio-with-vlc status: publish post_type: post
streaming audio with vlc
This is one of those “first step” posts where I make some notes on how I got something to begin working, at least.
VideoLAN, a/k/a vlc media player, is a cross-platform multimedia client that started out as a student project at the Ecole Centrale Paris. It handles just about every media format known, and does it better than anything else available as open, or in my humble opinion, closed source.
A couple of weeks ago one of my buddies up at corporate called to have me check on whether a training video was accessible from the branch. The file had been pushed out to every branch in anticipation of a training event, and as one of the few IT people who works out of a sales branch I often get called on to sanity check things like that.
Thinking about it later on, I wondered what economical options there might be for streaming video across the network as opposed to dropping files on the local server. Of course the main limiting factor is bandwidth, something that most mid-sized companies have in short supply. Bandwidth is expensive. Very expensive. Which is why our new President (of the United States, that is) has building out the national broadband network infrastructure high up on his list of priorities.
Since I had worked with vlc, I was aware that it has a streaming media server component, but had never tried it.
My first simple test was to set up the streaming of an mp3 file on one of my machines that would be heard on another machine.
The basic procedure was:
1. Execute vlc in console mode on the “server” machine with the following syntax:
vlc -vvv "/u01/media/test.mp3" --sout '#standard{access=http, mux=raw,dst=0.0.0.0:8080}' --sout-http-mime="audio/mpeg" -I http \--http-host my.example.com:9999
2. Execute vlc in console mode on the “client” machine with this syntax:
vlc http://my.example.com:8080
3. Press the “Play” button on the client vlc player.
There are a lot of different ways to do the above, other than how I did it. I’m still learning about them. One of the things that the above server syntax does is set up a separate http administrative interface for the “server” player that can be used to change selections in the playlist. I’ve played with that a little already. According to the documentation you’re supposed to be able to set up the server from the http interface, but I’m still struggling with the exact procedure. The doc isn’t very clear on this and other subjects, suffering from the major weakness of most technical documentation: those who wrote it either know the product so well they take too much for granted, or know it so poorly that anything they do write is so superficial as to be nearly useless.
Copyright 2004-2019 Phil Lembo