OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright 2012 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 713 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
724 const std::vector<cricket::Candidate>& candidates) { | 724 const std::vector<cricket::Candidate>& candidates) { |
725 return false; | 725 return false; |
726 } | 726 } |
727 | 727 |
728 // Register a metric observer (used by chromium). | 728 // Register a metric observer (used by chromium). |
729 // | 729 // |
730 // There can only be one observer at a time. Before the observer is | 730 // There can only be one observer at a time. Before the observer is |
731 // destroyed, RegisterUMAOberver(nullptr) should be called. | 731 // destroyed, RegisterUMAOberver(nullptr) should be called. |
732 virtual void RegisterUMAObserver(UMAObserver* observer) = 0; | 732 virtual void RegisterUMAObserver(UMAObserver* observer) = 0; |
733 | 733 |
| 734 struct BitrateParameters { |
| 735 rtc::Optional<int> min_bitrate_bps; |
| 736 rtc::Optional<int> current_bitrate_bps; |
| 737 rtc::Optional<int> max_bitrate_bps; |
| 738 }; |
| 739 |
| 740 // SetBitrate limits the bandwidth allocated for all RTP streams sent by |
| 741 // this PeerConnection. Other limitations might affect these limits and |
| 742 // are respected (for example "b=AS" in SDP). |
| 743 // |
| 744 // 0 <= min <= current <= max should hold for set parameters. |
| 745 // |
| 746 // Changing |current_bitrate_bps| to a new value will reset the current |
| 747 // bitrate estimate to the provided value. |
| 748 virtual RTCError SetBitrate(const BitrateParameters& bitrate) = 0; |
| 749 |
734 // Returns the current SignalingState. | 750 // Returns the current SignalingState. |
735 virtual SignalingState signaling_state() = 0; | 751 virtual SignalingState signaling_state() = 0; |
736 virtual IceConnectionState ice_connection_state() = 0; | 752 virtual IceConnectionState ice_connection_state() = 0; |
737 virtual IceGatheringState ice_gathering_state() = 0; | 753 virtual IceGatheringState ice_gathering_state() = 0; |
738 | 754 |
739 // Starts RtcEventLog using existing file. Takes ownership of |file| and | 755 // Starts RtcEventLog using existing file. Takes ownership of |file| and |
740 // passes it on to Call, which will take the ownership. If the | 756 // passes it on to Call, which will take the ownership. If the |
741 // operation fails the file will be closed. The logging will stop | 757 // operation fails the file will be closed. The logging will stop |
742 // automatically after 10 minutes have passed, or when the StopRtcEventLog | 758 // automatically after 10 minutes have passed, or when the StopRtcEventLog |
743 // function is called. | 759 // function is called. |
(...skipping 362 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1106 cricket::WebRtcVideoEncoderFactory* encoder_factory, | 1122 cricket::WebRtcVideoEncoderFactory* encoder_factory, |
1107 cricket::WebRtcVideoDecoderFactory* decoder_factory) { | 1123 cricket::WebRtcVideoDecoderFactory* decoder_factory) { |
1108 return CreatePeerConnectionFactory( | 1124 return CreatePeerConnectionFactory( |
1109 worker_and_network_thread, worker_and_network_thread, signaling_thread, | 1125 worker_and_network_thread, worker_and_network_thread, signaling_thread, |
1110 default_adm, encoder_factory, decoder_factory); | 1126 default_adm, encoder_factory, decoder_factory); |
1111 } | 1127 } |
1112 | 1128 |
1113 } // namespace webrtc | 1129 } // namespace webrtc |
1114 | 1130 |
1115 #endif // WEBRTC_API_PEERCONNECTIONINTERFACE_H_ | 1131 #endif // WEBRTC_API_PEERCONNECTIONINTERFACE_H_ |
OLD | NEW |