# How to iterate video.pixels.length for random area of image

**URL:** <https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367>\
**Category:** Libraries\
**Created:** [October 20, 2022, 4:41am UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367 "2022-10-20T04:41:45Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![doni](https://avatars.discourse-cdn.com/v4/letter/d/a698b9/32.png) [@doni](https://discourse.processing.org/u/doni)\
**Post date:** [October 20, 2022, 4:41am UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/1 "2022-10-20T04:41:45Z")

</div>

assume the image as following top left, rectangular with 4 columns and 5 rows

 ![image](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/3X/9/4/94621d7eae0a319b1f985b1d49f97b029d6a5ef1.png)

how do i iterate within for loop for yellow rectangular (1,2,5,6,9,10,13,14) to fetch rgb values if my array is 1D (bellow rectangular) with following code

```auto
  for(int i = 0; i < posBuffer.pixels.length; i++){
if(blue(posBuffer.pixels[i]) > 0){
  count++;
 avg.add(red(posBuffer.pixels[i]) / 255.0, green(posBuffer.pixels[i]) / 255.0);
}

```

thank you

---

<div class="post-metadata">

**Author:** ![svan](https://avatars.discourse-cdn.com/v4/letter/s/82dd89/32.png) [@svan](https://discourse.processing.org/u/svan)\
**Post date:** [October 20, 2022, 6:12am UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/2 "2022-10-20T06:12:28Z")

</div>

The length of a pixel array is width times height (width\*height). If you want to select out a certain subset of the pixels then the only way that I know of is to reconvert it to a two dimensional array with two ‘for’ loops: one loop for the width and one loop for the height. You appear to be trying to make a two dimensional array fit into a one dimensional array that you have found somewhere.

pixelArray.length = width\*height and you need to take it back to the two dimensional array that it was to start with, then you will be able to select a subset of pixels from the rows and columns:

```auto
final int rows = 5;
final int cols = 4;

int left;
int top;
int id = 1;

void rectGrid(int l, int t, int w, int h, int vg, int hg) {
  for (int k = 0; k < rows; k++) {
    for (int j = 0; j < cols; j++) {
      left = l + j*(w+vg);
      top = t + k*(h+hg);
      stroke(0);
      strokeWeight(2);
      if (j < 2 && k < 4) {
        fill(color(240, 240, 40));
      } else {
        fill(255);
      }
      rect( left, top, w, h);
      fill(0);
      textSize(20);
      textAlign(CENTER, CENTER);
      text(str(id), left, top, w, h);
      id++;
    }
  }
}

void setup() {
  size(720, 600);
  background(255);
  rectGrid(0, 0, width/cols, height/rows, 0, 0);
}

void draw() {
}

```

 ![Screen Shot 2022-10-20 at 1.11.39 AM](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/3X/9/8/98a32f07c6c14309e46ec3eb5400e92cd3b81622.png)

---

<div class="post-metadata">

**Author:** ![doni](https://avatars.discourse-cdn.com/v4/letter/d/a698b9/32.png) [@doni](https://discourse.processing.org/u/doni)\
**Post date:** [October 20, 2022, 7:10am UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/3 "2022-10-20T07:10:44Z")

</div>

following image is the 1D array data i want iterate, i want to iterate 2 index and skip 2 index and repeat continuously until the end of data

 ![image1](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/3X/7/a/7a6d10f8e9dfdf195dbfd5f45c869937d5240df7.png)

---

<div class="post-metadata">

**Author:** ![josephh](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/josephh/32/210_2.png) [@josephh](https://discourse.processing.org/u/josephh)\
**Post date:** [October 20, 2022, 7:42am UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/4 "2022-10-20T07:42:01Z")

</div>

Hi again @doni,

This is linked to your previous post:

> [@How to Iterate over 2D region with 1D pixels array](https://discourse.processing.org/t/how-to-iterate-over-2d-region-with-1d-pixels-array/39336):
>
> the snippet code below is doing color tracking and get the average position and draw circle on it, the screen size (640, 480). how to do iteration in one dimensional array in for loop within part of the screen, for example i want to do tracking/iteration from 0 to 100 of x axis and from 0 to 100 of y axis. thank you PGraphics posBuffer; for(int i = 0; i \< posBuffer.pixels.length; i++){ // encoded so blue is \> 0 if a pixel is within threshold if(blue(posBuffer.pixels[i]) \> 0){ coun…

You should use a nested for loop and compute the 1D index with the `x + y * width` formula.

But it seems that you don’t want to use a nested for loop to iterate over the pixels… (I find it more simple and clear 😉 )

You can do that with a single `while` loop (maybe not the best solution thought):

```processing
int i = 0;
int iterations = 0;

while (i < 14) {
  iterations++;
  
  println(i + 1);
  
  if (iterations % 2 == 0) {
    i += 3;
  } else {
    i += 1;
  }
}

// -> 1 2 5 6 9 10 13 14

```

Or shorter:

```processing
while (i < 14) {
  iterations++;
  println(i + 1);
  i += ((iterations % 2) == 0) ? 3 : 1;
}

```

---

<div class="post-metadata">

**Author:** ![doni](https://avatars.discourse-cdn.com/v4/letter/d/a698b9/32.png) [@doni](https://discourse.processing.org/u/doni)\
**Post date:** [October 20, 2022, 7:58am UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/6 "2022-10-20T07:58:28Z")

</div>

would you like to help me implemented it on this following code

```auto
for(int i = 0; i < posBuffer.pixels.length; i++){
if(blue(posBuffer.pixels[i]) > 0){
  count++;
 avg.add(red(posBuffer.pixels[i]) / 255.0, green(posBuffer.pixels[i]) / 255.0);
}

```

---

<div class="post-metadata">

**Author:** ![josephh](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/josephh/32/210_2.png) [@josephh](https://discourse.processing.org/u/josephh)\
**Post date:** [October 20, 2022, 8:36am UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/7 "2022-10-20T08:36:18Z")

</div>

> [@doni](#):
>
> would you like to help me implemented it on this following code

You should be able to do it yourself, this is not complicated 😉

Ultimately what do you want to do? We gave you two solutions: either use a nested for loop (with `x` and `y`) or a “complicated” while loop.

Up to you to implement it.

---

<div class="post-metadata">

**Author:** ![doni](https://avatars.discourse-cdn.com/v4/letter/d/a698b9/32.png) [@doni](https://discourse.processing.org/u/doni)\
**Post date:** [October 20, 2022, 8:37am UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/8 "2022-10-20T08:37:24Z")

</div>

where 3 come from in this code

```auto
i += 3;

```

where 1 come from as following

```auto
i += 1;

```

---

<div class="post-metadata">

**Author:** ![doni](https://avatars.discourse-cdn.com/v4/letter/d/a698b9/32.png) [@doni](https://discourse.processing.org/u/doni)\
**Post date:** [October 20, 2022, 8:48am UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/9 "2022-10-20T08:48:30Z")

</div>

when i try this its error ArrayIndexOutOfBoundsException: 480, but webcam is turn on but some how its stuck some where

```auto
int [][] PosBuffer = new int [posBuffer.height [posBuffer.width];

  for (int x = 0; x < posBuffer.width ; x++ ) {
      for (int y = 0; y < posBuffer.height; y++ ) { 
     
        if(blue(PosBuffer[x][y]) > 0){
    count++;
     avg.add(red(PosBuffer[x][y]) / 255.0, green(PosBuffer[x][y]) / 255.0);
}
  }
  }

```

when i try this its error ArrayIndexOutOfBoundsException: 1, but webcam is turn on but some how its stuck some where

```auto
int [][] PosBuffer = {{posBuffer.width},{posBuffer.height}};

  for (int x = 0; x < posBuffer.width ; x++ ) {
      for (int y = 0; y < posBuffer.height; y++ ) { 
     
        if(blue(PosBuffer[x][y]) > 0){
    count++;
     avg.add(red(PosBuffer[x][y]) / 255.0, green(PosBuffer[x][y]) / 255.0);
}
  }
  }

```

when i try this its error ArrayIndexOutOfBoundsException: -2147450880 , but webcam is turn on but some how its stuck some where

```auto
for(int i = 0; i < posBuffer.pixels.length ; i+=640){
    for(int j = i; j < i + 100; j++)   
     i = i + j;
   if(blue(posBuffer.pixels[i]) > 0){
  count++;
  avg.add(red(posBuffer.pixels[i]) / 255.0, green(posBuffer.pixels[i]) / 255.0);
   }
}

```

when i try this its error ArrayIndexOutOfBoundsException: 307200, but webcam is turn on but some how its stuck some where

```auto
int i = 0;
int iteration = 0;
while (i < posBuffer.pixels.length){
  iteration++;
  if(iteration % 100 == 0){
    i += 75;
    if(blue(posBuffer.pixels[i]) > 0){
  count++;
  avg.add(red(posBuffer.pixels[i]) / 255.0, green(posBuffer.pixels[i]) / 255.0);   
  }else
  {
      i += 50;
    }
}
}

```

---

<div class="post-metadata">

**Author:** ![svan](https://avatars.discourse-cdn.com/v4/letter/s/82dd89/32.png) [@svan](https://discourse.processing.org/u/svan)\
**Post date:** [October 20, 2022, 9:34am UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/10 "2022-10-20T09:34:20Z")

</div>

The following demo will color a subset range of a webcam image. Note that it uses x + y\*width to get the pixel id:

```auto
import processing.video.*;

Capture cam;

void setup() {
  size(640, 480);
  String[] cameras = Capture.list();
  if (cameras == null) {
    println("Failed to retrieve the list of available cameras, will try the default...");
    cam = new Capture(this, 640, 480);
  } else if (cameras.length == 0) {
    println("There are no cameras available for capture.");
    exit();
  } else {
    println("Available cameras:");
    printArray(cameras);
    cam = new Capture(this, cameras[0]);
  }
  cam.start();
}

void draw() {
  if (cam.available() == true) {
    cam.read();
  }
  image(cam, 0, 0, width, height);
  loadPixels();
  color pink = color(255, 102, 204);
  for (int y = 0; y < height; y++) {
    for (int x = 0; x < width; x++) {
      int id = x + y * width;
      if (x < 100 && y > 240) {
        pixels[id] = pink;
      }
    }
  }
  updatePixels();
}

```

---

<div class="post-metadata">

**Author:** ![doni](https://avatars.discourse-cdn.com/v4/letter/d/a698b9/32.png) [@doni](https://discourse.processing.org/u/doni)\
**Post date:** [October 20, 2022, 9:41am UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/11 "2022-10-20T09:41:51Z")

</div>

actually i succeed to have full control on limitation of x and y data in for loop when using this code

```auto
import processing.video.*;
    Capture video;
    
    float threshold = 210;
    color trackColor; 
    PVector target;
    
    void setup() {
     
    size(640, 480);
    video = new Capture(this, width, height);
    video.start();
     trackColor = color(160,0,0); // Start off tracking for red    
    }
    
    void captureEvent(Capture video) {
    // Read image from the camera
    video.read();
    }
    
    void draw() {
    loadPixels();
    video.loadPixels();
    image(video, 0, 0);
    float avgX = 0;
    float avgY = 0;
     int count = 0;
    
    for (int x = 0; x < video.width && x < 100; x ++ ) {
    for (int y = 240; y < video.height; y ++ ) {
    int loc = x + y*video.width;   
    color currentColor = video.pixels[loc];
    float r1 = red(currentColor);
    float g1 = green(currentColor);
    float b1 = blue(currentColor);
    float r2 = red(trackColor);
    float g2 = green(trackColor);
    float b2 = blue(trackColor);
    
    // Using euclidean distance to compare colors
    float d = distSq(r1, g1, b1, r2, g2, b2);
    if (d < threshold) {
    stroke(255);
    strokeWeight(1);
    point(x,y);
     
    avgX += x;
    avgY += y;
     count++;
    }
    }
    }
    if (count > 0) { 
    avgX = avgX / count;
    avgY = avgY / count;
    // Draw a circle at the tracked pixel
    fill(trackColor);
    strokeWeight(4.0);
    stroke(0);
    ellipse(avgX, avgY, 20, 20);
    text("brightnesslevel: " + trackColor, 20, 60);
    text("FPS: " + frameRate, 20, 80);
    }
    target = new PVector (avgX, avgY);
    }
    
    float distSq(float x1,float y1, float z1, float x2, float y2, float z2){
    float d = (x2-x1)*(x2-x1) + (y2-y1)*(y2-y1) + (z2-z1)*(z2-z1);
    return d;
    }
    
    void mousePressed() {
    // Save color where the mouse is clicked in trackColor variable
    int loc = mouseX + mouseY*video.width;
    trackColor = video.pixels[loc];
    }

```

but fail with this code

```auto
import processing.video.*;
PShader colorFinder, colorPosShader;
PGraphics overlay, posBuffer;
// Variable for capture device
Capture video;

// A variable for the color we are searching for.
color trackColor; 
float threshold = 0.1;

void setup() {
  //size(320, 240);
  size(640, 480, P2D);
  overlay = createGraphics(width, height, P2D);
  posBuffer = createGraphics(width, height, P2D);
  colorFinder = loadShader("colorDetect.glsl");
  colorPosShader = loadShader("colorPos.glsl");
  printArray(Capture.list());
  video = new Capture(this, width, height);
  video.start();
  video.loadPixels();
  // Start off tracking for red
  trackColor = color(255, 0, 0);
}

void captureEvent(Capture video) {
  // Read image from the camera
  video.read();
}

void draw() {
  colorFinder.set("threshold", threshold);
  colorFinder.set("targetColor", red(trackColor) / 255.0, green(trackColor) / 255.0, blue(trackColor) / 255.0, 1.0);
  colorPosShader.set("threshold", threshold);
  colorPosShader.set("targetColor", red(trackColor) / 255.0, green(trackColor) / 255.0, blue(trackColor) / 255.0, 1.0);
  overlay.beginDraw();
  overlay.shader(colorFinder);
  overlay.image(video, 0, 0);
  overlay.endDraw();
  posBuffer.beginDraw();
  posBuffer.shader(colorPosShader);
  posBuffer.image(video, 0, 0);
  posBuffer.endDraw();
  //compute average position by looking at pixels from position buffer
  posBuffer.loadPixels();
  PVector avg = new PVector(0, 0);
  int count = 0;
  for(int i = 0; i < posBuffer.pixels.length; i++){
    // encoded so blue is > 0 if a pixel is within threshold
    if(blue(posBuffer.pixels[i]) > 0){
      count++;
      // processing takes 0-1 (float) color values from shader to 0-255 (int) values for color
      // to decode, we need to divide the color by 255 to get the original value
      avg.add(red(posBuffer.pixels[i]) / 255.0, green(posBuffer.pixels[i]) / 255.0);
    }
  }
  if(count > 0){
    // we have the sum of positions, so divide by the number of additions
    avg.div((float) count);
    // convert 0-1 position to screen position
    avg.x *= width;
    avg.y *= height;
  } else {
    // appear offscreen
    avg = new PVector(-100, -100);
  }
  image(overlay, 0, 0);
  fill(trackColor);
  stroke(0);
  circle(avg.x, avg.y, 16);
  fill(0, 50);
  noStroke();
  rect(0, 0, 150, 30);
  fill(150);
  text("Framerate: " + frameRate, 0, 11);
  text("Threshold: " + threshold, 0, 22);
}

void mousePressed() {
  // Save color where the mouse is clicked in trackColor variable
  video.loadPixels();
  int loc = mouseX + mouseY*video.width;
  trackColor = video.pixels[loc];
}

void mouseWheel(MouseEvent e){
  threshold -= e.getCount() * 0.01;
  threshold = constrain(threshold, 0, 1);
}

```

this is the [link](https://discourse.processing.org/t/realtime-image-processing-using-thread-or-class-extending-thread/30304/14)

---

<div class="post-metadata">

**Author:** ![doni](https://avatars.discourse-cdn.com/v4/letter/d/a698b9/32.png) [@doni](https://discourse.processing.org/u/doni)\
**Post date:** [October 20, 2022, 9:47am UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/12 "2022-10-20T09:47:42Z")

</div>

all “ArrayIndexOutOfBoundsException: n” errors come from this line

```auto
if(blue(PosBuffer[x][y]) > 0)

```

---

<div class="post-metadata">

**Author:** ![svan](https://avatars.discourse-cdn.com/v4/letter/s/82dd89/32.png) [@svan](https://discourse.processing.org/u/svan)\
**Post date:** [October 20, 2022, 10:00am UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/13 "2022-10-20T10:00:32Z")

</div>

The pixels are changing rapidly in realtime video. Using x + y\*width to get pixel id inside of nested for loops seems to work without array overruns.

---

<div class="post-metadata">

**Author:** ![doni](https://avatars.discourse-cdn.com/v4/letter/d/a698b9/32.png) [@doni](https://discourse.processing.org/u/doni)\
**Post date:** [October 20, 2022, 10:04am UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/14 "2022-10-20T10:04:42Z")

</div>

if you don mind try the second code combined with glsl which is GPU pararel processing, i faced difficulties when tried to do limitation over pixels.length within second code for loop

---

<div class="post-metadata">

**Author:** ![svan](https://avatars.discourse-cdn.com/v4/letter/s/82dd89/32.png) [@svan](https://discourse.processing.org/u/svan)\
**Post date:** [October 20, 2022, 1:30pm UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/15 "2022-10-20T13:30:37Z")

</div>

The following runs without crashing on my system:

```auto
 for (int y = 0; y < posBuffer.height; y++) {
    for (int x = 0; x < posBuffer.width; x++) {
      int id = x + y * width;
      // encoded so blue is > 0 if a pixel is within threshold
      if (blue(posBuffer.pixels[id]) > 0) {
        count++;
        // processing takes 0-1 (float) color values from shader to 0-255 (int) values for color
        // to decode, we need to divide the color by 255 to get the original value
        avg.add(red(posBuffer.pixels[id]) / 255.0, green(posBuffer.pixels[id]) / 255.0);
      }
    }

```

---

<div class="post-metadata">

**Author:** ![doni](https://avatars.discourse-cdn.com/v4/letter/d/a698b9/32.png) [@doni](https://discourse.processing.org/u/doni)\
**Post date:** [October 20, 2022, 1:37pm UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/16 "2022-10-20T13:37:43Z")

</div>

```auto
 for (int y = 0; y < posBuffer.height; y++) {
    for (int x = 0; x < posBuffer.width && x < 100; x++) {
      int id = x + y * width;
      // encoded so blue is > 0 if a pixel is within threshold
      if (blue(posBuffer.pixels[id]) > 0) {
        count++;
        // processing takes 0-1 (float) color values from shader to 0-255 (int) values for color
        // to decode, we need to divide the color by 255 to get the original value
        avg.add(red(posBuffer.pixels[id]) / 255.0, green(posBuffer.pixels[id]) / 255.0);
      }
    }

```

when i limit iteration in x axis the sampled pixel and circle still drawn even in area over 100 of x axis. its different with first code it could limit the circle movement and drawn sampled color according to limitation value stated in iteration

```auto
for (int x = 0; x < video.width && x < 100; x ++ ) {
    for (int y = 240; y < video.height; y ++ )

```

 ![processing color tracking](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/3X/e/c/ec20d25183558aee2693a76224a13e24939dbb94.jpeg)

if i move the yellow paper beyond limit value stated in iteration the white and the circle wont be drawn

---

<div class="post-metadata">

**Author:** ![svan](https://avatars.discourse-cdn.com/v4/letter/s/82dd89/32.png) [@svan](https://discourse.processing.org/u/svan)\
**Post date:** [October 20, 2022, 1:58pm UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/17 "2022-10-20T13:58:49Z")

</div>

Is this what you are trying to do?

```auto
  for (int y = 0; y < posBuffer.height; y++) {
    for (int x = 0; x < posBuffer.width; x++) {
      int id = x + y * width;
      if (x < 100 && y > 240) {
      // encoded so blue is > 0 if a pixel is within threshold
      if (blue(posBuffer.pixels[id]) > 0) {
        count++;
        // processing takes 0-1 (float) color values from shader to 0-255 (int) values for color
        // to decode, we need to divide the color by 255 to get the original value
        avg.add(red(posBuffer.pixels[id]) / 255.0, green(posBuffer.pixels[id]) / 255.0);
      }
      }
    }
  }

```

---

<div class="post-metadata">

**Author:** ![doni](https://avatars.discourse-cdn.com/v4/letter/d/a698b9/32.png) [@doni](https://discourse.processing.org/u/doni)\
**Post date:** [October 20, 2022, 2:06pm UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/18 "2022-10-20T14:06:40Z")

</div>

wow nearly! the circle jailed in this value `if (x < 100 && y > 240)` but the sampled color still drawn beyond that x and y value

---

<div class="post-metadata">

**Author:** ![svan](https://avatars.discourse-cdn.com/v4/letter/s/82dd89/32.png) [@svan](https://discourse.processing.org/u/svan)\
**Post date:** [October 20, 2022, 2:11pm UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/19 "2022-10-20T14:11:36Z")

</div>

> the sampled color still drawn beyond that x and y value

If you don’t want to sample beyond x \< 100 and y \> 240 then you’ve got to limit where the mouse traps clicks. I’ve shown you this code previously. The last post of this thread:[https://discourse.processing.org/t/how-to-iterate-over-2d-region-with-1d-pixels-array/39336/23](https://discourse.processing.org/t/how-to-iterate-over-2d-region-with-1d-pixels-array/39336/23)

One change would be to not use the counter but use the most recent code that was posted above; ie, use id = x + y\*width.

---

<div class="post-metadata">

**Author:** ![doni](https://avatars.discourse-cdn.com/v4/letter/d/a698b9/32.png) [@doni](https://discourse.processing.org/u/doni)\
**Post date:** [October 20, 2022, 2:13pm UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/20 "2022-10-20T14:13:41Z")

</div>

i am so sorry not noticed it. OK i should check ti

---

<div class="post-metadata">

**Author:** ![doni](https://avatars.discourse-cdn.com/v4/letter/d/a698b9/32.png) [@doni](https://discourse.processing.org/u/doni)\
**Post date:** [October 20, 2022, 2:33pm UTC](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367/21 "2022-10-20T14:33:03Z")

</div>

still the same brother, why i insist my self to use code with glsl is because its faster than the first code.

[Next page](https://discourse.processing.org/t/how-to-iterate-video-pixels-length-for-random-area-of-image/39367.md?page=2)
