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

Side by Side Diff: webrtc/pc/rtcstatscollector.cc

Issue 2607933002: RTCMediaStreamTrackStats.framesDropped collected by RTCStatsCollector. (Closed)
Patch Set: Rebase with master after webrtc/api renamed to webrtc/pc Created 3 years, 11 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
« no previous file with comments | « webrtc/pc/rtcstats_integrationtest.cc ('k') | webrtc/pc/rtcstatscollector_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2016 The WebRTC Project Authors. All rights reserved. 2 * Copyright 2016 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 427 matching lines...) Expand 10 before | Expand all | Expand 10 after
438 video_receiver_info.frame_width); 438 video_receiver_info.frame_width);
439 video_track_stats->frame_height = static_cast<uint32_t>( 439 video_track_stats->frame_height = static_cast<uint32_t>(
440 video_receiver_info.frame_height); 440 video_receiver_info.frame_height);
441 } 441 }
442 video_track_stats->frames_received = video_receiver_info.frames_received; 442 video_track_stats->frames_received = video_receiver_info.frames_received;
443 // TODO(hbos): When we support receiving simulcast, this should be the total 443 // TODO(hbos): When we support receiving simulcast, this should be the total
444 // number of frames correctly decoded, independent of which SSRC it was 444 // number of frames correctly decoded, independent of which SSRC it was
445 // received from. Since we don't support that, this is correct and is the same 445 // received from. Since we don't support that, this is correct and is the same
446 // value as "RTCInboundRTPStreamStats.framesDecoded". crbug.com/659137 446 // value as "RTCInboundRTPStreamStats.framesDecoded". crbug.com/659137
447 video_track_stats->frames_decoded = video_receiver_info.frames_decoded; 447 video_track_stats->frames_decoded = video_receiver_info.frames_decoded;
448 RTC_DCHECK_GE(video_receiver_info.frames_received,
449 video_receiver_info.frames_rendered);
450 video_track_stats->frames_dropped = video_receiver_info.frames_received -
451 video_receiver_info.frames_rendered;
448 return video_track_stats; 452 return video_track_stats;
449 } 453 }
450 454
451 void ProduceMediaStreamAndTrackStats( 455 void ProduceMediaStreamAndTrackStats(
452 int64_t timestamp_us, 456 int64_t timestamp_us,
453 const TrackMediaInfoMap& track_media_info_map, 457 const TrackMediaInfoMap& track_media_info_map,
454 rtc::scoped_refptr<StreamCollectionInterface> streams, 458 rtc::scoped_refptr<StreamCollectionInterface> streams,
455 bool is_local, 459 bool is_local,
456 RTCStatsReport* report) { 460 RTCStatsReport* report) {
457 // TODO(hbos): When "AddTrack" is implemented we should iterate tracks to 461 // TODO(hbos): When "AddTrack" is implemented we should iterate tracks to
(...skipping 760 matching lines...) Expand 10 before | Expand all | Expand 10 after
1218 const std::string& type) { 1222 const std::string& type) {
1219 return CandidateTypeToRTCIceCandidateType(type); 1223 return CandidateTypeToRTCIceCandidateType(type);
1220 } 1224 }
1221 1225
1222 const char* DataStateToRTCDataChannelStateForTesting( 1226 const char* DataStateToRTCDataChannelStateForTesting(
1223 DataChannelInterface::DataState state) { 1227 DataChannelInterface::DataState state) {
1224 return DataStateToRTCDataChannelState(state); 1228 return DataStateToRTCDataChannelState(state);
1225 } 1229 }
1226 1230
1227 } // namespace webrtc 1231 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/pc/rtcstats_integrationtest.cc ('k') | webrtc/pc/rtcstatscollector_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698