OSDN Git Service

rtsp/rtpdec: Set the AVStream time_base directly in rtsp when it is known
authorMartin Storsjö <martin@martin.st>
Tue, 7 Dec 2010 13:29:44 +0000 (13:29 +0000)
committerMartin Storsjö <martin@martin.st>
Tue, 7 Dec 2010 13:29:44 +0000 (13:29 +0000)
commit86b6e387cc16f873d2739af14f63696b648e0423
treec4abe3caeeda5c55d800a00093f0afc5222476c4
parentbb776f3b0037b4ddc2977643fb0efaeff756babc
rtsp/rtpdec: Set the AVStream time_base directly in rtsp when it is known

This fixes cases where the RTP time base and the sample rate of the stream
differ. Previously, the AVStream time_base was unconditionally set to
the sample rate (which initially was set to one value when parsing the
rtpmap field in the SDP, but later overridden by an a=SampleRate field).

Additionally, this makes the code actually use the stream time base set
in rtpmap for video codecs, instead of hardcoding it to always be 90 kHz.

Originally committed as revision 25908 to svn://svn.ffmpeg.org/ffmpeg/trunk
libavformat/rtpdec.c
libavformat/rtsp.c