Given a space curve, to design a surface with it as a geodesic is in urgent need of garment manufacture and shoe making industry. The existing research proposed to construct a surface pencil with the curve as a common geodesic, and then specify the final surface among them by fitting scanned data. Such a method highly depends on surface parameterization and representation, and gives no consideration to surface fairness, which is important in practice. According to the material characteristic of garment and the designing concept, this paper provides a new method to specify the final surface in an energy optimization way. It first changes the representation of the surface pencil, so as to establish a relation between the free variable and the surface expression. After that, it introduces a proper energy function, and then determines the optimization surface by solving the minimum energy equation. In this way, global smoothness is realized. The authors also consider surface modification with different constraints such as interpolating or fitting some points or curves. Experiments show that the new method can simulate the garment modeling and processing efficiently and effectively. The method provided is especially applicable and useful in CAD/CAM.