Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1438)

Unified Diff: remoting/protocol/webrtc_transport.cc

Issue 2394433003: Add WebrtcAudioModule (Closed)
Patch Set: Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « remoting/protocol/webrtc_transport.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/protocol/webrtc_transport.cc
diff --git a/remoting/protocol/webrtc_transport.cc b/remoting/protocol/webrtc_transport.cc
index e13544ecadb0a600a7cb45ef8b64cee3f99d9473..b3f759ac652728238ec39569e5ad9ce69f814dce 100644
--- a/remoting/protocol/webrtc_transport.cc
+++ b/remoting/protocol/webrtc_transport.cc
@@ -24,10 +24,10 @@
#include "remoting/protocol/port_allocator_factory.h"
#include "remoting/protocol/stream_message_pipe_adapter.h"
#include "remoting/protocol/transport_context.h"
+#include "remoting/protocol/webrtc_audio_module.h"
#include "remoting/protocol/webrtc_dummy_video_encoder.h"
#include "third_party/webrtc/api/test/fakeconstraints.h"
#include "third_party/webrtc/libjingle/xmllite/xmlelement.h"
-#include "third_party/webrtc/modules/audio_device/include/fake_audio_device.h"
using buzz::QName;
using buzz::XmlElement;
@@ -146,8 +146,11 @@ class WebrtcTransport::PeerConnectionWrapper
std::unique_ptr<cricket::PortAllocator> port_allocator,
base::WeakPtr<WebrtcTransport> transport)
: transport_(transport) {
+ scoped_refptr<WebrtcAudioModule> audio_module =
+ new rtc::RefCountedObject<WebrtcAudioModule>();
+
peer_connection_factory_ = webrtc::CreatePeerConnectionFactory(
- worker_thread, rtc::Thread::Current(), &fake_audio_device_module_,
+ worker_thread, rtc::Thread::Current(), audio_module.get(),
encoder_factory.release(), nullptr);
webrtc::FakeConstraints constraints;
@@ -208,7 +211,7 @@ class WebrtcTransport::PeerConnectionWrapper
}
private:
- webrtc::FakeAudioDeviceModule fake_audio_device_module_;
+ scoped_refptr<WebrtcAudioModule> audio_module_;
scoped_refptr<webrtc::PeerConnectionFactoryInterface>
peer_connection_factory_;
scoped_refptr<webrtc::PeerConnectionInterface> peer_connection_;
« no previous file with comments | « remoting/protocol/webrtc_transport.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698