How to force pixels to hit the screen?
mike at plan99.net
Wed May 21 07:43:16 UTC 2014
> Would that runLater() code always run after the splash image was finished
> being rendered?
Unfortunately I tried this and it doesn't work.
JavaFX has a dual threaded architecture in which all app logic and scene
graph handling happens on the app thread, and the process of drawing a
frame actually just pushes commands onto a render thread which then does
the work of translating into OpenGL or DirectX or whatever the underlying
rendering engine is. Exactly what that data stream looks like I'm not sure,
but my guess as to what is happening (didn't profile it yet) is that my app
does lots of stuff during startup (including starting other threads,
networking events, etc) and the OS doesn't know that the Prism render
thread is special, so it doesn't get scheduled with higher priority vs the
If there was a way to synchronize with the render thread, that would work,
and if there was a way to make the render thread higher priority than the
rest, that might also work. But I'm not enough of a guru (yet) to know the
best way to do this.
More information about the openjfx-dev