Issues with Panel.repaint() and Panel.repaintImmediately() - laggy user interface
-
Hi everyone :-)
When I use
repaint()orrepaintImmediately()- for example, in a timer callback to create an animation - the user interface quickly becomes very laggy if the panel is somewhat large. The Cubase interface also becomes very laggy.Does anyone have any ideas on how I can solve this problem? I already tried using a background task, but it didn’t work - or maybe I did it wrong. :-)
Thanks a lot,
Oli -
@Oli-Ullmann said in Issues with Panel.repaint() and Panel.repaintImmediately() - laggy user interface:
Does anyone have any ideas on how I can solve this problem?
Drop the animation, ain't nobody looking at your sexy UI anyway.
Seriously though, I find users add the plugin to their project, set up some parameter (or more likely load a preset) then close the interface. Animations that aren't functional are just a way to use up some extra CPU. Since Juce6 isn't using the GPU for drawing, your framerate is limited unless you're using shaders.
-
@David-Healey
Ha ha ha
I was afraid this wouldn't be an easy task...If I want to use shaders, I need to enable OpenGL, right? But I've heard that this isn't supported on Mac anymore. Or am I mistaken?
-
@Oli-Ullmann said in Issues with Panel.repaint() and Panel.repaintImmediately() - laggy user interface:
If I want to use shaders, I need to enable OpenGL, right? But I've heard that this isn't supported on Mac anymore. Or am I mistaken?
I have no idea, as you can probably tell from my response, I don't use animations on my UIs (yet)

-
@David-Healey
Ha ha, that makes sense! :-)
Thanks anyway for your reply! :-)