A method of detecting an object on a road side, the method comprising: a step of obtaining a disparity map of a scene containing the object; a step of obtaining a sequence of disparity cross-sectional views corresponding to disparities or disparity ranges according to a big-to-small order of the disparities, wherein, each of the disparity cross-sectional views is a disparity map cross-sectional generated by all disparity points corresponding to a predetermined disparity or a predetermined disparity range; a step of extracting from the disparity cross-sectional views vertical line segments whose heights satisfy a predetermined range; and a step of recognizing the object comprising: mapping the top end points and the bottom end points of the extracted vertical line segments to an image, carrying out a straight line fit with respect to the top end points to determine the presence of a first straight line covering most of the top end points in the image, and carrying out a straight line fit with respect to the bottom end points to determine the presence of a second straight line covering most of the bottom end points in the image, and indicating the presence of the object if said two straight lines are determined to be present, wherein the object appears in the sequence of disparity cross-sectional views as a plurality of vertical line segments whose change in position and height in adjacent disparity cross-sectional views is below a predetermined threshold. a step of obtaining a disparity map of a scene containing the object; a step of obtaining a sequence of disparity cross-sectional views corresponding to disparities or disparity ranges according to a big-to-small order of the disparities, wherein, each of the disparity cross-sectional views is a disparity map cross-sectional generated by all disparity points corresponding to a predetermined disparity or a predetermined disparity range; a step of extracting from the disparity cross-sectional views vertical line segments whose heights satisfy a predetermined range; and a step of recognizing the object comprising: mapping the top end points and the bottom end points of the extracted vertical line segments to an image, carrying out a straight line fit with respect to the top end points to determine the presence of a first straight line covering most of the top end points in the image, and carrying out a straight line fit with respect to the bottom end points to determine the presence of a second straight line covering most of the bottom end points in the image, and indicating the presence of the object if said two straight lines are determined to be present, mapping the top end points and the bottom end points of the extracted vertical line segments to an image, carrying out a straight line fit with respect to the top end points to determine the presence of a first straight line covering most of the top end points in the image, and carrying out a straight line fit with respect to the bottom end points to determine the presence of a second straight line covering most of the bottom end points in the image, and indicating the presence of the object if said two straight lines are determined to be present, wherein the object appears in the sequence of disparity cross-sectional views as a plurality of vertical line segments whose change in position and height in adjacent disparity cross-sectional views is below a predetermined threshold.