(int wide, int high)
| 122 | |
| 123 | |
| 124 | @Override |
| 125 | public void setSize(int wide, int high) { |
| 126 | if (PApplet.DEBUG) { |
| 127 | //System.out.format("frame visible %b, setSize(%d, %d) %n", frame.isVisible(), wide, high); |
| 128 | new Exception(String.format("setSize(%d, %d)", wide, high)).printStackTrace(System.out); |
| 129 | } |
| 130 | |
| 131 | //if (wide == sketchWidth && high == sketchHeight) { // doesn't work on launch |
| 132 | if (wide == sketch.width && high == sketch.height) { |
| 133 | if (PApplet.DEBUG) { |
| 134 | new Exception("w/h unchanged " + wide + " " + high).printStackTrace(System.out); |
| 135 | } |
| 136 | return; // unchanged, don't rebuild everything |
| 137 | } |
| 138 | |
| 139 | //throw new RuntimeException("implement me, see readme.md"); |
| 140 | sketch.width = wide; |
| 141 | sketch.height = high; |
| 142 | |
| 143 | // set PGraphics variables for width/height/pixelWidth/pixelHeight |
| 144 | graphics.setSize(wide, high); |
| 145 | } |
| 146 | |
| 147 | |
| 148 | // public void initImage(PGraphics graphics) { |
no test coverage detected