(Auto)update libjingle 72847605-> 72850595
git-svn-id: http://webrtc.googlecode.com/svn/trunk@6855 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
parent
65b98d12c3
commit
53df88c1bc
@ -95,6 +95,8 @@ const char MediaConstraintsInterface::kEnableVideoSuspendBelowMinBitrate[] =
|
|||||||
"googSuspendBelowMinBitrate";
|
"googSuspendBelowMinBitrate";
|
||||||
const char MediaConstraintsInterface::kImprovedWifiBwe[] =
|
const char MediaConstraintsInterface::kImprovedWifiBwe[] =
|
||||||
"googImprovedWifiBwe";
|
"googImprovedWifiBwe";
|
||||||
|
const char MediaConstraintsInterface::kNumUnsignalledRecvStreams[] =
|
||||||
|
"googNumUnsignalledRecvStreams";
|
||||||
const char MediaConstraintsInterface::kScreencastMinBitrate[] =
|
const char MediaConstraintsInterface::kScreencastMinBitrate[] =
|
||||||
"googScreencastMinBitrate";
|
"googScreencastMinBitrate";
|
||||||
// TODO(ronghuawu): Remove once cpu overuse detection is stable.
|
// TODO(ronghuawu): Remove once cpu overuse detection is stable.
|
||||||
|
@ -116,6 +116,8 @@ class MediaConstraintsInterface {
|
|||||||
static const char kEnableVideoSuspendBelowMinBitrate[];
|
static const char kEnableVideoSuspendBelowMinBitrate[];
|
||||||
// googSuspendBelowMinBitrate
|
// googSuspendBelowMinBitrate
|
||||||
static const char kImprovedWifiBwe[]; // googImprovedWifiBwe
|
static const char kImprovedWifiBwe[]; // googImprovedWifiBwe
|
||||||
|
static const char kNumUnsignalledRecvStreams[];
|
||||||
|
// googNumUnsignalledRecvStreams
|
||||||
static const char kScreencastMinBitrate[]; // googScreencastMinBitrate
|
static const char kScreencastMinBitrate[]; // googScreencastMinBitrate
|
||||||
static const char kCpuOveruseDetection[]; // googCpuOveruseDetection
|
static const char kCpuOveruseDetection[]; // googCpuOveruseDetection
|
||||||
static const char kCpuUnderuseThreshold[]; // googCpuUnderuseThreshold
|
static const char kCpuUnderuseThreshold[]; // googCpuUnderuseThreshold
|
||||||
|
@ -38,6 +38,7 @@
|
|||||||
#include "talk/app/webrtc/mediastreamsignaling.h"
|
#include "talk/app/webrtc/mediastreamsignaling.h"
|
||||||
#include "talk/app/webrtc/peerconnectioninterface.h"
|
#include "talk/app/webrtc/peerconnectioninterface.h"
|
||||||
#include "talk/app/webrtc/webrtcsessiondescriptionfactory.h"
|
#include "talk/app/webrtc/webrtcsessiondescriptionfactory.h"
|
||||||
|
#include "webrtc/base/basictypes.h"
|
||||||
#include "webrtc/base/helpers.h"
|
#include "webrtc/base/helpers.h"
|
||||||
#include "webrtc/base/logging.h"
|
#include "webrtc/base/logging.h"
|
||||||
#include "webrtc/base/stringencode.h"
|
#include "webrtc/base/stringencode.h"
|
||||||
@ -74,6 +75,7 @@ const char kSdpWithoutIceUfragPwd[] =
|
|||||||
"Called with SDP without ice-ufrag and ice-pwd.";
|
"Called with SDP without ice-ufrag and ice-pwd.";
|
||||||
const char kSessionError[] = "Session error code: ";
|
const char kSessionError[] = "Session error code: ";
|
||||||
const char kSessionErrorDesc[] = "Session error description: ";
|
const char kSessionErrorDesc[] = "Session error description: ";
|
||||||
|
const int kMaxUnsignalledRecvStreams = 20;
|
||||||
|
|
||||||
// Compares |answer| against |offer|. Comparision is done
|
// Compares |answer| against |offer|. Comparision is done
|
||||||
// for number of m-lines in answer against offer. If matches true will be
|
// for number of m-lines in answer against offer. If matches true will be
|
||||||
@ -589,6 +591,17 @@ bool WebRtcSession::Initialize(
|
|||||||
video_options_.use_improved_wifi_bandwidth_estimator.Set(true);
|
video_options_.use_improved_wifi_bandwidth_estimator.Set(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
SetOptionFromOptionalConstraint(constraints,
|
||||||
|
MediaConstraintsInterface::kNumUnsignalledRecvStreams,
|
||||||
|
&video_options_.unsignalled_recv_stream_limit);
|
||||||
|
if (video_options_.unsignalled_recv_stream_limit.IsSet()) {
|
||||||
|
int stream_limit;
|
||||||
|
video_options_.unsignalled_recv_stream_limit.Get(&stream_limit);
|
||||||
|
stream_limit = rtc::_min(kMaxUnsignalledRecvStreams, stream_limit);
|
||||||
|
stream_limit = rtc::_max(0, stream_limit);
|
||||||
|
video_options_.unsignalled_recv_stream_limit.Set(stream_limit);
|
||||||
|
}
|
||||||
|
|
||||||
SetOptionFromOptionalConstraint(constraints,
|
SetOptionFromOptionalConstraint(constraints,
|
||||||
MediaConstraintsInterface::kHighStartBitrate,
|
MediaConstraintsInterface::kHighStartBitrate,
|
||||||
&video_options_.video_start_bitrate);
|
&video_options_.video_start_bitrate);
|
||||||
|
@ -73,6 +73,9 @@ extern const char kSdpWithoutIceUfragPwd[];
|
|||||||
extern const char kSdpWithoutSdesAndDtlsDisabled[];
|
extern const char kSdpWithoutSdesAndDtlsDisabled[];
|
||||||
extern const char kSessionError[];
|
extern const char kSessionError[];
|
||||||
extern const char kSessionErrorDesc[];
|
extern const char kSessionErrorDesc[];
|
||||||
|
// Maximum number of received video streams that will be processed by webrtc
|
||||||
|
// even if they are not signalled beforehand.
|
||||||
|
extern const int kMaxUnsignalledRecvStreams;
|
||||||
|
|
||||||
// ICE state callback interface.
|
// ICE state callback interface.
|
||||||
class IceObserver {
|
class IceObserver {
|
||||||
|
@ -98,6 +98,7 @@ using webrtc::kSdpWithoutDtlsFingerprint;
|
|||||||
using webrtc::kSdpWithoutSdesCrypto;
|
using webrtc::kSdpWithoutSdesCrypto;
|
||||||
using webrtc::kSessionError;
|
using webrtc::kSessionError;
|
||||||
using webrtc::kSessionErrorDesc;
|
using webrtc::kSessionErrorDesc;
|
||||||
|
using webrtc::kMaxUnsignalledRecvStreams;
|
||||||
|
|
||||||
typedef PeerConnectionInterface::RTCOfferAnswerOptions RTCOfferAnswerOptions;
|
typedef PeerConnectionInterface::RTCOfferAnswerOptions RTCOfferAnswerOptions;
|
||||||
|
|
||||||
@ -537,6 +538,28 @@ class WebRtcSessionTest : public testing::Test {
|
|||||||
VerifyCryptoParams(answer->description());
|
VerifyCryptoParams(answer->description());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void SetAndVerifyNumUnsignalledRecvStreams(
|
||||||
|
int value_set, int value_expected) {
|
||||||
|
constraints_.reset(new FakeConstraints());
|
||||||
|
constraints_->AddOptional(
|
||||||
|
webrtc::MediaConstraintsInterface::kNumUnsignalledRecvStreams,
|
||||||
|
value_set);
|
||||||
|
session_.reset();
|
||||||
|
Init(NULL);
|
||||||
|
mediastream_signaling_.SendAudioVideoStream1();
|
||||||
|
SessionDescriptionInterface* offer = CreateOffer();
|
||||||
|
|
||||||
|
SetLocalDescriptionWithoutError(offer);
|
||||||
|
|
||||||
|
video_channel_ = media_engine_->GetVideoChannel(0);
|
||||||
|
|
||||||
|
ASSERT_TRUE(video_channel_ != NULL);
|
||||||
|
cricket::VideoOptions video_options;
|
||||||
|
EXPECT_TRUE(video_channel_->GetOptions(&video_options));
|
||||||
|
EXPECT_EQ(value_expected,
|
||||||
|
video_options.unsignalled_recv_stream_limit.GetWithDefaultIfUnset(-1));
|
||||||
|
}
|
||||||
|
|
||||||
void CompareIceUfragAndPassword(const cricket::SessionDescription* desc1,
|
void CompareIceUfragAndPassword(const cricket::SessionDescription* desc1,
|
||||||
const cricket::SessionDescription* desc2,
|
const cricket::SessionDescription* desc2,
|
||||||
bool expect_equal) {
|
bool expect_equal) {
|
||||||
@ -3279,6 +3302,15 @@ TEST_F(WebRtcSessionTest, TestSuspendBelowMinBitrateConstraint) {
|
|||||||
video_options.suspend_below_min_bitrate.GetWithDefaultIfUnset(false));
|
video_options.suspend_below_min_bitrate.GetWithDefaultIfUnset(false));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
TEST_F(WebRtcSessionTest, TestNumUnsignalledRecvStreamsConstraint) {
|
||||||
|
// Number of unsignalled receiving streams should be between 0 and
|
||||||
|
// kMaxUnsignalledRecvStreams.
|
||||||
|
SetAndVerifyNumUnsignalledRecvStreams(10, 10);
|
||||||
|
SetAndVerifyNumUnsignalledRecvStreams(kMaxUnsignalledRecvStreams + 1,
|
||||||
|
kMaxUnsignalledRecvStreams);
|
||||||
|
SetAndVerifyNumUnsignalledRecvStreams(-1, 0);
|
||||||
|
}
|
||||||
|
|
||||||
// Tests that we can renegotiate new media content with ICE candidates in the
|
// Tests that we can renegotiate new media content with ICE candidates in the
|
||||||
// new remote SDP.
|
// new remote SDP.
|
||||||
TEST_F(WebRtcSessionTest, TestRenegotiateNewMediaWithCandidatesInSdp) {
|
TEST_F(WebRtcSessionTest, TestRenegotiateNewMediaWithCandidatesInSdp) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user