Chromium Code Reviews| Index: webrtc/modules/rtp_rtcp/source/rtp_sender_video.cc |
| diff --git a/webrtc/modules/rtp_rtcp/source/rtp_sender_video.cc b/webrtc/modules/rtp_rtcp/source/rtp_sender_video.cc |
| index 3f4c401a19d5c43ff9f64c6a9e3bd14d60ff9fb6..b9434b266a521906b6599ce2b1be00d96fe2c9ac 100644 |
| --- a/webrtc/modules/rtp_rtcp/source/rtp_sender_video.cc |
| +++ b/webrtc/modules/rtp_rtcp/source/rtp_sender_video.cc |
| @@ -304,6 +304,7 @@ bool RTPSenderVideo::SendVideo(RtpVideoCodecTypes video_type, |
| auto last_packet = rtc::MakeUnique<RtpPacketToSend>(*rtp_header); |
| size_t fec_packet_overhead; |
| + bool is_timing_frame = false; |
| bool red_enabled; |
| int32_t retransmission_settings; |
| { |
| @@ -332,6 +333,11 @@ bool RTPSenderVideo::SendVideo(RtpVideoCodecTypes video_type, |
| last_packet->SetExtension<VideoContentTypeExtension>( |
| video_header->content_type); |
| } |
| + if (video_header->video_timing.is_timing_frame) { |
| + last_packet->SetExtension<VideoTimingExtension>( |
| + video_header->video_timing); |
| + is_timing_frame = true; |
| + } |
| } |
| // FEC settings. |
| @@ -388,6 +394,11 @@ bool RTPSenderVideo::SendVideo(RtpVideoCodecTypes video_type, |
| if (!rtp_sender_->AssignSequenceNumber(packet.get())) |
| return false; |
| + // Put packetization finish timestamp into extension; |
|
åsapersson
2017/06/12 14:33:42
nit end with.
ilnik
2017/06/13 08:43:13
Done.
|
| + if (last && is_timing_frame) { |
|
åsapersson
2017/06/12 14:33:42
Can HasExtension be used instead of is_timing_fram
ilnik
2017/06/13 08:43:13
Yes, but they are set together at lines 337-339 ex
|
| + packet->set_packetization_finish_time_ms(clock_->TimeInMilliseconds()); |
| + } |
| + |
| const bool protect_packet = |
| (packetizer->GetProtectionType() == kProtectedPacket); |
| if (flexfec_enabled()) { |