-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Open
Description
The following code works on OS X, but on the Raspberry Pi (GLES2 driver), the background doesn't accumulate over multiple frames. The call that triggers this is background()
on an offscreen PGraphics object. It works fine without. @codeanticode Any ideas?
PGraphics pg;
void setup() {
size(200, 200, P2D);
pg = createGraphics(200, 200, P2D);
background(0);
}
void draw() {
// this shouldn't be required either, separate bug
if (frameCount == 1) {
background(0);
}
pg.beginDraw();
pg.background(255, 0, 0);
pg.endDraw();
noStroke();
fill(255);
rect(frameCount, height/2-5, 10, 10);
}