Where to get the data for metering?


#1

Where do I extract the data for metering (like VU meters) for audio?

I had a look at the audio callback on AudioDeviceManager but I'm slightly confused - the input channel is the microphone, I believe, the output channel is... what? Always seems to be empty, and the recommendation is to fill it with zeroes?


#2

Well it will be empty when the callback starts, you need to fill it with whatever should be sent to the outputs.

What data you need to examine for metering will depend on what you actually want to meter. If it's just the master output then examine your main audioDeviceIOCallback after you've sent the buffers off to your sources to be filled.


#3

Ahah!

"after you've sent the buffers off to your sources"...

I changed the order I added the callback:

  • the metering callback
  • the source callback

Now I can see the metering!