Control Opacity Via Output

Is there a way to control the Opacity of an image or Alpha Channel from an output buffer.

Thanks for any help with this.

Cheers,

In your audio callback you could do your analysis the buffer (e.g., get its magnitude or RMS or whatever) and then store that in an atomic float member in your processor. Then use a timer callback in your editor to read the atomic float and update the UI.

You would probably want to smooth the value over time that your write to the value from the processor as you will definitely miss some values in the UI and it would otherwise look glitchy and noncontinuous. Have a look at how JUCE measures the CPU usage (AudioProcessLoadMeasurer class), which also takes into account the number of samples used in the analysis as part of that smoothing process.

Thanks for the quick reply. Seems a bit far off for me at the moment. Still having issues with automation and slider smoothing which take precedence I was just curious if it was possible. I Couldn’t find anything on the Forums…Does doing something like this affect CPU usage in a drastic way. I might just drop some of the cool GUI things I wanted to implement. All the best.