Resample image to desired resolution.