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

Side by Side Diff: webrtc/video_send_stream.h

Issue 2133073002: Add periodic logging of video stats. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: rebase, address comments Created 4 years, 4 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) 2013 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2013 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 23 matching lines...) Expand all
34 // externally to make sure that any old frames are not delivered concurrently. 34 // externally to make sure that any old frames are not delivered concurrently.
35 virtual void IncomingCapturedFrame(const VideoFrame& video_frame) = 0; 35 virtual void IncomingCapturedFrame(const VideoFrame& video_frame) = 0;
36 36
37 protected: 37 protected:
38 virtual ~VideoCaptureInput() {} 38 virtual ~VideoCaptureInput() {}
39 }; 39 };
40 40
41 class VideoSendStream { 41 class VideoSendStream {
42 public: 42 public:
43 struct StreamStats { 43 struct StreamStats {
44 std::string ToString() const;
45
44 FrameCounts frame_counts; 46 FrameCounts frame_counts;
45 int width = 0; 47 int width = 0;
46 int height = 0; 48 int height = 0;
47 // TODO(holmer): Move bitrate_bps out to the webrtc::Call layer. 49 // TODO(holmer): Move bitrate_bps out to the webrtc::Call layer.
48 int total_bitrate_bps = 0; 50 int total_bitrate_bps = 0;
49 int retransmit_bitrate_bps = 0; 51 int retransmit_bitrate_bps = 0;
50 int avg_delay_ms = 0; 52 int avg_delay_ms = 0;
51 int max_delay_ms = 0; 53 int max_delay_ms = 0;
52 StreamDataCounters rtp_stats; 54 StreamDataCounters rtp_stats;
53 RtcpPacketTypeCounter rtcp_packet_type_counts; 55 RtcpPacketTypeCounter rtcp_packet_type_counts;
54 RtcpStatistics rtcp_stats; 56 RtcpStatistics rtcp_stats;
55 }; 57 };
56 58
57 struct Stats { 59 struct Stats {
60 std::string ToString(int64_t time_ms) const;
58 std::string encoder_implementation_name = "unknown"; 61 std::string encoder_implementation_name = "unknown";
59 int input_frame_rate = 0; 62 int input_frame_rate = 0;
60 int encode_frame_rate = 0; 63 int encode_frame_rate = 0;
61 int avg_encode_time_ms = 0; 64 int avg_encode_time_ms = 0;
62 int encode_usage_percent = 0; 65 int encode_usage_percent = 0;
63 int target_media_bitrate_bps = 0; 66 int target_media_bitrate_bps = 0;
64 int media_bitrate_bps = 0; 67 int media_bitrate_bps = 0;
65 bool suspended = false; 68 bool suspended = false;
66 bool bw_limited_resolution = false; 69 bool bw_limited_resolution = false;
67 std::map<uint32_t, StreamStats> substreams; 70 std::map<uint32_t, StreamStats> substreams;
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after
184 187
185 virtual Stats GetStats() = 0; 188 virtual Stats GetStats() = 0;
186 189
187 protected: 190 protected:
188 virtual ~VideoSendStream() {} 191 virtual ~VideoSendStream() {}
189 }; 192 };
190 193
191 } // namespace webrtc 194 } // namespace webrtc
192 195
193 #endif // WEBRTC_VIDEO_SEND_STREAM_H_ 196 #endif // WEBRTC_VIDEO_SEND_STREAM_H_
OLDNEW
« webrtc/video/video_receive_stream.cc ('K') | « webrtc/video_receive_stream.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698