RealAlexZ / MultiMeter

A comprehensive set of AU/VST real-time audio analysis tools in one window implemented with JUCE 6.
GNU General Public License v3.0
28 stars 1 forks source link

Validation fix for PluginManager in newer LPX and macOS meters fix #3

Open JohnKesko opened 7 months ago

JohnKesko commented 7 months ago

Hey, great plugin! Thanks :)

I cloned the repo and ran it in LPX 10.8.1 (newest) but it crashed in the validation:

1 Channel Test: Render Test at 512 frames JUCE Assertion failure in PluginProcessor.h:177 JUCE Assertion failure in juce_AudioSampleBuffer.h:255 validation result: crashed validation

So I went into debug mode and found that in validation, (at least in LPX newer versions), we need to check for a stereo channel, otherwise just set it to mono.


Then for the rendering of the meters on macOS. I found that the buffer for the FIFO in PluginProcessor.h wasn't either pushed or pulled, it was was always empty so it didn't have anything to render, this fixes that.

Then the Goniometer::update was never called anywhere so I placed it in the timerCallback passing the buffer. Hope that's reasonble.

Last, when I changed the buffer size in AUAudioFilePlayer in AudioPluginHost to something smaller than 256, neither Histogram or Goniometer didn't render anything. However, I found you had an if-statement to render specifics for that. I guess you have some great ideas for it but I removed it since it didn't make much sense. Also in the Goniometer::update method, I changed it up to dynamically resize the internalBuffer to whatever the host is using.

RealAlexZ commented 7 months ago

Hi John - I am so sorry for the late reply! I am in college, and the past week has been quite a hectic one for me. I will definitely make sure to take a good look at your well-organized comments and suggestions, and get back to you later this week! Thank you so much for testing my code and trying to debug it - I really appreciate it!