Take the 2-minute tour ×

I would like to read an MP3 stream (from icecast, to read ICY metadata an then pass the binary MP3 data to a Web Audio Api).

Firefox has a "moz-chunked-arraybuffer" xhr responseType to read data on progress, but I can't find any equivalent for webkit / chrome.

EDIT 2014/02/03 :

Chrome has started implementing xhr.responseType "stream"

The "parsing" is landed in Chrome (with the --enable-experimental-webkit-features flag) but the xhr.response resulted object (Stream) is not yet useable directly in Javascript : https://code.google.com/p/chromium/issues/detail?id=240603

EDIT 2014/07/10 :

The spec is now developped : https://github.com/whatwg/streams

Chromium devs plans to "do some prototype without waiting for completion of standardization"

share|improve this question

3 Answers 3

up vote 2 down vote accepted

My guess is that WebKit will get https://dvcs.w3.org/hg/streams-api/raw-file/tip/Overview.htm instead

share|improve this answer
Has any vendor at all implemented this yet? –  abergmeier Mar 8 '13 at 15:40
Congrats @max ogden, you were right ! –  Julien CROUZET Feb 3 at 11:58

Sorry to be the bearer of bad news, but to my knowledge there's not currently a webkit equivalent. Originally the chunked-arraybuffer response type arose from a concern similar to yours:


Additionally, MDN lists the responseType as only available in Firefox:


share|improve this answer

I think the solution to your issue is not having seen the full AudioContext object for html5.


You can decode audio data : decodeAudioData() You can play music via an AudioBuffer that can stream music to you via a web socket or just chunked http streaming.

When you want to play a song you just call the playSound()

So the real answer is use the AudioContext and you'll be golden

share|improve this answer
It COULD be. I was almost there ... 1) You need to remove the extra bytes from Icecast (icy-metadata) 2) decodeAudioData() adds some extra miliseconds of "blank" audio in each buffer which results in a bad quality for the audio –  Julien CROUZET Mar 25 '13 at 15:53

Your Answer


