views:

129

answers:

0

I'm trying to listen to a live audio stream on a webpage with a latency of less than 3 seconds. So far with ogg vorbis streams generated using ices & icecast, I've been unable to get latencies less than 7 seconds. All players I've used so far (html5 audio tag in Firefox, Opera, Safari; VLC as well) seem to introduce similar delays. It's unclear at this point how much latency is introduced in ices/icecast vs. the client-side player. I've tweaked ices and icecast settings, to no avail.

Has anyone achieved better latencies than this in a similar ices/icecast setup? I wouldn't expect an ogg vorbis decoder (be it html 5 in a browser, VLC, or whatever) to delay an audio stream for multiple seconds. Am I incorrect? I can't find any info on controlling buffer sizes or the decoding in browsers.

With a different architecture (html 5, firefox, WSGI server serving wav format audio), I was able to achieve latencies around 1-2 seconds. By default, the firefox began playing the wav file 5+ seconds behind, but I could advance playback by setting audio.currentTime ahead, and only be 1-2 seconds back (somewhat fragile). However, I'd much prefer to use icecast, and streaming wavs obviously doesn't scale.

Thanks in advance for any ideas.