Detection and classification of vehicles are the most challenging tasks of a video-based intelligent transportation system. Traditional detection and classification methods are based on subtraction of estimated still backgrounds from a video to find out the moving objects. In general, these methods are computationally highly expensive, and in many cases show poor detection and classification performance, especially when differences between pixel intensities of vehicles and backgrounds are small. In this paper, we present a novel detection and classification method that employs an analysis of time-spatial image (TSI) obtained from a virtual line on the frames of a video so that the dependencies of pixel intensities of still and moving objects of the video may be reduced. First, the TSI is segmented to count the number of vehicles those cross the virtual line. Then, a feature-based classification scheme is proposed to classify these vehicles. The classification scheme utilizes the shape of the segmented regions of the TSI as well as that of appropriate frames of a video to extract the certain features of the moving objects. Experimental results on a number of real video sequences demonstrate that the proposed method provides higher accuracy in counting and classifying the vehicles as compared to that of the conventional background subtraction-based methods.