Skip to content

Commit ad2e009

Browse files
authored
Merge pull request #590 from hx2A/fix-linux-issue
Fix linux KDE issue
2 parents 3025016 + c3cc3fd commit ad2e009

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

py5_jar/src/main/java/py5/core/Sketch.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -259,6 +259,11 @@ public void draw() {
259259
if (success && preDrawUpdateRunner != null && !py5RegisteredEvents.contains("post_draw")) {
260260
preDrawUpdateRunner.interrupt();
261261
}
262+
263+
if (frameCount == 1 && platform == LINUX && g.isGL()) {
264+
// Linux with KDE Plasma window manager and OpenGL need to capture pixels after the last draw() call
265+
capturePixels();
266+
}
262267
}
263268

264269
protected void preDrawUpdate() {

0 commit comments

Comments
 (0)