OLD | NEW |
---|---|
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 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
102 for (size_t i = 0; i < extensions.size(); ++i) { | 102 for (size_t i = 0; i < extensions.size(); ++i) { |
103 ss << extensions[i].ToString(); | 103 ss << extensions[i].ToString(); |
104 if (i != extensions.size() - 1) | 104 if (i != extensions.size() - 1) |
105 ss << ", "; | 105 ss << ", "; |
106 } | 106 } |
107 ss << ']'; | 107 ss << ']'; |
108 ss << '}'; | 108 ss << '}'; |
109 return ss.str(); | 109 return ss.str(); |
110 } | 110 } |
111 | 111 |
112 std::string VideoReceiveStream::Stats::ToString(int64_t time_ms) const { | |
113 std::stringstream ss; | |
114 ss << "VideoReceiveStream stats:" << time_ms << ",{ssrc:" << ssrc << ","; | |
115 ss << "[tot_bps:" << total_bitrate_bps << "],"; | |
pbos-webrtc
2016/07/10 16:58:51
Remove []s unless this format is from somewhere. A
åsapersson
2016/08/01 15:55:22
Done.
| |
116 ss << "[w:" << width << "],"; | |
117 ss << "[h:" << height << "],"; | |
118 ss << "[network_fps:" << network_frame_rate << "],"; | |
119 ss << "[dec_fps:" << decode_frame_rate << "],"; | |
120 ss << "[render_fps:" << render_frame_rate << "],"; | |
121 ss << "[dec_ms:" << decode_ms << "],"; | |
122 ss << "[max_dec_ms:" << max_decode_ms << "],"; | |
123 ss << "[cur_delay_ms:" << current_delay_ms << "],"; | |
124 ss << "[targ_delay_ms:" << target_delay_ms << "],"; | |
125 ss << "[jb_delay_ms:" << jitter_buffer_ms << "],"; | |
126 ss << "[min_playout_delay_ms:" << min_playout_delay_ms << "],"; | |
127 ss << "[discarded:" << discarded_packets << "]"; | |
128 ss << '}'; | |
129 return ss.str(); | |
130 } | |
131 | |
112 namespace { | 132 namespace { |
113 VideoCodec CreateDecoderVideoCodec(const VideoReceiveStream::Decoder& decoder) { | 133 VideoCodec CreateDecoderVideoCodec(const VideoReceiveStream::Decoder& decoder) { |
114 VideoCodec codec; | 134 VideoCodec codec; |
115 memset(&codec, 0, sizeof(codec)); | 135 memset(&codec, 0, sizeof(codec)); |
116 | 136 |
117 codec.plType = decoder.payload_type; | 137 codec.plType = decoder.payload_type; |
118 strncpy(codec.plName, decoder.payload_name.c_str(), sizeof(codec.plName)); | 138 strncpy(codec.plName, decoder.payload_name.c_str(), sizeof(codec.plName)); |
119 if (decoder.payload_name == "VP8") { | 139 if (decoder.payload_name == "VP8") { |
120 codec.codecType = kVideoCodecVP8; | 140 codec.codecType = kVideoCodecVP8; |
121 } else if (decoder.payload_name == "VP9") { | 141 } else if (decoder.payload_name == "VP9") { |
(...skipping 237 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
359 const std::vector<uint16_t>& sequence_numbers) { | 379 const std::vector<uint16_t>& sequence_numbers) { |
360 rtp_stream_receiver_.RequestPacketRetransmit(sequence_numbers); | 380 rtp_stream_receiver_.RequestPacketRetransmit(sequence_numbers); |
361 } | 381 } |
362 | 382 |
363 void VideoReceiveStream::RequestKeyFrame() { | 383 void VideoReceiveStream::RequestKeyFrame() { |
364 rtp_stream_receiver_.RequestKeyFrame(); | 384 rtp_stream_receiver_.RequestKeyFrame(); |
365 } | 385 } |
366 | 386 |
367 } // namespace internal | 387 } // namespace internal |
368 } // namespace webrtc | 388 } // namespace webrtc |
OLD | NEW |