You can add a grabber sample to the chart after the mp3 decoder. The grabber sample allows you to set up a callback that is called when each sample passes through the media pipeline.
Your chart will look something like this:
mp3 file -> mp3 decoder -> sample grabber -> renderer
Raalf source share