Description
I am working with some rather large WAVs/MP3s which I am trying to generate small waveform graphics for. This is working. However the MP3s are 50x slower to process and render than the wav files are.
I thought it might be something I am doing wrong, but even the demo project on here is considerably slower when working with the large MP3s compared to working with the even larger WAVs. By large, I mean the MPs are 100mb to 200mb and the WAVs are 500mb to 1gb.
I've narrowed the performance problem down to this one line in the SamplingPeakProvider:
int num = base.Provider.Read(base.ReadBuffer, 0, base.ReadBuffer.Length);
Each call to this is taking on average 0.1 seconds per call on the MP3 files, resulting in it taking 15 to 20 seconds to process the file and render the waveform.
That same line on WAV files is taking 0.002 seconds.
I am unsure of how to improve the performance in the demo to get comparable speeds (or at least go from 50x slower to only 5x slower).
Activity