We consider the problem of the grid generation for a generic compact connected domain Ω of the two-dimensional real Euclidean space. This problem can be seen as a finite dimensional version of the extension of a given parameterization of the boundary of Ω to a parameterization of the whole domain Ω. We describe the direct method, where the grid generation problem is reformulated as an optimization problem, and two different modifications of this method. We present a large number of numerical results on standard test problems. From these results we can see that the new version has higher accuracy and lower computational cost than the usual version of the direct method for the grid generation problem.