I am currently working on implementing spectrogram and the input to it are output from FFT. The results which I am getting is very pixelated. To make the output more smooth, I need to implement bilinear interpolation.
Is there any library or API readily available for it?
I found a function samplingLinear() in CoreImage which samples an image using bilinear interpolation. However, I need to interpolate the FFT data instead of an image.
Any help will be greatly appreciated.Spectrogram_Sample
Thanks.
Assuming you're displaying the data via OpenGL/CoreAnimation/UIImageView, you should do the interpolation there.
E.g. if you're displaying the data via a
CALayer
, you can set themagnificationFilter
tokCAFilterLinear
. If you're using OpenGL, you can setGL_TEXTURE_MAG_FILTER
toGL_LINEAR
.