when using AudioAppComponent, the methods paint and getNextAudioBlock are called by the same thread. When my application is painting a lot of stuff, audio has a huge latency. I guess it is possible to separate painting and audio processing into two different threads, Unfortunately I could not find any resources on how this is done with JUCE. Could someone please give me a hint how I can do this?
Unless it’s some platform specific issue, the GUI and audio are already run in different threads…
Maybe some CriticalSection/mutex/MessageManagerLock is attempted to be locked during both your paint and getNextAudioBlock methods? That could make it appear like the execution is happening in one thread.