0

I'm working with xamarin.forms.

I need to read an mp3 file and to access to raw bytes[] as I need to performa an FFT (Fast Fourier Transform).

I can read an mp3 using MediaPlayer and a custom MediaDataSource reading bytes by ReadAt method.

Anyway I need the raw pcm16 converted version to manage data correctly.

NAudio is not available as dll are missing.

I need a solution can work both fopr Android and iOS.

Jano
  • 731
  • 7
  • 18
  • unless you can find a cross platform library to do this, you will probably need to do it in each platform and use DependencyService to access it from Forms – Jason Apr 06 '20 at 16:10
  • I'm already using DependencyService. I need to understand the steps to decode mp3 and to convert to pcm. I was not able to find something useful able to access raw converted bytes. I don't need simply to play it, that's easy. – Jano Apr 06 '20 at 16:19
  • there are many existing posts about doing mp3->wav conversion for Android and iOS – Jason Apr 06 '20 at 16:24
  • I have no doubt, if writing here is because I was not able to find a good solution. Would be great to list one of them, in order to help not only me but also other users. – Jano Apr 06 '20 at 16:59
  • You can try to NAudio https://www.nuget.org/packages/NAudio/ , you can refer to this thread about how to use it.https://stackoverflow.com/questions/11446096/converting-mp3-data-to-wav-data-c-sharp – Leon Apr 07 '20 at 07:22
  • As mentioned I tried Naudio from nuget, but always got the error of a missing. dll searching I found some articles saying is not available for mobile. – Jano Apr 07 '20 at 08:31

0 Answers0