Decoding mp3 file

1k views Asked by At

Can any one tell me that how to decode mp3 file.
I want to decode mp3 file likewise any media player but my work is to decode and read its specific characteristics.
Can I use NAudio for this purpose?
Now what I need is RAWDATA of the mp3 file.

4

There are 4 answers

0
Irfan Aslam On BEST ANSWER

Use this method bits[index] you can access

e.g

BitArray bits = new BitArray(FrameByteArray);
Console.Write(bits[59]);
2
Alex Paven On

See http://msdn.microsoft.com/en-us/library/system.collections.bitarray.get.aspx

BitArray.Get Method: Gets the value of the bit at a specific position in the BitArray.

0
AudioBubble On
bool value = bits[149];

Remember that the index is zero-based.

MSDN documentation

2
Justin Niessner On

The BitArray class definitely defines an indexer, so you shouldn't have any problem getting the value using bits[149]. That value will be a bool rather than an int though, so you have to check it against true/false rather than 1/0.