lioncash/droidsound — comment on commit 05f8b7f9eb82ba238ffee0859d4d3508eeae930b
File:  line 0
By alankila:

Lioncash kirjoitti 9.2.2012 kello 6.01:

> I realize that every format in this library will practically have to resample to 44100Hz. As the library itself does not do this, and considering the fact that my knowledge in upsampling and downsampling is practically zero, I have no idea on how I'd implement this. Any thoughts?

Let android do it. It will use high-quality sinc resampled internally to do the work. Here's how:

1) Add a method in plugin that returns the sample rate of the audio stream.

2) Make async package player query the plugin's frequency, and then passes that. It's currently just a static constant.

3) VisualizationView also needs it (it has the frequency halved somewhere, 22050). It can just get that from OverlappingFFT.Data which is the container class used to pass FFT data. The variable frameRate already exists there, so you can just add that.

--
Antti