In Juce-Teapot “OpenGL Demo” the rotation needs a time-dependent factor, if not the rotation is very uneven on new MacBook Pros M1 Max, because it has an adaptive frame-rate, here is the fix
auto now=Time::getMillisecondCounterHiRes();
if (! controlsOverlay->isMouseButtonDownThreadsafe())
rotation += (float) (rotationSpeed * ((now-lastTime) * 60. / 1000.));
lastTime=now;
This patch includes the benchmark functionality which was proposed by @attila
time_factor_in_rotation_and_benchmark.patch.zip (2.5 KB)
So here is the interesting part:
If I run the benchmark, it shows acceptable values.
But the animation is still stuttering (If you look at it physically) , which will be more visible if you have do some something like a scrolling-waveform.
The same code (as also the teapot-time) runs very smooth on my 9 year old retina-macbook pro.
I have this confirmed multiple times. So my customers with latest hardware generation have the worst results :-/
If would be cool, if someone form the juce-team can confirm this and run the tea-pot demo on the new MacBook Pro M1 Max (latest tip, with the fix) and look physically on it.
I have seen quite smooth animation from other plugin-vendors, so I hope there is still room for improvement with OpenGL in JUCE on Apple M1 Max.