| 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 |
| 11 #ifndef WEBRTC_VIDEO_SEND_STATISTICS_PROXY_H_ | 11 #ifndef WEBRTC_VIDEO_SEND_STATISTICS_PROXY_H_ |
| 12 #define WEBRTC_VIDEO_SEND_STATISTICS_PROXY_H_ | 12 #define WEBRTC_VIDEO_SEND_STATISTICS_PROXY_H_ |
| 13 | 13 |
| 14 #include <string> | 14 #include <string> |
| 15 | 15 |
| 16 #include "webrtc/base/criticalsection.h" | 16 #include "webrtc/base/criticalsection.h" |
| 17 #include "webrtc/base/exp_filter.h" |
| 17 #include "webrtc/base/ratetracker.h" | 18 #include "webrtc/base/ratetracker.h" |
| 18 #include "webrtc/base/scoped_ptr.h" | 19 #include "webrtc/base/scoped_ptr.h" |
| 19 #include "webrtc/base/thread_annotations.h" | 20 #include "webrtc/base/thread_annotations.h" |
| 20 #include "webrtc/common_types.h" | 21 #include "webrtc/common_types.h" |
| 21 #include "webrtc/modules/video_coding/include/video_codec_interface.h" | 22 #include "webrtc/modules/video_coding/include/video_codec_interface.h" |
| 22 #include "webrtc/modules/video_coding/include/video_coding_defines.h" | 23 #include "webrtc/modules/video_coding/include/video_coding_defines.h" |
| 23 #include "webrtc/system_wrappers/include/clock.h" | 24 #include "webrtc/system_wrappers/include/clock.h" |
| 24 #include "webrtc/video_engine/overuse_frame_detector.h" | 25 #include "webrtc/video_engine/overuse_frame_detector.h" |
| 25 #include "webrtc/video_engine/vie_encoder.h" | 26 #include "webrtc/video_engine/vie_encoder.h" |
| 26 #include "webrtc/video_send_stream.h" | 27 #include "webrtc/video_send_stream.h" |
| (...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 126 VideoSendStream::StreamStats* GetStatsEntry(uint32_t ssrc) | 127 VideoSendStream::StreamStats* GetStatsEntry(uint32_t ssrc) |
| 127 EXCLUSIVE_LOCKS_REQUIRED(crit_); | 128 EXCLUSIVE_LOCKS_REQUIRED(crit_); |
| 128 | 129 |
| 129 Clock* const clock_; | 130 Clock* const clock_; |
| 130 const VideoSendStream::Config config_; | 131 const VideoSendStream::Config config_; |
| 131 mutable rtc::CriticalSection crit_; | 132 mutable rtc::CriticalSection crit_; |
| 132 VideoEncoderConfig::ContentType content_type_ GUARDED_BY(crit_); | 133 VideoEncoderConfig::ContentType content_type_ GUARDED_BY(crit_); |
| 133 VideoSendStream::Stats stats_ GUARDED_BY(crit_); | 134 VideoSendStream::Stats stats_ GUARDED_BY(crit_); |
| 134 uint32_t last_sent_frame_timestamp_ GUARDED_BY(crit_); | 135 uint32_t last_sent_frame_timestamp_ GUARDED_BY(crit_); |
| 135 std::map<uint32_t, StatsUpdateTimes> update_times_ GUARDED_BY(crit_); | 136 std::map<uint32_t, StatsUpdateTimes> update_times_ GUARDED_BY(crit_); |
| 137 rtc::ExpFilter encode_time_ GUARDED_BY(crit_); |
| 136 | 138 |
| 137 // Contains stats used for UMA histograms. These stats will be reset if | 139 // Contains stats used for UMA histograms. These stats will be reset if |
| 138 // content type changes between real-time video and screenshare, since these | 140 // content type changes between real-time video and screenshare, since these |
| 139 // will be reported separately. | 141 // will be reported separately. |
| 140 struct UmaSamplesContainer { | 142 struct UmaSamplesContainer { |
| 141 explicit UmaSamplesContainer(const char* prefix); | 143 explicit UmaSamplesContainer(const char* prefix); |
| 142 ~UmaSamplesContainer(); | 144 ~UmaSamplesContainer(); |
| 143 | 145 |
| 144 void UpdateHistograms(); | 146 void UpdateHistograms(); |
| 145 | 147 |
| (...skipping 14 matching lines...) Expand all Loading... |
| 160 SampleCounter max_delay_counter_; | 162 SampleCounter max_delay_counter_; |
| 161 rtc::RateTracker input_frame_rate_tracker_; | 163 rtc::RateTracker input_frame_rate_tracker_; |
| 162 rtc::RateTracker sent_frame_rate_tracker_; | 164 rtc::RateTracker sent_frame_rate_tracker_; |
| 163 }; | 165 }; |
| 164 | 166 |
| 165 rtc::scoped_ptr<UmaSamplesContainer> uma_container_ GUARDED_BY(crit_); | 167 rtc::scoped_ptr<UmaSamplesContainer> uma_container_ GUARDED_BY(crit_); |
| 166 }; | 168 }; |
| 167 | 169 |
| 168 } // namespace webrtc | 170 } // namespace webrtc |
| 169 #endif // WEBRTC_VIDEO_SEND_STATISTICS_PROXY_H_ | 171 #endif // WEBRTC_VIDEO_SEND_STATISTICS_PROXY_H_ |
| OLD | NEW |