# Processing Mp3

**URL:** <https://forum.juce.com/t/processing-mp3/9676>\
**Category:** General JUCE discussion\
**Created:** [December 10, 2012, 3:04pm UTC](https://forum.juce.com/t/processing-mp3/9676 "2012-12-10T15:04:39Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Shlomi](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/shlomi/32/99_2.png) [@Shlomi](https://forum.juce.com/u/Shlomi)\
**Post date:** [December 10, 2012, 3:04pm UTC](https://forum.juce.com/t/processing-mp3/9676/1 "2012-12-10T15:04:39Z")

</div>

Hello

When I’m creating an AudioFormatReader to an MP3 file the manager returns a reader with format name “Windows Media” and not “MP3”, is that ok (tried many files)?

Then for cropping purposes I read it into an AudioSampleBuffer and then I’m writing it to a memory stream with WavAudioFormat::createWriterFor  
but it returns null because the bitsPerSample is 0 (reader-\>bitsPerSample from the original reader)

Am I doing something wrong? (am I doing something right?)

Thank you

---

<div class="post-metadata">

**Author:** ![jules](https://avatars.discourse-cdn.com/v4/letter/j/41988e/32.png) [@jules](https://forum.juce.com/u/jules)\
**Post date:** [December 10, 2012, 9:56pm UTC](https://forum.juce.com/t/processing-mp3/9676/2 "2012-12-10T21:56:17Z")

</div>

You can use the MP3AudioFormat class directly if you want it to have a go at opening the file before the Windows Media codec. Strange that the WM one fails to read it though, I’m pretty sure it works on my machine.
