From 8f04bfb45212b49d7fe02cba3a60b59a41318d67 Mon Sep 17 00:00:00 2001 From: codeanticode Date: Sat, 28 May 2011 05:45:27 +0000 Subject: [PATCH] Fixed issue 624 on android --- android/core/src/processing/core/PGraphicsAndroid3D.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/android/core/src/processing/core/PGraphicsAndroid3D.java b/android/core/src/processing/core/PGraphicsAndroid3D.java index 949fb640c..dcd6dea99 100644 --- a/android/core/src/processing/core/PGraphicsAndroid3D.java +++ b/android/core/src/processing/core/PGraphicsAndroid3D.java @@ -5677,11 +5677,13 @@ public class PGraphicsAndroid3D extends PGraphics { this.setCache(a3d, texture); this.setParams(a3d, params); + // The texture crop should also take into account + // the Y inversion, this is why using hight and -height. texCrop = new int[4]; texCrop[0] = 0; - texCrop[1] = 0; + texCrop[1] = height; texCrop[2] = width; - texCrop[3] = height; + texCrop[3] = -height; } }