Update talk folder to revision=49470012. Same as 375 in libjingle's google code repository.
TBR=wu@webrtc.org BUG=N/A Review URL: https://webrtc-codereview.appspot.com/1824004 git-svn-id: http://webrtc.googlecode.com/svn/trunk@4364 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
parent
a3f30143b7
commit
9de257d00f
@ -69,9 +69,9 @@
|
|||||||
#include "talk/media/devices/videorendererfactory.h"
|
#include "talk/media/devices/videorendererfactory.h"
|
||||||
#include "talk/media/webrtc/webrtcvideocapturer.h"
|
#include "talk/media/webrtc/webrtcvideocapturer.h"
|
||||||
#include "third_party/icu/public/common/unicode/unistr.h"
|
#include "third_party/icu/public/common/unicode/unistr.h"
|
||||||
#include "third_party/webrtc/system_wrappers/interface/trace.h"
|
#include "webrtc/system_wrappers/interface/trace.h"
|
||||||
#include "third_party/webrtc/video_engine/include/vie_base.h"
|
#include "webrtc/video_engine/include/vie_base.h"
|
||||||
#include "third_party/webrtc/voice_engine/include/voe_base.h"
|
#include "webrtc/voice_engine/include/voe_base.h"
|
||||||
|
|
||||||
using icu::UnicodeString;
|
using icu::UnicodeString;
|
||||||
using webrtc::AudioSourceInterface;
|
using webrtc::AudioSourceInterface;
|
||||||
|
@ -66,8 +66,6 @@ using cricket::FakeVoiceMediaChannel;
|
|||||||
using cricket::NS_GINGLE_P2P;
|
using cricket::NS_GINGLE_P2P;
|
||||||
using cricket::NS_JINGLE_ICE_UDP;
|
using cricket::NS_JINGLE_ICE_UDP;
|
||||||
using cricket::TransportInfo;
|
using cricket::TransportInfo;
|
||||||
using cricket::kDtmfDelay;
|
|
||||||
using cricket::kDtmfReset;
|
|
||||||
using talk_base::SocketAddress;
|
using talk_base::SocketAddress;
|
||||||
using talk_base::scoped_ptr;
|
using talk_base::scoped_ptr;
|
||||||
using webrtc::CreateSessionDescription;
|
using webrtc::CreateSessionDescription;
|
||||||
@ -2247,13 +2245,13 @@ TEST_F(WebRtcSessionTest, TestIncorrectMLinesInLocalAnswer) {
|
|||||||
|
|
||||||
cricket::SessionDescription* answer_copy = answer->description()->Copy();
|
cricket::SessionDescription* answer_copy = answer->description()->Copy();
|
||||||
answer_copy->RemoveContentByName("video");
|
answer_copy->RemoveContentByName("video");
|
||||||
JsepSessionDescription* modified_answer =
|
talk_base::scoped_ptr<JsepSessionDescription> modified_answer(
|
||||||
new JsepSessionDescription(JsepSessionDescription::kAnswer);
|
new JsepSessionDescription(JsepSessionDescription::kAnswer));
|
||||||
|
|
||||||
EXPECT_TRUE(modified_answer->Initialize(answer_copy,
|
EXPECT_TRUE(modified_answer->Initialize(answer_copy,
|
||||||
answer->session_id(),
|
answer->session_id(),
|
||||||
answer->session_version()));
|
answer->session_version()));
|
||||||
SetLocalDescriptionExpectError(kMlineMismatch, modified_answer);
|
SetLocalDescriptionExpectError(kMlineMismatch, modified_answer.get());
|
||||||
SetLocalDescriptionWithoutError(answer);
|
SetLocalDescriptionWithoutError(answer);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -29,6 +29,7 @@
|
|||||||
|
|
||||||
{
|
{
|
||||||
'variables': {
|
'variables': {
|
||||||
|
'webrtc_root%': '<(DEPTH)/webrtc',
|
||||||
# TODO(ronghuawu): Chromium build will need a different libjingle_root.
|
# TODO(ronghuawu): Chromium build will need a different libjingle_root.
|
||||||
'libjingle_root%': '<(DEPTH)',
|
'libjingle_root%': '<(DEPTH)',
|
||||||
# TODO(ronghuawu): For now, disable the Chrome plugins, which causes a
|
# TODO(ronghuawu): For now, disable the Chrome plugins, which causes a
|
||||||
@ -44,6 +45,7 @@
|
|||||||
'../..',
|
'../..',
|
||||||
'../../third_party',
|
'../../third_party',
|
||||||
'../../third_party/webrtc',
|
'../../third_party/webrtc',
|
||||||
|
'../../webrtc',
|
||||||
],
|
],
|
||||||
'defines': [
|
'defines': [
|
||||||
'EXPAT_RELATIVE_PATH',
|
'EXPAT_RELATIVE_PATH',
|
||||||
|
@ -80,7 +80,7 @@
|
|||||||
{
|
{
|
||||||
'variables': {
|
'variables': {
|
||||||
'java_src_dir': 'app/webrtc/java/src',
|
'java_src_dir': 'app/webrtc/java/src',
|
||||||
'webrtc_modules_dir': '<(DEPTH)/third_party/webrtc/modules',
|
'webrtc_modules_dir': '<(webrtc_root)/modules',
|
||||||
'peerconnection_java_files': [
|
'peerconnection_java_files': [
|
||||||
'app/webrtc/java/src/org/webrtc/AudioSource.java',
|
'app/webrtc/java/src/org/webrtc/AudioSource.java',
|
||||||
'app/webrtc/java/src/org/webrtc/AudioTrack.java',
|
'app/webrtc/java/src/org/webrtc/AudioTrack.java',
|
||||||
@ -105,13 +105,13 @@
|
|||||||
# included here, or better yet, build a proper .jar in webrtc
|
# included here, or better yet, build a proper .jar in webrtc
|
||||||
# and include it here.
|
# and include it here.
|
||||||
'android_java_files': [
|
'android_java_files': [
|
||||||
'<(webrtc_modules_dir)/audio_device/android/org/webrtc/voiceengine/WebRTCAudioDevice.java',
|
'<(webrtc_modules_dir)/audio_device/android/java/src/org/webrtc/voiceengine/WebRTCAudioDevice.java',
|
||||||
'<(webrtc_modules_dir)/video_capture/android/java/org/webrtc/videoengine/CaptureCapabilityAndroid.java',
|
'<(webrtc_modules_dir)/video_capture/android/java/src/org/webrtc/videoengine/CaptureCapabilityAndroid.java',
|
||||||
'<(webrtc_modules_dir)/video_capture/android/java/org/webrtc/videoengine/VideoCaptureAndroid.java',
|
'<(webrtc_modules_dir)/video_capture/android/java/src/org/webrtc/videoengine/VideoCaptureAndroid.java',
|
||||||
'<(webrtc_modules_dir)/video_capture/android/java/org/webrtc/videoengine/VideoCaptureDeviceInfoAndroid.java',
|
'<(webrtc_modules_dir)/video_capture/android/java/src/org/webrtc/videoengine/VideoCaptureDeviceInfoAndroid.java',
|
||||||
'<(webrtc_modules_dir)/video_render/android/java/org/webrtc/videoengine/ViEAndroidGLES20.java',
|
'<(webrtc_modules_dir)/video_render/android/java/src/org/webrtc/videoengine/ViEAndroidGLES20.java',
|
||||||
'<(webrtc_modules_dir)/video_render/android/java/org/webrtc/videoengine/ViERenderer.java',
|
'<(webrtc_modules_dir)/video_render/android/java/src/org/webrtc/videoengine/ViERenderer.java',
|
||||||
'<(webrtc_modules_dir)/video_render/android/java/org/webrtc/videoengine/ViESurfaceRenderer.java',
|
'<(webrtc_modules_dir)/video_render/android/java/src/org/webrtc/videoengine/ViESurfaceRenderer.java',
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
'action_name': 'create_jar',
|
'action_name': 'create_jar',
|
||||||
@ -769,11 +769,11 @@
|
|||||||
'type': 'static_library',
|
'type': 'static_library',
|
||||||
'dependencies': [
|
'dependencies': [
|
||||||
'<(DEPTH)/third_party/libyuv/libyuv.gyp:libyuv',
|
'<(DEPTH)/third_party/libyuv/libyuv.gyp:libyuv',
|
||||||
'<(DEPTH)/third_party/webrtc/modules/modules.gyp:video_capture_module',
|
'<(webrtc_root)/modules/modules.gyp:video_capture_module',
|
||||||
'<(DEPTH)/third_party/webrtc/modules/modules.gyp:video_render_module',
|
'<(webrtc_root)/modules/modules.gyp:video_render_module',
|
||||||
'<(DEPTH)/third_party/webrtc/video_engine/video_engine.gyp:video_engine_core',
|
'<(webrtc_root)/video_engine/video_engine.gyp:video_engine_core',
|
||||||
'<(DEPTH)/third_party/webrtc/voice_engine/voice_engine.gyp:voice_engine',
|
'<(webrtc_root)/voice_engine/voice_engine.gyp:voice_engine',
|
||||||
'<(DEPTH)/third_party/webrtc/system_wrappers/source/system_wrappers.gyp:system_wrappers',
|
'<(webrtc_root)/system_wrappers/source/system_wrappers.gyp:system_wrappers',
|
||||||
'libjingle',
|
'libjingle',
|
||||||
'libjingle_sound',
|
'libjingle_sound',
|
||||||
],
|
],
|
||||||
|
@ -22,13 +22,13 @@ talk.Library(env, name = "expat",
|
|||||||
)
|
)
|
||||||
talk.Library(env, name = "gunit",
|
talk.Library(env, name = "gunit",
|
||||||
srcs = [
|
srcs = [
|
||||||
"third_party/gtest/src/gtest-all.cc",
|
"testing/gtest/src/gtest-all.cc",
|
||||||
],
|
],
|
||||||
includedirs = [
|
includedirs = [
|
||||||
"third_party/gtest/include",
|
"testing/gtest/include",
|
||||||
"third_party/expat-2.0.1/lib",
|
"third_party/expat-2.0.1/lib",
|
||||||
"third_party/srtp",
|
"third_party/srtp",
|
||||||
"third_party/gtest",
|
"testing/gtest",
|
||||||
],
|
],
|
||||||
cppdefines = [
|
cppdefines = [
|
||||||
"EXPAT_RELATIVE_PATH",
|
"EXPAT_RELATIVE_PATH",
|
||||||
@ -355,7 +355,7 @@ talk.Library(env, name = "jingle",
|
|||||||
includedirs = [
|
includedirs = [
|
||||||
"third_party/libudev",
|
"third_party/libudev",
|
||||||
"third_party/expat-2.0.1/lib",
|
"third_party/expat-2.0.1/lib",
|
||||||
"third_party/gtest/include",
|
"testing/gtest/include",
|
||||||
"third_party/srtp/include",
|
"third_party/srtp/include",
|
||||||
"third_party/srtp/crypto/include",
|
"third_party/srtp/crypto/include",
|
||||||
] + SSL_INCLUDES,
|
] + SSL_INCLUDES,
|
||||||
@ -405,10 +405,10 @@ talk.Library(env, name = "unittest_main",
|
|||||||
"base/unittest_main.cc",
|
"base/unittest_main.cc",
|
||||||
],
|
],
|
||||||
includedirs = [
|
includedirs = [
|
||||||
"third_party/gtest/include",
|
"testing/gtest/include",
|
||||||
"third_party/expat-2.0.1/lib",
|
"third_party/expat-2.0.1/lib",
|
||||||
"third_party/srtp",
|
"third_party/srtp",
|
||||||
"third_party/gtest",
|
"testing/gtest",
|
||||||
],
|
],
|
||||||
cppdefines = [
|
cppdefines = [
|
||||||
"EXPAT_RELATIVE_PATH",
|
"EXPAT_RELATIVE_PATH",
|
||||||
@ -589,10 +589,10 @@ talk.Unittest(env, name = "base",
|
|||||||
"base/windowpicker_unittest.cc",
|
"base/windowpicker_unittest.cc",
|
||||||
],
|
],
|
||||||
includedirs = [
|
includedirs = [
|
||||||
"third_party/gtest/include",
|
"testing/gtest/include",
|
||||||
"third_party/expat-2.0.1/lib",
|
"third_party/expat-2.0.1/lib",
|
||||||
"third_party/srtp",
|
"third_party/srtp",
|
||||||
"third_party/gtest",
|
"testing/gtest",
|
||||||
],
|
],
|
||||||
win_srcs = [
|
win_srcs = [
|
||||||
"base/win32_unittest.cc",
|
"base/win32_unittest.cc",
|
||||||
@ -644,10 +644,10 @@ talk.Unittest(env, name = "p2p",
|
|||||||
"p2p/client/portallocator_unittest.cc",
|
"p2p/client/portallocator_unittest.cc",
|
||||||
],
|
],
|
||||||
includedirs = [
|
includedirs = [
|
||||||
"third_party/gtest/include",
|
"testing/gtest/include",
|
||||||
"third_party/expat-2.0.1/lib",
|
"third_party/expat-2.0.1/lib",
|
||||||
"third_party/srtp",
|
"third_party/srtp",
|
||||||
"third_party/gtest",
|
"testing/gtest",
|
||||||
],
|
],
|
||||||
libs = [
|
libs = [
|
||||||
"jingle",
|
"jingle",
|
||||||
@ -688,10 +688,10 @@ talk.Unittest(env, name = "media",
|
|||||||
"session/media/ssrcmuxfilter_unittest.cc",
|
"session/media/ssrcmuxfilter_unittest.cc",
|
||||||
],
|
],
|
||||||
includedirs = [
|
includedirs = [
|
||||||
"third_party/gtest/include",
|
"testing/gtest/include",
|
||||||
"third_party/expat-2.0.1/lib",
|
"third_party/expat-2.0.1/lib",
|
||||||
"third_party/srtp",
|
"third_party/srtp",
|
||||||
"third_party/gtest",
|
"testing/gtest",
|
||||||
],
|
],
|
||||||
libs = [
|
libs = [
|
||||||
"jingle",
|
"jingle",
|
||||||
@ -712,10 +712,10 @@ talk.Unittest(env, name = "sound",
|
|||||||
mac_libs = SSL_LIBS,
|
mac_libs = SSL_LIBS,
|
||||||
|
|
||||||
includedirs = [
|
includedirs = [
|
||||||
"third_party/gtest/include",
|
"testing/gtest/include",
|
||||||
"third_party/expat-2.0.1/lib",
|
"third_party/expat-2.0.1/lib",
|
||||||
"third_party/srtp",
|
"third_party/srtp",
|
||||||
"third_party/gtest",
|
"testing/gtest",
|
||||||
],
|
],
|
||||||
cppdefines = [
|
cppdefines = [
|
||||||
"EXPAT_RELATIVE_PATH",
|
"EXPAT_RELATIVE_PATH",
|
||||||
@ -738,10 +738,10 @@ talk.Unittest(env, name = "xmllite",
|
|||||||
],
|
],
|
||||||
mac_libs = SSL_LIBS,
|
mac_libs = SSL_LIBS,
|
||||||
includedirs = [
|
includedirs = [
|
||||||
"third_party/gtest/include",
|
"testing/gtest/include",
|
||||||
"third_party/expat-2.0.1/lib",
|
"third_party/expat-2.0.1/lib",
|
||||||
"third_party/srtp",
|
"third_party/srtp",
|
||||||
"third_party/gtest",
|
"testing/gtest",
|
||||||
],
|
],
|
||||||
cppdefines = [
|
cppdefines = [
|
||||||
"EXPAT_RELATIVE_PATH",
|
"EXPAT_RELATIVE_PATH",
|
||||||
@ -772,10 +772,10 @@ talk.Unittest(env, name = "xmpp",
|
|||||||
"xmpp/xmppstanzaparser_unittest.cc",
|
"xmpp/xmppstanzaparser_unittest.cc",
|
||||||
],
|
],
|
||||||
includedirs = [
|
includedirs = [
|
||||||
"third_party/gtest/include",
|
"testing/gtest/include",
|
||||||
"third_party/expat-2.0.1/lib",
|
"third_party/expat-2.0.1/lib",
|
||||||
"third_party/srtp",
|
"third_party/srtp",
|
||||||
"third_party/gtest",
|
"testing/gtest",
|
||||||
],
|
],
|
||||||
libs = [
|
libs = [
|
||||||
"jingle",
|
"jingle",
|
||||||
|
@ -225,8 +225,7 @@
|
|||||||
['os_posix==1', {
|
['os_posix==1', {
|
||||||
'sources': [
|
'sources': [
|
||||||
'base/sslidentity_unittest.cc',
|
'base/sslidentity_unittest.cc',
|
||||||
# TODO(ronghuawu): reenable once fixed on build bots.
|
'base/sslstreamadapter_unittest.cc',
|
||||||
# 'base/sslstreamadapter_unittest.cc',
|
|
||||||
],
|
],
|
||||||
}],
|
}],
|
||||||
], # conditions
|
], # conditions
|
||||||
|
@ -393,12 +393,6 @@ enum DtmfFlags {
|
|||||||
DF_SEND = 0x02,
|
DF_SEND = 0x02,
|
||||||
};
|
};
|
||||||
|
|
||||||
// Special purpose DTMF event code used by the VoiceMediaChannel::InsertDtmf.
|
|
||||||
const int kDtmfDelay = -1; // Insert a delay to the end of the DTMF queue.
|
|
||||||
const int kDtmfReset = -2; // Reset the DTMF queue.
|
|
||||||
// The delay in ms when the InsertDtmf is called with kDtmfDelay.
|
|
||||||
const int kDtmfDelayInMs = 2000;
|
|
||||||
|
|
||||||
class MediaChannel : public sigslot::has_slots<> {
|
class MediaChannel : public sigslot::has_slots<> {
|
||||||
public:
|
public:
|
||||||
class NetworkInterface {
|
class NetworkInterface {
|
||||||
@ -738,10 +732,8 @@ class VoiceMediaChannel : public MediaChannel {
|
|||||||
// Send and/or play a DTMF |event| according to the |flags|.
|
// Send and/or play a DTMF |event| according to the |flags|.
|
||||||
// The DTMF out-of-band signal will be used on sending.
|
// The DTMF out-of-band signal will be used on sending.
|
||||||
// The |ssrc| should be either 0 or a valid send stream ssrc.
|
// The |ssrc| should be either 0 or a valid send stream ssrc.
|
||||||
// The valid value for the |event| are -2 to 15.
|
// The valid value for the |event| are 0 to 15 which corresponding to
|
||||||
// kDtmfReset(-2) is used to reset the DTMF.
|
// DTMF event 0-9, *, #, A-D.
|
||||||
// kDtmfDelay(-1) is used to insert a delay to the end of the DTMF queue.
|
|
||||||
// 0 to 15 which corresponding to DTMF event 0-9, *, #, A-D.
|
|
||||||
virtual bool InsertDtmf(uint32 ssrc, int event, int duration, int flags) = 0;
|
virtual bool InsertDtmf(uint32 ssrc, int event, int duration, int flags) = 0;
|
||||||
// Gets quality stats for the channel.
|
// Gets quality stats for the channel.
|
||||||
virtual bool GetStats(VoiceMediaInfo* info) = 0;
|
virtual bool GetStats(VoiceMediaInfo* info) = 0;
|
||||||
|
@ -140,7 +140,8 @@ class RtpDataMediaChannelTest : public testing::Test {
|
|||||||
|
|
||||||
std::string GetSentData(int index) {
|
std::string GetSentData(int index) {
|
||||||
// Assume RTP header of length 12
|
// Assume RTP header of length 12
|
||||||
const talk_base::Buffer* packet = iface_->GetRtpPacket(index);
|
talk_base::scoped_ptr<const talk_base::Buffer> packet(
|
||||||
|
iface_->GetRtpPacket(index));
|
||||||
if (packet->length() > 12) {
|
if (packet->length() > 12) {
|
||||||
return std::string(packet->data() + 12, packet->length() - 12);
|
return std::string(packet->data() + 12, packet->length() - 12);
|
||||||
} else {
|
} else {
|
||||||
@ -149,7 +150,8 @@ class RtpDataMediaChannelTest : public testing::Test {
|
|||||||
}
|
}
|
||||||
|
|
||||||
cricket::RtpHeader GetSentDataHeader(int index) {
|
cricket::RtpHeader GetSentDataHeader(int index) {
|
||||||
const talk_base::Buffer* packet = iface_->GetRtpPacket(index);
|
talk_base::scoped_ptr<const talk_base::Buffer> packet(
|
||||||
|
iface_->GetRtpPacket(index));
|
||||||
cricket::RtpHeader header;
|
cricket::RtpHeader header;
|
||||||
GetRtpHeader(packet->data(), packet->length(), &header);
|
GetRtpHeader(packet->data(), packet->length(), &header);
|
||||||
return header;
|
return header;
|
||||||
|
@ -708,6 +708,10 @@ class FakeWebRtcVideoEngine
|
|||||||
WEBRTC_STUB(DeregisterDecoderObserver, (const int));
|
WEBRTC_STUB(DeregisterDecoderObserver, (const int));
|
||||||
WEBRTC_STUB(SendKeyFrame, (const int));
|
WEBRTC_STUB(SendKeyFrame, (const int));
|
||||||
WEBRTC_STUB(WaitForFirstKeyFrame, (const int, const bool));
|
WEBRTC_STUB(WaitForFirstKeyFrame, (const int, const bool));
|
||||||
|
#ifdef USE_WEBRTC_DEV_BRANCH
|
||||||
|
WEBRTC_STUB(StartDebugRecording, (int, const char*));
|
||||||
|
WEBRTC_STUB(StopDebugRecording, (int));
|
||||||
|
#endif
|
||||||
|
|
||||||
// webrtc::ViECapture
|
// webrtc::ViECapture
|
||||||
WEBRTC_STUB(NumberOfCaptureDevices, ());
|
WEBRTC_STUB(NumberOfCaptureDevices, ());
|
||||||
|
@ -2290,12 +2290,6 @@ bool WebRtcVoiceMediaChannel::InsertDtmf(uint32 ssrc, int event,
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO(ronghuawu): Remove this once the reset and delay are supported by VoE.
|
|
||||||
// https://code.google.com/p/webrtc/issues/detail?id=747
|
|
||||||
if (event == kDtmfReset || event == kDtmfDelay) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Send the event.
|
// Send the event.
|
||||||
if (flags & cricket::DF_SEND) {
|
if (flags & cricket::DF_SEND) {
|
||||||
if (send_ssrc_ != ssrc && ssrc != 0) {
|
if (send_ssrc_ != ssrc && ssrc != 0) {
|
||||||
|
@ -121,8 +121,11 @@ void TCPPort::PrepareAddress() {
|
|||||||
ICE_TYPE_PREFERENCE_HOST_TCP, true);
|
ICE_TYPE_PREFERENCE_HOST_TCP, true);
|
||||||
} else {
|
} else {
|
||||||
LOG_J(LS_INFO, this) << "Not listening due to firewall restrictions.";
|
LOG_J(LS_INFO, this) << "Not listening due to firewall restrictions.";
|
||||||
// Sending error signal as we can't allocate tcp candidate.
|
// Note: We still add the address, since otherwise the remote side won't
|
||||||
SignalPortError(this);
|
// recognize our incoming TCP connections.
|
||||||
|
AddAddress(talk_base::SocketAddress(ip(), 0),
|
||||||
|
talk_base::SocketAddress(ip(), 0), TCP_PROTOCOL_NAME,
|
||||||
|
LOCAL_PORT_TYPE, ICE_TYPE_PREFERENCE_HOST_TCP, true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -505,18 +505,6 @@ TEST_F(PortAllocatorTest, TestGetAllPortsNoSockets) {
|
|||||||
// There is no error reporting from RelayEntry to handle this failure.
|
// There is no error reporting from RelayEntry to handle this failure.
|
||||||
}
|
}
|
||||||
|
|
||||||
TEST_F(PortAllocatorTest, TestTcpPortNoListenAllowed) {
|
|
||||||
AddInterface(kClientAddr);
|
|
||||||
allocator().set_flags(cricket::PORTALLOCATOR_DISABLE_UDP |
|
|
||||||
cricket::PORTALLOCATOR_DISABLE_STUN |
|
|
||||||
cricket::PORTALLOCATOR_DISABLE_RELAY);
|
|
||||||
allocator().set_allow_tcp_listen(false);
|
|
||||||
EXPECT_TRUE(CreateSession(cricket::ICE_CANDIDATE_COMPONENT_RTP));
|
|
||||||
session_->StartGettingPorts();
|
|
||||||
EXPECT_TRUE_WAIT(candidate_allocation_done_, kDefaultAllocationTimeout);
|
|
||||||
EXPECT_TRUE(candidates_.empty());
|
|
||||||
}
|
|
||||||
|
|
||||||
// Testing STUN timeout.
|
// Testing STUN timeout.
|
||||||
TEST_F(PortAllocatorTest, TestGetAllPortsNoUdpAllowed) {
|
TEST_F(PortAllocatorTest, TestGetAllPortsNoUdpAllowed) {
|
||||||
fss_->AddRule(false, talk_base::FP_UDP, talk_base::FD_ANY, kClientAddr);
|
fss_->AddRule(false, talk_base::FP_UDP, talk_base::FD_ANY, kClientAddr);
|
||||||
|
@ -385,10 +385,8 @@ class VoiceChannel : public BaseChannel {
|
|||||||
// Send and/or play a DTMF |event| according to the |flags|.
|
// Send and/or play a DTMF |event| according to the |flags|.
|
||||||
// The DTMF out-of-band signal will be used on sending.
|
// The DTMF out-of-band signal will be used on sending.
|
||||||
// The |ssrc| should be either 0 or a valid send stream ssrc.
|
// The |ssrc| should be either 0 or a valid send stream ssrc.
|
||||||
// The valid value for the |event| are -2 to 15.
|
// The valid value for the |event| are 0 which corresponding to DTMF
|
||||||
// kDtmfReset(-2) is used to reset the DTMF.
|
// event 0-9, *, #, A-D.
|
||||||
// kDtmfDelay(-1) is used to insert a delay to the end of the DTMF queue.
|
|
||||||
// 0 to 15 which corresponding to DTMF event 0-9, *, #, A-D.
|
|
||||||
bool InsertDtmf(uint32 ssrc, int event_code, int duration, int flags);
|
bool InsertDtmf(uint32 ssrc, int event_code, int duration, int flags);
|
||||||
bool SetOutputScaling(uint32 ssrc, double left, double right);
|
bool SetOutputScaling(uint32 ssrc, double left, double right);
|
||||||
// Get statistics about the current media session.
|
// Get statistics about the current media session.
|
||||||
|
@ -57,8 +57,6 @@ using cricket::CA_PRANSWER;
|
|||||||
using cricket::CA_ANSWER;
|
using cricket::CA_ANSWER;
|
||||||
using cricket::CA_UPDATE;
|
using cricket::CA_UPDATE;
|
||||||
using cricket::FakeVoiceMediaChannel;
|
using cricket::FakeVoiceMediaChannel;
|
||||||
using cricket::kDtmfDelay;
|
|
||||||
using cricket::kDtmfReset;
|
|
||||||
using cricket::ScreencastId;
|
using cricket::ScreencastId;
|
||||||
using cricket::StreamParams;
|
using cricket::StreamParams;
|
||||||
using cricket::TransportChannel;
|
using cricket::TransportChannel;
|
||||||
@ -2221,23 +2219,17 @@ TEST_F(VoiceChannelTest, TestInsertDtmf) {
|
|||||||
EXPECT_TRUE(SendAccept());
|
EXPECT_TRUE(SendAccept());
|
||||||
EXPECT_EQ(0U, media_channel1_->dtmf_info_queue().size());
|
EXPECT_EQ(0U, media_channel1_->dtmf_info_queue().size());
|
||||||
|
|
||||||
EXPECT_TRUE(channel1_->InsertDtmf(-1, kDtmfReset, -1, cricket::DF_SEND));
|
|
||||||
EXPECT_TRUE(channel1_->InsertDtmf(0, kDtmfDelay, 90, cricket::DF_PLAY));
|
|
||||||
EXPECT_TRUE(channel1_->InsertDtmf(1, 3, 100, cricket::DF_SEND));
|
EXPECT_TRUE(channel1_->InsertDtmf(1, 3, 100, cricket::DF_SEND));
|
||||||
EXPECT_TRUE(channel1_->InsertDtmf(2, 5, 110, cricket::DF_PLAY));
|
EXPECT_TRUE(channel1_->InsertDtmf(2, 5, 110, cricket::DF_PLAY));
|
||||||
EXPECT_TRUE(channel1_->InsertDtmf(3, 7, 120,
|
EXPECT_TRUE(channel1_->InsertDtmf(3, 7, 120,
|
||||||
cricket::DF_PLAY | cricket::DF_SEND));
|
cricket::DF_PLAY | cricket::DF_SEND));
|
||||||
|
|
||||||
ASSERT_EQ(5U, media_channel1_->dtmf_info_queue().size());
|
ASSERT_EQ(3U, media_channel1_->dtmf_info_queue().size());
|
||||||
EXPECT_TRUE(CompareDtmfInfo(media_channel1_->dtmf_info_queue()[0],
|
EXPECT_TRUE(CompareDtmfInfo(media_channel1_->dtmf_info_queue()[0],
|
||||||
-1, kDtmfReset, -1, cricket::DF_SEND));
|
|
||||||
EXPECT_TRUE(CompareDtmfInfo(media_channel1_->dtmf_info_queue()[1],
|
|
||||||
0, kDtmfDelay, 90, cricket::DF_PLAY));
|
|
||||||
EXPECT_TRUE(CompareDtmfInfo(media_channel1_->dtmf_info_queue()[2],
|
|
||||||
1, 3, 100, cricket::DF_SEND));
|
1, 3, 100, cricket::DF_SEND));
|
||||||
EXPECT_TRUE(CompareDtmfInfo(media_channel1_->dtmf_info_queue()[3],
|
EXPECT_TRUE(CompareDtmfInfo(media_channel1_->dtmf_info_queue()[1],
|
||||||
2, 5, 110, cricket::DF_PLAY));
|
2, 5, 110, cricket::DF_PLAY));
|
||||||
EXPECT_TRUE(CompareDtmfInfo(media_channel1_->dtmf_info_queue()[4],
|
EXPECT_TRUE(CompareDtmfInfo(media_channel1_->dtmf_info_queue()[2],
|
||||||
3, 7, 120, cricket::DF_PLAY | cricket::DF_SEND));
|
3, 7, 120, cricket::DF_PLAY | cricket::DF_SEND));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user