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

Unified Diff: webrtc/voice_engine/voice_engine_impl.cc

Issue 1459083007: Open backdoor in VoiceEngineImpl to get at the actual voe::Channel objects from an ID. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: presubmit complaints Created 5 years, 1 month 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 | « webrtc/voice_engine/voice_engine_impl.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/voice_engine/voice_engine_impl.cc
diff --git a/webrtc/voice_engine/voice_engine_impl.cc b/webrtc/voice_engine/voice_engine_impl.cc
index 814d619589e755fd16b515b39519bbf34d29938e..d9c574457b0d21b9adda9b6f5dbf2fabe87d7bc9 100644
--- a/webrtc/voice_engine/voice_engine_impl.cc
+++ b/webrtc/voice_engine/voice_engine_impl.cc
@@ -15,8 +15,11 @@
#include "webrtc/modules/utility/include/jvm_android.h"
#endif
+#include "webrtc/base/checks.h"
#include "webrtc/modules/audio_coding/main/include/audio_coding_module.h"
+#include "webrtc/system_wrappers/include/critical_section_wrapper.h"
#include "webrtc/system_wrappers/include/trace.h"
+#include "webrtc/voice_engine/channel_proxy.h"
#include "webrtc/voice_engine/voice_engine_impl.h"
namespace webrtc {
@@ -77,6 +80,15 @@ int VoiceEngineImpl::Release() {
return new_ref;
}
+rtc::scoped_ptr<voe::ChannelProxy> VoiceEngineImpl::GetChannelProxy(
+ int channel_id) {
+ RTC_DCHECK(channel_id >= 0);
+ CriticalSectionScoped cs(crit_sec());
+ RTC_DCHECK(statistics().Initialized());
+ return rtc::scoped_ptr<voe::ChannelProxy>(
+ new voe::ChannelProxy(channel_manager().GetChannel(channel_id)));
+}
+
VoiceEngine* VoiceEngine::Create() {
Config* config = new Config();
return GetVoiceEngine(config, true);
« no previous file with comments | « webrtc/voice_engine/voice_engine_impl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698