| 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 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 83 ~OveruseFrameDetector(); | 83 ~OveruseFrameDetector(); |
| 84 | 84 |
| 85 // Called for each captured frame. | 85 // Called for each captured frame. |
| 86 void FrameCaptured(const VideoFrame& frame); | 86 void FrameCaptured(const VideoFrame& frame); |
| 87 | 87 |
| 88 // Called for each sent frame. | 88 // Called for each sent frame. |
| 89 void FrameSent(uint32_t timestamp); | 89 void FrameSent(uint32_t timestamp); |
| 90 | 90 |
| 91 // Implements Module. | 91 // Implements Module. |
| 92 int64_t TimeUntilNextProcess() override; | 92 int64_t TimeUntilNextProcess() override; |
| 93 void Process() override; | 93 int32_t Process() override; |
| 94 | 94 |
| 95 private: | 95 private: |
| 96 class SendProcessingUsage; | 96 class SendProcessingUsage; |
| 97 struct FrameTiming { | 97 struct FrameTiming { |
| 98 FrameTiming(int64_t capture_ntp_ms, uint32_t timestamp, int64_t now) | 98 FrameTiming(int64_t capture_ntp_ms, uint32_t timestamp, int64_t now) |
| 99 : capture_ntp_ms(capture_ntp_ms), | 99 : capture_ntp_ms(capture_ntp_ms), |
| 100 timestamp(timestamp), | 100 timestamp(timestamp), |
| 101 capture_ms(now), | 101 capture_ms(now), |
| 102 last_send_ms(-1) {} | 102 last_send_ms(-1) {} |
| 103 int64_t capture_ntp_ms; | 103 int64_t capture_ntp_ms; |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 158 std::list<FrameTiming> frame_timing_ GUARDED_BY(crit_); | 158 std::list<FrameTiming> frame_timing_ GUARDED_BY(crit_); |
| 159 | 159 |
| 160 rtc::ThreadChecker processing_thread_; | 160 rtc::ThreadChecker processing_thread_; |
| 161 | 161 |
| 162 RTC_DISALLOW_COPY_AND_ASSIGN(OveruseFrameDetector); | 162 RTC_DISALLOW_COPY_AND_ASSIGN(OveruseFrameDetector); |
| 163 }; | 163 }; |
| 164 | 164 |
| 165 } // namespace webrtc | 165 } // namespace webrtc |
| 166 | 166 |
| 167 #endif // WEBRTC_VIDEO_OVERUSE_FRAME_DETECTOR_H_ | 167 #endif // WEBRTC_VIDEO_OVERUSE_FRAME_DETECTOR_H_ |
| OLD | NEW |