Mercurial > libavformat.hg
comparison rtpenc.c @ 5842:cc35562d3747 libavformat
Use AVFormatContext.start_time_realtime in the RTP muxer
author | mstorsjo |
---|---|
date | Mon, 15 Mar 2010 10:37:12 +0000 |
parents | f4ca0041b4f4 |
children | 7028f9476da4 |
comparison
equal
deleted
inserted
replaced
5841:ba41d3865253 | 5842:cc35562d3747 |
---|---|
84 s->timestamp = s->base_timestamp; | 84 s->timestamp = s->base_timestamp; |
85 s->cur_timestamp = 0; | 85 s->cur_timestamp = 0; |
86 s->ssrc = 0; /* FIXME: was random(), what should this be? */ | 86 s->ssrc = 0; /* FIXME: was random(), what should this be? */ |
87 s->first_packet = 1; | 87 s->first_packet = 1; |
88 s->first_rtcp_ntp_time = ff_ntp_time(); | 88 s->first_rtcp_ntp_time = ff_ntp_time(); |
89 if (s1->start_time_realtime) | |
90 /* Round the NTP time to whole milliseconds. */ | |
91 s->first_rtcp_ntp_time = (s1->start_time_realtime / 1000) * 1000 + | |
92 NTP_OFFSET_US; | |
89 | 93 |
90 max_packet_size = url_fget_max_packet_size(s1->pb); | 94 max_packet_size = url_fget_max_packet_size(s1->pb); |
91 if (max_packet_size <= 12) | 95 if (max_packet_size <= 12) |
92 return AVERROR(EIO); | 96 return AVERROR(EIO); |
93 s->buf = av_malloc(max_packet_size); | 97 s->buf = av_malloc(max_packet_size); |