Computing modular polynomials by deformation