Added loopOverPix() function witch probably will be better designed later.