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

Side by Side Diff: webrtc/modules/video_coding/main/source/jitter_buffer.cc

Issue 1328113004: Work on flexible mode and screen sharing. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Spatial layers when screensharing. Created 5 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) 2012 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2012 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 #include "webrtc/modules/video_coding/main/source/jitter_buffer.h" 10 #include "webrtc/modules/video_coding/main/source/jitter_buffer.h"
(...skipping 577 matching lines...) Expand 10 before | Expand all | Expand 10 after
588 << " consecutive old packets received. Flushing the jitter buffer."; 588 << " consecutive old packets received. Flushing the jitter buffer.";
589 Flush(); 589 Flush();
590 return kFlushIndicator; 590 return kFlushIndicator;
591 } 591 }
592 return kOldPacket; 592 return kOldPacket;
593 } 593 }
594 594
595 if (packet.codec == kVideoCodecVP9) { 595 if (packet.codec == kVideoCodecVP9) {
596 // TODO(asapersson): Move this code to appropriate place. 596 // TODO(asapersson): Move this code to appropriate place.
597 // TODO(asapersson): Handle out of order GOF. 597 // TODO(asapersson): Handle out of order GOF.
598 if (packet.codecSpecificHeader.codecHeader.VP9.flexible_mode) {
599 // TODO(asapersson): Add support for flexible mode.
600 return kGeneralError;
601 }
602 if (packet.codecSpecificHeader.codecHeader.VP9.ss_data_available) { 598 if (packet.codecSpecificHeader.codecHeader.VP9.ss_data_available) {
603 if (!last_gof_valid_ || 599 if (!last_gof_valid_ ||
604 IsNewerTimestamp(packet.timestamp, last_gof_timestamp_)) { 600 IsNewerTimestamp(packet.timestamp, last_gof_timestamp_)) {
605 last_gof_.CopyGofInfoVP9( 601 last_gof_.CopyGofInfoVP9(
606 packet.codecSpecificHeader.codecHeader.VP9.gof); 602 packet.codecSpecificHeader.codecHeader.VP9.gof);
607 last_gof_timestamp_ = packet.timestamp; 603 last_gof_timestamp_ = packet.timestamp;
608 last_gof_valid_ = true; 604 last_gof_valid_ = true;
609 } 605 }
610 } 606 }
611 if (last_gof_valid_ && 607 if (last_gof_valid_ &&
(...skipping 641 matching lines...) Expand 10 before | Expand all | Expand 10 after
1253 } 1249 }
1254 // Evaluate if the RTT is higher than |high_rtt_nack_threshold_ms_|, and in 1250 // Evaluate if the RTT is higher than |high_rtt_nack_threshold_ms_|, and in
1255 // that case we don't wait for retransmissions. 1251 // that case we don't wait for retransmissions.
1256 if (high_rtt_nack_threshold_ms_ >= 0 && 1252 if (high_rtt_nack_threshold_ms_ >= 0 &&
1257 rtt_ms_ >= high_rtt_nack_threshold_ms_) { 1253 rtt_ms_ >= high_rtt_nack_threshold_ms_) {
1258 return false; 1254 return false;
1259 } 1255 }
1260 return true; 1256 return true;
1261 } 1257 }
1262 } // namespace webrtc 1258 } // namespace webrtc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698