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 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
52 ~VideoSendStream() override; | 52 ~VideoSendStream() override; |
53 | 53 |
54 // webrtc::SendStream implementation. | 54 // webrtc::SendStream implementation. |
55 void Start() override; | 55 void Start() override; |
56 void Stop() override; | 56 void Stop() override; |
57 void SignalNetworkState(NetworkState state) override; | 57 void SignalNetworkState(NetworkState state) override; |
58 bool DeliverRtcp(const uint8_t* packet, size_t length) override; | 58 bool DeliverRtcp(const uint8_t* packet, size_t length) override; |
59 | 59 |
60 // webrtc::VideoSendStream implementation. | 60 // webrtc::VideoSendStream implementation. |
61 VideoCaptureInput* Input() override; | 61 VideoCaptureInput* Input() override; |
62 bool ReconfigureVideoEncoder(const VideoEncoderConfig& config) override; | 62 void ReconfigureVideoEncoder(const VideoEncoderConfig& config) override; |
63 Stats GetStats() override; | 63 Stats GetStats() override; |
64 | 64 |
65 // webrtc::CpuOveruseObserver implementation. | 65 // webrtc::CpuOveruseObserver implementation. |
66 void OveruseDetected() override; | 66 void OveruseDetected() override; |
67 void NormalUsage() override; | 67 void NormalUsage() override; |
68 | 68 |
69 typedef std::map<uint32_t, RtpState> RtpStateMap; | 69 typedef std::map<uint32_t, RtpState> RtpStateMap; |
70 RtpStateMap GetRtpStates() const; | 70 RtpStateMap GetRtpStates() const; |
71 | 71 |
72 int64_t GetRtt() const; | 72 int64_t GetRtt() const; |
73 int GetPaddingNeededBps() const; | 73 int GetPaddingNeededBps() const; |
74 | 74 |
| 75 void SetSendCodec(VideoCodec video_codec); |
| 76 |
75 private: | 77 private: |
76 bool SetSendCodec(VideoCodec video_codec); | |
77 void ConfigureSsrcs(); | 78 void ConfigureSsrcs(); |
78 | 79 |
79 SendStatisticsProxy stats_proxy_; | 80 SendStatisticsProxy stats_proxy_; |
80 TransportAdapter transport_adapter_; | 81 TransportAdapter transport_adapter_; |
81 EncodedFrameCallbackAdapter encoded_frame_proxy_; | 82 EncodedFrameCallbackAdapter encoded_frame_proxy_; |
82 const VideoSendStream::Config config_; | 83 const VideoSendStream::Config config_; |
83 VideoEncoderConfig encoder_config_; | 84 VideoEncoderConfig encoder_config_; |
84 std::map<uint32_t, RtpState> suspended_ssrcs_; | 85 std::map<uint32_t, RtpState> suspended_ssrcs_; |
85 | 86 |
86 ProcessThread* const module_process_thread_; | 87 ProcessThread* const module_process_thread_; |
87 CallStats* const call_stats_; | 88 CallStats* const call_stats_; |
88 CongestionController* const congestion_controller_; | 89 CongestionController* const congestion_controller_; |
89 | 90 |
90 rtc::scoped_ptr<VideoCaptureInput> input_; | 91 rtc::scoped_ptr<VideoCaptureInput> input_; |
91 rtc::scoped_ptr<ViEChannel> vie_channel_; | 92 rtc::scoped_ptr<ViEChannel> vie_channel_; |
92 rtc::scoped_ptr<ViEEncoder> vie_encoder_; | 93 rtc::scoped_ptr<ViEEncoder> vie_encoder_; |
93 rtc::scoped_ptr<EncoderStateFeedback> encoder_feedback_; | 94 rtc::scoped_ptr<EncoderStateFeedback> encoder_feedback_; |
94 | |
95 // Used as a workaround to indicate that we should be using the configured | |
96 // start bitrate initially, instead of the one reported by VideoEngine (which | |
97 // defaults to too high). | |
98 bool use_config_bitrate_; | |
99 }; | 95 }; |
100 } // namespace internal | 96 } // namespace internal |
101 } // namespace webrtc | 97 } // namespace webrtc |
102 | 98 |
103 #endif // WEBRTC_VIDEO_VIDEO_SEND_STREAM_H_ | 99 #endif // WEBRTC_VIDEO_VIDEO_SEND_STREAM_H_ |
OLD | NEW |