Yes! Very complex.

But, for the code

for(int x=1 ; x<width-1; x++) {

// inspect neighbouring bits in current row

int pix1 = (get(x-1,y)&1)<<2; // gives 100 if x-1 on, else 000

int pix2 = (get(x,y)&1)<<1; // gives 010 if x on, else 000

int pix3 = (get(x+1,y)&1); // gives 001 if x+1 on, else 000

this is a 1D, 3-bit cellular automata