Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1463)

Side by Side Diff: webrtc/modules/rtp_rtcp/source/rtp_format_h264.cc

Issue 2999063002: Add flag enabling more packets to be retransmittable. (Closed)
Patch Set: Addressed comments Created 3 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2014 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2014 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 371 matching lines...) Expand 10 before | Expand all | Expand 10 after
382 uint8_t* buffer = 382 uint8_t* buffer =
383 rtp_packet->AllocatePayload(kFuAHeaderSize + fragment.length); 383 rtp_packet->AllocatePayload(kFuAHeaderSize + fragment.length);
384 buffer[0] = fu_indicator; 384 buffer[0] = fu_indicator;
385 buffer[1] = fu_header; 385 buffer[1] = fu_header;
386 memcpy(buffer + kFuAHeaderSize, fragment.buffer, fragment.length); 386 memcpy(buffer + kFuAHeaderSize, fragment.buffer, fragment.length);
387 if (packet->last_fragment) 387 if (packet->last_fragment)
388 input_fragments_.pop_front(); 388 input_fragments_.pop_front();
389 packets_.pop(); 389 packets_.pop();
390 } 390 }
391 391
392 ProtectionType RtpPacketizerH264::GetProtectionType() {
393 return kProtectedPacket;
394 }
395
396 StorageType RtpPacketizerH264::GetStorageType(
397 uint32_t retransmission_settings) {
398 return kAllowRetransmission;
399 }
400
401 std::string RtpPacketizerH264::ToString() { 392 std::string RtpPacketizerH264::ToString() {
402 return "RtpPacketizerH264"; 393 return "RtpPacketizerH264";
403 } 394 }
404 395
405 RtpDepacketizerH264::RtpDepacketizerH264() : offset_(0), length_(0) {} 396 RtpDepacketizerH264::RtpDepacketizerH264() : offset_(0), length_(0) {}
406 RtpDepacketizerH264::~RtpDepacketizerH264() {} 397 RtpDepacketizerH264::~RtpDepacketizerH264() {}
407 398
408 bool RtpDepacketizerH264::Parse(ParsedPayload* parsed_payload, 399 bool RtpDepacketizerH264::Parse(ParsedPayload* parsed_payload,
409 const uint8_t* payload_data, 400 const uint8_t* payload_data,
410 size_t payload_data_length) { 401 size_t payload_data_length) {
(...skipping 257 matching lines...) Expand 10 before | Expand all | Expand 10 after
668 h264->packetization_type = kH264FuA; 659 h264->packetization_type = kH264FuA;
669 h264->nalu_type = original_nal_type; 660 h264->nalu_type = original_nal_type;
670 if (first_fragment) { 661 if (first_fragment) {
671 h264->nalus[h264->nalus_length] = nalu; 662 h264->nalus[h264->nalus_length] = nalu;
672 h264->nalus_length = 1; 663 h264->nalus_length = 1;
673 } 664 }
674 return true; 665 return true;
675 } 666 }
676 667
677 } // namespace webrtc 668 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/modules/rtp_rtcp/source/rtp_format_h264.h ('k') | webrtc/modules/rtp_rtcp/source/rtp_format_video_generic.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698