JUCE 7 repainting bug?!

Part of the problem is that the sync isn’t explicitly managed by JUCE, but by the OS.

OpenGL rendering will flush frames after the [renderContext flushBuffer] call (not necessarily synchronously) (juce_OpenGL_osx.h:173).

The GL view will resize after [view setFrame:] is called on it (juce_mac_NSViewComponent.mm:70). Again, this doesn’t trigger a synchronous redraw, so the actual paint will happen at some point in the future.

Finally, non-OpenGL JUCE views are painted during the drawRect callback from the OS (juce_mac_NSViewComponentPeer.mm:891).

1 Like