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

Side by Side Diff: webrtc/api/peerconnectioninterface.h

Issue 2854123003: Build WebRTC with data channel only. (Closed)
Patch Set: Rebase. Created 3 years, 6 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 unified diff | Download patch
« no previous file with comments | « webrtc/api/mediastreaminterface.h ('k') | webrtc/call/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2012 The WebRTC project authors. All Rights Reserved. 2 * Copyright 2012 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 #include "webrtc/api/rtpsenderinterface.h" 83 #include "webrtc/api/rtpsenderinterface.h"
84 #include "webrtc/api/stats/rtcstatscollectorcallback.h" 84 #include "webrtc/api/stats/rtcstatscollectorcallback.h"
85 #include "webrtc/api/statstypes.h" 85 #include "webrtc/api/statstypes.h"
86 #include "webrtc/api/umametrics.h" 86 #include "webrtc/api/umametrics.h"
87 #include "webrtc/base/fileutils.h" 87 #include "webrtc/base/fileutils.h"
88 #include "webrtc/base/network.h" 88 #include "webrtc/base/network.h"
89 #include "webrtc/base/rtccertificate.h" 89 #include "webrtc/base/rtccertificate.h"
90 #include "webrtc/base/rtccertificategenerator.h" 90 #include "webrtc/base/rtccertificategenerator.h"
91 #include "webrtc/base/socketaddress.h" 91 #include "webrtc/base/socketaddress.h"
92 #include "webrtc/base/sslstreamadapter.h" 92 #include "webrtc/base/sslstreamadapter.h"
93 #include "webrtc/call/callfactoryinterface.h"
94 #include "webrtc/logging/rtc_event_log/rtc_event_log_factory_interface.h"
93 #include "webrtc/media/base/mediachannel.h" 95 #include "webrtc/media/base/mediachannel.h"
94 #include "webrtc/media/base/videocapturer.h" 96 #include "webrtc/media/base/videocapturer.h"
95 #include "webrtc/p2p/base/portallocator.h" 97 #include "webrtc/p2p/base/portallocator.h"
96 98
97 namespace rtc { 99 namespace rtc {
98 class SSLIdentity; 100 class SSLIdentity;
99 class Thread; 101 class Thread;
100 } 102 }
101 103
102 namespace cricket { 104 namespace cricket {
105 class MediaEngineInterface;
103 class WebRtcVideoDecoderFactory; 106 class WebRtcVideoDecoderFactory;
104 class WebRtcVideoEncoderFactory; 107 class WebRtcVideoEncoderFactory;
105 } 108 }
106 109
107 namespace webrtc { 110 namespace webrtc {
108 class AudioDeviceModule; 111 class AudioDeviceModule;
109 class AudioMixer; 112 class AudioMixer;
113 class CallFactoryInterface;
110 class MediaConstraintsInterface; 114 class MediaConstraintsInterface;
111 115
112 // MediaStream container interface. 116 // MediaStream container interface.
113 class StreamCollectionInterface : public rtc::RefCountInterface { 117 class StreamCollectionInterface : public rtc::RefCountInterface {
114 public: 118 public:
115 // TODO(ronghuawu): Update the function names to c++ style, e.g. find -> Find. 119 // TODO(ronghuawu): Update the function names to c++ style, e.g. find -> Find.
116 virtual size_t count() = 0; 120 virtual size_t count() = 0;
117 virtual MediaStreamInterface* at(size_t index) = 0; 121 virtual MediaStreamInterface* at(size_t index) = 0;
118 virtual MediaStreamInterface* find(const std::string& label) = 0; 122 virtual MediaStreamInterface* find(const std::string& label) = 0;
119 virtual MediaStreamTrackInterface* FindAudioTrack( 123 virtual MediaStreamTrackInterface* FindAudioTrack(
(...skipping 999 matching lines...) Expand 10 before | Expand all | Expand 10 after
1119 rtc::Thread* worker_and_network_thread, 1123 rtc::Thread* worker_and_network_thread,
1120 rtc::Thread* signaling_thread, 1124 rtc::Thread* signaling_thread,
1121 AudioDeviceModule* default_adm, 1125 AudioDeviceModule* default_adm,
1122 cricket::WebRtcVideoEncoderFactory* encoder_factory, 1126 cricket::WebRtcVideoEncoderFactory* encoder_factory,
1123 cricket::WebRtcVideoDecoderFactory* decoder_factory) { 1127 cricket::WebRtcVideoDecoderFactory* decoder_factory) {
1124 return CreatePeerConnectionFactory( 1128 return CreatePeerConnectionFactory(
1125 worker_and_network_thread, worker_and_network_thread, signaling_thread, 1129 worker_and_network_thread, worker_and_network_thread, signaling_thread,
1126 default_adm, encoder_factory, decoder_factory); 1130 default_adm, encoder_factory, decoder_factory);
1127 } 1131 }
1128 1132
1133 // This is a lower-level version of the CreatePeerConnectionFactory functions
1134 // above. It's implemented in the "peerconnection" build target, whereas the
1135 // above methods are only implemented in the broader "libjingle_peerconnection"
1136 // build target, which pulls in the implementations of every module webrtc may
1137 // use.
1138 //
1139 // If an application knows it will only require certain modules, it can reduce
1140 // webrtc's impact on its binary size by depending only on the "peerconnection"
1141 // target and the modules the application requires, using
1142 // CreateModularPeerConnectionFactory instead of one of the
1143 // CreatePeerConnectionFactory methods above. For example, if an application
1144 // only uses WebRTC for audio, it can pass in null pointers for the
1145 // video-specific interfaces, and omit the corresponding modules from its
1146 // build.
1147 //
1148 // If |network_thread| or |worker_thread| are null, the PeerConnectionFactory
1149 // will create the necessary thread internally. If |signaling_thread| is null,
1150 // the PeerConnectionFactory will use the thread on which this method is called
1151 // as the signaling thread, wrapping it in an rtc::Thread object if needed.
1152 //
1153 // If non-null, a reference is added to |default_adm|, and ownership of
1154 // |video_encoder_factory| and |video_decoder_factory| is transferred to the
1155 // returned factory.
1156 //
1157 // TODO(deadbeef): Use rtc::scoped_refptr<> and std::unique_ptr<> to make this
1158 // ownership transfer and ref counting more obvious.
1159 //
1160 // TODO(deadbeef): Encapsulate these modules in a struct, so that when a new
1161 // module is inevitably exposed, we can just add a field to the struct instead
1162 // of adding a whole new CreateModularPeerConnectionFactory overload.
1163 rtc::scoped_refptr<PeerConnectionFactoryInterface>
1164 CreateModularPeerConnectionFactory(
1165 rtc::Thread* network_thread,
1166 rtc::Thread* worker_thread,
1167 rtc::Thread* signaling_thread,
1168 AudioDeviceModule* default_adm,
1169 rtc::scoped_refptr<AudioEncoderFactory> audio_encoder_factory,
1170 rtc::scoped_refptr<AudioDecoderFactory> audio_decoder_factory,
1171 cricket::WebRtcVideoEncoderFactory* video_encoder_factory,
1172 cricket::WebRtcVideoDecoderFactory* video_decoder_factory,
1173 rtc::scoped_refptr<AudioMixer> audio_mixer,
1174 std::unique_ptr<cricket::MediaEngineInterface> media_engine,
1175 std::unique_ptr<CallFactoryInterface> call_factory,
1176 std::unique_ptr<RtcEventLogFactoryInterface> event_log_factory);
1177
1129 } // namespace webrtc 1178 } // namespace webrtc
1130 1179
1131 #endif // WEBRTC_API_PEERCONNECTIONINTERFACE_H_ 1180 #endif // WEBRTC_API_PEERCONNECTIONINTERFACE_H_
OLDNEW
« no previous file with comments | « webrtc/api/mediastreaminterface.h ('k') | webrtc/call/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698