In this paper, we propose a direct method for 3D surface reconstruction from stereo images. We reconstruct a 3D surface by estimating all depths of the vertices of a mesh composed of piecewise triangular patches on the reference (template) image. The analyses described in this paper subsume that the deformation of the mesh between the stereo images is specified by homographies, each of which represents the deformation of a single patch. The homography deforms each patch which has 3 d.o.f under epipolar constraints. We first formulate a fast "direct" method for estimating the three parameters of a 3D plane by incorporating inverse compositional expression into the sum of squared differences (SSD) function of two stereo images. This method is about eight times faster than the conventional method. Then we extend the direct method to the estimation of the vertex depths in the mesh for reconstructing piecewise-planar surfaces. The validity of the proposed method is demonstrated through results of experiments using synthetic and real images.