To accurately construct the topographic information of a six-legged walking robot in real time, this study proposes a stereo matching algorithm that can conduct disparity estimation on each pixel by using the Bayesian posterior probability model based on GPU-accelerated parallel processing. In the proposed algorithm, supporting points construct a disparity space to obtain the prior distribution probability density of each pixel and then substitute it into the Bayesian posterior probability model to establish the energy function of the disparity. The estimated disparity value of the unknown pixel can be obtained by minimizing the energy function. By performing a consistency check on the left and right sides of an image, the mismatching pixel can be eliminated. According to the disparity value of the supporting point, the disparity filling of the mismatching area can be achieved by applying the adaptive weight method on the basis of cross extending to obtain the accurate density of the disparity map. Parallel computing in each stage of the proposed algorithm is performed by using the compute unified device architecture to reduce the running time. Experimental results show that the proposed algorithm has good robustness for different illuminations and texture curved surface reconstruction. The algorithm can also adapt to the fast matching of images in different sizes and reconstruct the disparity map of scenes in real time under the resolution ratio of 640 x 480. The stereoscopic vision test board is employed to construct the disparity map of real scenes and verify the practical application effect of the algorithm. Good experiment effect is achieved. (C) 2015 Elsevier B.V. All rights reserved.