Zhentan Feng <spyfeng gmail com> as part of Google's Summer of Code program. Originally committed as revision 24861 to svn://svn.ffmpeg.org/ffmpeg/trunk