From d94987cbce9014ba43511d3db4e5fc358e4dfb5b Mon Sep 17 00:00:00 2001 From: Jakub Valtar Date: Wed, 12 Apr 2017 18:57:35 +0200 Subject: [PATCH] pixelDensity (OpenGL): fix 2x on Windows --- core/src/processing/opengl/PSurfaceJOGL.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/src/processing/opengl/PSurfaceJOGL.java b/core/src/processing/opengl/PSurfaceJOGL.java index d67c9632f..381900a00 100644 --- a/core/src/processing/opengl/PSurfaceJOGL.java +++ b/core/src/processing/opengl/PSurfaceJOGL.java @@ -953,8 +953,8 @@ public class PSurfaceJOGL implements PSurface { public void reshape(GLAutoDrawable drawable, int x, int y, int w, int h) { pgl.resetFBOLayer(); pgl.getGL(drawable); - window.getCurrentSurfaceScale(currentPixelScale); - setSize((int) (w / currentPixelScale[0]), (int) (h / currentPixelScale[1])); + float scale = getPixelScale(); + setSize((int) (w / scale), (int) (h / scale)); } }