From f7dc181bbe9ecd9b5988f76740b11c806801ccfe Mon Sep 17 00:00:00 2001 From: Ben Fry Date: Fri, 11 Oct 2013 20:37:19 -0400 Subject: [PATCH] textureMode(REPEAT) throws an error (#2052) --- core/src/processing/core/PGraphics.java | 3 +++ core/todo.txt | 2 ++ 2 files changed, 5 insertions(+) diff --git a/core/src/processing/core/PGraphics.java b/core/src/processing/core/PGraphics.java index dc47a2c6c..8ec72c89d 100644 --- a/core/src/processing/core/PGraphics.java +++ b/core/src/processing/core/PGraphics.java @@ -1224,6 +1224,9 @@ public class PGraphics extends PImage implements PConstants { * @see PGraphics#textureWrap(int) */ public void textureMode(int mode) { + if (mode != IMAGE && mode != NORMAL) { + throw new RuntimeException("textureMode() only supports IMAGE and NORMAL"); + } this.textureMode = mode; } diff --git a/core/todo.txt b/core/todo.txt index 329e82178..43fcad9c1 100644 --- a/core/todo.txt +++ b/core/todo.txt @@ -36,6 +36,8 @@ X child SVG elements misplaced when rendering with P2D/P3D X https://github.com/processing/processing/issues/2086 X SUBTRACT and DIFFERENCE blend modes are swapped X https://github.com/processing/processing/issues/2075 +X throw an error for textureMode(REPEAT) [fry] +X https://github.com/processing/processing/issues/2052 _ Sort out blending differences with P2D/P3D _ https://github.com/processing/processing/issues/1844