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 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
131 static const bool kEnableFrameRecording = false; | 131 static const bool kEnableFrameRecording = false; |
132 static const int kMaxLayers = 3; | 132 static const int kMaxLayers = 3; |
133 std::unique_ptr<IvfFileWriter> file_writers_[kMaxLayers]; | 133 std::unique_ptr<IvfFileWriter> file_writers_[kMaxLayers]; |
134 | 134 |
135 rtc::PlatformThread encoder_thread_; | 135 rtc::PlatformThread encoder_thread_; |
136 rtc::Event encoder_wakeup_event_; | 136 rtc::Event encoder_wakeup_event_; |
137 volatile int stop_encoder_thread_; | 137 volatile int stop_encoder_thread_; |
138 rtc::CriticalSection encoder_settings_crit_; | 138 rtc::CriticalSection encoder_settings_crit_; |
139 std::unique_ptr<EncoderSettings> pending_encoder_settings_ | 139 std::unique_ptr<EncoderSettings> pending_encoder_settings_ |
140 GUARDED_BY(encoder_settings_crit_); | 140 GUARDED_BY(encoder_settings_crit_); |
| 141 uint32_t encoder_max_bitrate_bps_ GUARDED_BY(encoder_settings_crit_); |
141 | 142 |
142 enum class State { | 143 enum class State { |
143 kStopped, // VideoSendStream::Start has not yet been called. | 144 kStopped, // VideoSendStream::Start has not yet been called. |
144 kStarted, // VideoSendStream::Start has been called. | 145 kStarted, // VideoSendStream::Start has been called. |
145 // VideoSendStream::Start has been called but the encoder have timed out. | 146 // VideoSendStream::Start has been called but the encoder have timed out. |
146 kEncoderTimedOut, | 147 kEncoderTimedOut, |
147 }; | 148 }; |
148 rtc::Optional<State> pending_state_change_ GUARDED_BY(encoder_settings_crit_); | 149 rtc::Optional<State> pending_state_change_ GUARDED_BY(encoder_settings_crit_); |
149 | 150 |
150 // Only used on the encoder thread. | 151 // Only used on the encoder thread. |
(...skipping 12 matching lines...) Expand all Loading... |
163 const std::unique_ptr<RtcpBandwidthObserver> bandwidth_observer_; | 164 const std::unique_ptr<RtcpBandwidthObserver> bandwidth_observer_; |
164 // RtpRtcp modules, declared here as they use other members on construction. | 165 // RtpRtcp modules, declared here as they use other members on construction. |
165 const std::vector<RtpRtcp*> rtp_rtcp_modules_; | 166 const std::vector<RtpRtcp*> rtp_rtcp_modules_; |
166 PayloadRouter payload_router_; | 167 PayloadRouter payload_router_; |
167 VideoCaptureInput input_; | 168 VideoCaptureInput input_; |
168 }; | 169 }; |
169 } // namespace internal | 170 } // namespace internal |
170 } // namespace webrtc | 171 } // namespace webrtc |
171 | 172 |
172 #endif // WEBRTC_VIDEO_VIDEO_SEND_STREAM_H_ | 173 #endif // WEBRTC_VIDEO_VIDEO_SEND_STREAM_H_ |
OLD | NEW |