I am searching a way to get the bitrate and duration from a audio stream in C# on Windows Phone 7 platform.
First, I, tried to get it by calculate using formula (let's say that i can have duration of stream, that i am going to download as number)
bitrate = ((((filesize)/duration)/1024)*8)
I can download the audio (mp3) in stream from webclient and store or play it but i want to check for some rules first, for theese rules i need the bitrate that i can calculate without duration and bytes using some kind of formula as the audio stream may has variable bitrate and deeper calculations will be wrong.
Also sometimes, a part of the stream is downloaded within the app, so i do not have the full filesize and duration, so the bitrate is not right calculated, so i need a sure way.
So how can i get bitrate or duration from a stream using some function of Windows Phone 7 framework without actualy play it?