My Problem is to get ACTUAL DATA of a mp3 frame. For this I have used NAudio and get RawData but I think in the RawData property, it returns all the bytes of the frame including header and side information.
Code is given below:
private void button1_Click(object sender, EventArgs e)
{
Mp3FileReader reader = new Mp3FileReader("file.mp3");
Mp3Frame mp3Frame = reader.ReadNextFrame();
byte [] FrameByteArray = mp3Frame.RawData;
BitArray bits = new BitArray(FrameByteArray);
Console.Write(mp3Frame.RawData.Length);
foreach (bool b in bits)
{
if (b == true)
{
Console.Write(" 1");
}
else
{
Console.Write(" 0");
}
}
reader.Close();
}
it returns all frame data in bits including header and side information. But I only need actual data of every frame without header and side information.
Can anyone help??