Note that there are some explanatory texts on larger screens.

plurals
  1. POGetting hiccup noise from Shoutcast
    primarykey
    data
    text
    <p>I'm trying to read Shoutcast stream and then play it using MediaStreamSource. Here is the excellent open source <a href="http://shoutstreamsource.codeplex.com/" rel="nofollow">project</a> that saved lot of my time. After little bit modification I'm able to hear perfect sound. But the problem is I'm getting a periodic blip/hiccup kind of noise.</p> <p>Any idea how I can stop that noise. I thought its may be Shoutcast sends some metadata in interval but don't find out how to stop that. Tried with <code>request.Headers["Icy-MetaData"] = "0";</code> But it doesn't fix my problem either. Any help will be greatly appreciated.</p> <p><strong>Edit1:</strong> I did some more investigation. I read my stream data for 2-3 mins and found that there are lot of 'zero' byte in that stream. Here is the list of index of '0' byte</p> <p>92 247 359 1208 1904 2037 2227 2397 2536 2694 2740 2863 2952 3048 3110 3689 3994 4027 4098 4218 4730 4830 4943 5029 5115 5248 5315 5358 5666 6084 6375 6873 6920 7441 7660 7700 7756 8174 8254 8614 9010 9018 9025 9039 9541 9846..... </p> <p>Is it because httpwebrequest slow download/failed to download or Shoutcast itself sending those zero bytes? Also does this '0' bytes causing that hiccup noise?</p> <p><strong>Edit2:</strong> Here is few line of code of how I'm getting response from shoutcast</p> <pre><code> HttpWebRequest request = result.AsyncState as HttpWebRequest; HttpWebResponse response = request.EndGetResponse(result) as HttpWebResponse; r = response.GetResponseStream(); ShoutcastHeader(r); </code></pre> <p>And here is my ShoutcastHeader method definition:</p> <pre><code> StreamReader headerReader = new StreamReader(r); bool headerIsDone = false; while (!headerIsDone) { string headerLine = headerReader.ReadLine(); if (headerLine.StartsWith("icy-name:")) { StationName = headerLine.Substring(9); } else if (headerLine.StartsWith("icy-genre:")) { Genre = headerLine.Substring(10); } else if (headerLine.StartsWith("icy-br:")) { BitRate = short.Parse(headerLine.Substring(7)); } else if (headerLine.StartsWith("icy-metaint:")) { MetaInt = int.Parse(headerLine.Substring(12)) * 1111084; MetadataAvailable = true; } else if (headerLine.Equals("")) headerIsDone = true; } </code></pre> <p>And here is the response in headerReader</p> <p>ICY 200 OK icy-notice1:<BR>This stream requires <a href="http://www.winamp.com/" rel="nofollow">Winamp</a><BR> icy-notice2:SHOUTcast Distributed Network Audio Server/Linux v1.9.93atdn<BR> icy-name:Bollywood &amp; Beyond - Radio NRI 24/7 icy-genre:Indian Hindi Tamil Telugu Malayalam Desi icy-url:http://www.radionri.com content-type:audio/mpeg icy-pub:1 icy-br:128</p> <p>Also I have places the stream bytes in my skydrive share <a href="https://skydrive.live.com/redir.aspx?cid=22d64e162daa62ac&amp;resid=22D64E162DAA62AC!401&amp;parid=22D64E162DAA62AC!101&amp;authkey=!AMFWJABokydEmeM" rel="nofollow">location</a>.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload