The technology of streaming media is more and more widely used in the field of Internet. By streaming media, we can playback the movie while downloading without downloading the whole video. The media formats of wmv, rm, flv are the main media formats. In order to unify digital media storage format, MPEG drafted MP4 file format, named as Information technology coding of audio-visual objects Part 12: ISO base media file format. MP4 file format is an open container. Almost all media can be contained in a MP4 file. The media data and metadata is stored separately. The organization of a media file is unrestricted, not necessary to be arranged in sequence. The media data can even be the URL outside the file. MP4 is widely used to store H.264 encoded video and AAC encoded audio, which is a representation of HD video.A highly efficient streaming scheme of MP4 file is proposed by this paper. Considering that streaming is a process to fetch video and audio synchronously, the offsets of video and audio samples need to be calculated. If we calculate the offset frame by frame, the computation load is very high. We propose a pre-processing scheme, by which the offsets of each frame are calculated and stored in an array, so that there is no need to calculate the offset again when streaming. As a result, the streaming process can be speed up.Transferring the calculation of offsets from server to client is another feature of our scheme. For a traditional streaming system, the work is performed on server, and the workload of streaming server is very high. The workload is distributed to clients by our scheme. Therefore, more users can be served by the same server.This paper also presents the schemes of synchronization of audio and video frames, Internet protocols, such as HTTP, RTSP and stream media rendering module based on DirectX technology. Two different schemes are provided in some modules. By analyzing and comparing the advantage and disadvantage of each scheme, this paper eventually selects the scheme based on HTTP and DirectX technology to complete the development of MP4 streaming system. Finally this paper analyzes and compares the experiment results and draws a conclusion based on the experiments. In the scheme MP4 file can be streamed efficiently, the performance of media play using DirectX is very good, and HTTP protocol is more suitable for this system. |