width = 100 height = 100 pixels = {} for x = 0, width-1 do for y = 0, height-1 do pixels[y*width+x+1] = {x/100.0, y/100.0, 0.3} end end