OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2015 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 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
89 std::list<FeedbackPacket*>* feedbacks, | 89 std::list<FeedbackPacket*>* feedbacks, |
90 Packets* generated); | 90 Packets* generated); |
91 | 91 |
92 VideoSource* source_; | 92 VideoSource* source_; |
93 rtc::scoped_ptr<BweSender> bwe_; | 93 rtc::scoped_ptr<BweSender> bwe_; |
94 int64_t start_of_run_ms_; | 94 int64_t start_of_run_ms_; |
95 std::list<Module*> modules_; | 95 std::list<Module*> modules_; |
96 | 96 |
97 private: | 97 private: |
98 uint32_t previous_sending_bitrate_; | 98 uint32_t previous_sending_bitrate_; |
99 DISALLOW_COPY_AND_ASSIGN(VideoSender); | 99 RTC_DISALLOW_COPY_AND_ASSIGN(VideoSender); |
100 }; | 100 }; |
101 | 101 |
102 class PacedVideoSender : public VideoSender, public PacedSender::Callback { | 102 class PacedVideoSender : public VideoSender, public PacedSender::Callback { |
103 public: | 103 public: |
104 PacedVideoSender(PacketProcessorListener* listener, | 104 PacedVideoSender(PacketProcessorListener* listener, |
105 VideoSource* source, | 105 VideoSource* source, |
106 BandwidthEstimatorType estimator); | 106 BandwidthEstimatorType estimator); |
107 virtual ~PacedVideoSender(); | 107 virtual ~PacedVideoSender(); |
108 | 108 |
109 void RunFor(int64_t time_ms, Packets* in_out) override; | 109 void RunFor(int64_t time_ms, Packets* in_out) override; |
(...skipping 12 matching lines...) Expand all Loading... |
122 | 122 |
123 private: | 123 private: |
124 int64_t TimeUntilNextProcess(const std::list<Module*>& modules); | 124 int64_t TimeUntilNextProcess(const std::list<Module*>& modules); |
125 void CallProcess(const std::list<Module*>& modules); | 125 void CallProcess(const std::list<Module*>& modules); |
126 void QueuePackets(Packets* batch, int64_t end_of_batch_time_us); | 126 void QueuePackets(Packets* batch, int64_t end_of_batch_time_us); |
127 | 127 |
128 PacedSender pacer_; | 128 PacedSender pacer_; |
129 Packets queue_; | 129 Packets queue_; |
130 Packets pacer_queue_; | 130 Packets pacer_queue_; |
131 | 131 |
132 DISALLOW_IMPLICIT_CONSTRUCTORS(PacedVideoSender); | 132 RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(PacedVideoSender); |
133 }; | 133 }; |
134 | 134 |
135 class TcpSender : public PacketSender { | 135 class TcpSender : public PacketSender { |
136 public: | 136 public: |
137 TcpSender(PacketProcessorListener* listener, int flow_id, int64_t offset_ms); | 137 TcpSender(PacketProcessorListener* listener, int flow_id, int64_t offset_ms); |
138 TcpSender(PacketProcessorListener* listener, | 138 TcpSender(PacketProcessorListener* listener, |
139 int flow_id, | 139 int flow_id, |
140 int64_t offset_ms, | 140 int64_t offset_ms, |
141 int send_limit_bytes); | 141 int send_limit_bytes); |
142 virtual ~TcpSender() {} | 142 virtual ~TcpSender() {} |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
185 int total_sent_bytes_; | 185 int total_sent_bytes_; |
186 int send_limit_bytes_; // Initialized by default as kNoLimit. | 186 int send_limit_bytes_; // Initialized by default as kNoLimit. |
187 int64_t last_generated_packets_ms_; | 187 int64_t last_generated_packets_ms_; |
188 size_t num_recent_sent_packets_; | 188 size_t num_recent_sent_packets_; |
189 uint32_t bitrate_kbps_; | 189 uint32_t bitrate_kbps_; |
190 }; | 190 }; |
191 } // namespace bwe | 191 } // namespace bwe |
192 } // namespace testing | 192 } // namespace testing |
193 } // namespace webrtc | 193 } // namespace webrtc |
194 #endif // WEBRTC_MODULES_REMOTE_BITRATE_ESTIMATOR_TEST_PACKET_SENDER_H_ | 194 #endif // WEBRTC_MODULES_REMOTE_BITRATE_ESTIMATOR_TEST_PACKET_SENDER_H_ |
OLD | NEW |