mirror of
https://github.com/processing/processing4.git
synced 2026-02-02 13:21:07 +01:00
moving the OpenGL examples to the core
This commit is contained in:
15
java/examples/OpenGL/Pixels/UpdatePixels/UpdatePixels.pde
Normal file
15
java/examples/OpenGL/Pixels/UpdatePixels/UpdatePixels.pde
Normal file
@@ -0,0 +1,15 @@
|
||||
void setup() {
|
||||
size(400, 400, P3D);
|
||||
|
||||
background(0);
|
||||
loadPixels();
|
||||
}
|
||||
|
||||
void draw() {
|
||||
for (int i = 0; i < pixels.length; i++) {
|
||||
pixels[i] = color(random(255), random(255), random(255));
|
||||
}
|
||||
updatePixels();
|
||||
|
||||
println(frameRate);
|
||||
}
|
||||
Reference in New Issue
Block a user