Image convolution in javascript.