(Auto)update libjingle 77689511-> 77696841

git-svn-id: http://webrtc.googlecode.com/svn/trunk@7449 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
buildbot@webrtc.org
2014-10-14 20:29:28 +00:00
parent 43336b6b9f
commit 1ecbe45c7e
18 changed files with 113 additions and 52 deletions

View File

@@ -282,7 +282,11 @@ bool Call::AddSession(Session* session, const SessionDescription* offer) {
if (has_video_ && succeeded) {
media_session.video_channel =
session_client_->channel_manager()->CreateVideoChannel(
session, video_offer->name, true, media_session.voice_channel);
session,
video_offer->name,
true,
VideoOptions(),
media_session.voice_channel);
// video_channel can be NULL in case of NullVideoEngine.
if (media_session.video_channel) {
media_session.video_channel->SignalMediaMonitor.connect(

View File

@@ -362,22 +362,48 @@ void ChannelManager::DestroyVoiceChannel_w(VoiceChannel* voice_channel) {
}
VideoChannel* ChannelManager::CreateVideoChannel(
BaseSession* session, const std::string& content_name, bool rtcp,
BaseSession* session,
const std::string& content_name,
bool rtcp,
VoiceChannel* voice_channel) {
return worker_thread_->Invoke<VideoChannel*>(
Bind(&ChannelManager::CreateVideoChannel_w, this, session,
content_name, rtcp, voice_channel));
Bind(&ChannelManager::CreateVideoChannel_w,
this,
session,
content_name,
rtcp,
VideoOptions(),
voice_channel));
}
VideoChannel* ChannelManager::CreateVideoChannel(
BaseSession* session,
const std::string& content_name,
bool rtcp,
const VideoOptions& options,
VoiceChannel* voice_channel) {
return worker_thread_->Invoke<VideoChannel*>(
Bind(&ChannelManager::CreateVideoChannel_w,
this,
session,
content_name,
rtcp,
options,
voice_channel));
}
VideoChannel* ChannelManager::CreateVideoChannel_w(
BaseSession* session, const std::string& content_name, bool rtcp,
BaseSession* session,
const std::string& content_name,
bool rtcp,
const VideoOptions& options,
VoiceChannel* voice_channel) {
// This is ok to alloc from a thread other than the worker thread
ASSERT(initialized_);
VideoMediaChannel* media_channel =
// voice_channel can be NULL in case of NullVoiceEngine.
media_engine_->CreateVideoChannel(voice_channel ?
voice_channel->media_channel() : NULL);
media_engine_->CreateVideoChannel(
options, voice_channel ? voice_channel->media_channel() : NULL);
if (media_channel == NULL)
return NULL;

View File

@@ -113,11 +113,18 @@ class ChannelManager : public rtc::MessageHandler,
BaseSession* session, const std::string& content_name, bool rtcp);
// Destroys a voice channel created with the Create API.
void DestroyVoiceChannel(VoiceChannel* voice_channel);
// TODO(pbos): Remove as soon as all call sites specify VideoOptions.
VideoChannel* CreateVideoChannel(BaseSession* session,
const std::string& content_name,
bool rtcp,
VoiceChannel* voice_channel);
// Creates a video channel, synced with the specified voice channel, and
// associated with the specified session.
VideoChannel* CreateVideoChannel(
BaseSession* session, const std::string& content_name, bool rtcp,
VoiceChannel* voice_channel);
VideoChannel* CreateVideoChannel(BaseSession* session,
const std::string& content_name,
bool rtcp,
const VideoOptions& options,
VoiceChannel* voice_channel);
// Destroys a video channel created with the Create API.
void DestroyVideoChannel(VideoChannel* video_channel);
DataChannel* CreateDataChannel(
@@ -261,9 +268,11 @@ class ChannelManager : public rtc::MessageHandler,
VoiceChannel* CreateVoiceChannel_w(
BaseSession* session, const std::string& content_name, bool rtcp);
void DestroyVoiceChannel_w(VoiceChannel* voice_channel);
VideoChannel* CreateVideoChannel_w(
BaseSession* session, const std::string& content_name, bool rtcp,
VoiceChannel* voice_channel);
VideoChannel* CreateVideoChannel_w(BaseSession* session,
const std::string& content_name,
bool rtcp,
const VideoOptions& options,
VoiceChannel* voice_channel);
void DestroyVideoChannel_w(VideoChannel* video_channel);
DataChannel* CreateDataChannel_w(
BaseSession* session, const std::string& content_name,

View File

@@ -127,9 +127,8 @@ TEST_F(ChannelManagerTest, CreateDestroyChannels) {
cricket::VoiceChannel* voice_channel = cm_->CreateVoiceChannel(
session_, cricket::CN_AUDIO, false);
EXPECT_TRUE(voice_channel != NULL);
cricket::VideoChannel* video_channel =
cm_->CreateVideoChannel(session_, cricket::CN_VIDEO,
false, voice_channel);
cricket::VideoChannel* video_channel = cm_->CreateVideoChannel(
session_, cricket::CN_VIDEO, false, VideoOptions(), voice_channel);
EXPECT_TRUE(video_channel != NULL);
cricket::DataChannel* data_channel =
cm_->CreateDataChannel(session_, cricket::CN_DATA,
@@ -151,9 +150,8 @@ TEST_F(ChannelManagerTest, CreateDestroyChannelsOnThread) {
cricket::VoiceChannel* voice_channel = cm_->CreateVoiceChannel(
session_, cricket::CN_AUDIO, false);
EXPECT_TRUE(voice_channel != NULL);
cricket::VideoChannel* video_channel =
cm_->CreateVideoChannel(session_, cricket::CN_VIDEO,
false, voice_channel);
cricket::VideoChannel* video_channel = cm_->CreateVideoChannel(
session_, cricket::CN_VIDEO, false, VideoOptions(), voice_channel);
EXPECT_TRUE(video_channel != NULL);
cricket::DataChannel* data_channel =
cm_->CreateDataChannel(session_, cricket::CN_DATA,
@@ -178,9 +176,8 @@ TEST_F(ChannelManagerTest, NoTransportChannelTest) {
cricket::VoiceChannel* voice_channel = cm_->CreateVoiceChannel(
session_, cricket::CN_AUDIO, false);
EXPECT_TRUE(voice_channel == NULL);
cricket::VideoChannel* video_channel =
cm_->CreateVideoChannel(session_, cricket::CN_VIDEO,
false, voice_channel);
cricket::VideoChannel* video_channel = cm_->CreateVideoChannel(
session_, cricket::CN_VIDEO, false, VideoOptions(), voice_channel);
EXPECT_TRUE(video_channel == NULL);
cricket::DataChannel* data_channel =
cm_->CreateDataChannel(session_, cricket::CN_DATA,