modify bilinear interpolation