split color to layers, compute local distance for each pixel. don't care about pixel interpolation