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

Side by Side Diff: webrtc/sdk/objc/Framework/Classes/PeerConnection/RTCPeerConnectionFactory.mm

Issue 2987143003: Remove RTCAVFoundationVideoSource
Patch Set: Created 3 years, 4 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
OLDNEW
1 /* 1 /*
2 * Copyright 2015 The WebRTC project authors. All Rights Reserved. 2 * Copyright 2015 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
11 #import "RTCPeerConnectionFactory+Private.h" 11 #import "RTCPeerConnectionFactory+Private.h"
12 12
13 #import "NSString+StdString.h" 13 #import "NSString+StdString.h"
14 #import "RTCAVFoundationVideoSource+Private.h"
15 #import "RTCAudioSource+Private.h" 14 #import "RTCAudioSource+Private.h"
16 #import "RTCAudioTrack+Private.h" 15 #import "RTCAudioTrack+Private.h"
17 #import "RTCMediaConstraints+Private.h" 16 #import "RTCMediaConstraints+Private.h"
18 #import "RTCMediaStream+Private.h" 17 #import "RTCMediaStream+Private.h"
19 #import "RTCPeerConnection+Private.h" 18 #import "RTCPeerConnection+Private.h"
20 #import "RTCVideoSource+Private.h" 19 #import "RTCVideoSource+Private.h"
21 #import "RTCVideoTrack+Private.h" 20 #import "RTCVideoTrack+Private.h"
22 #import "WebRTC/RTCLogging.h" 21 #import "WebRTC/RTCLogging.h"
23 #import "WebRTC/RTCVideoCodecFactory.h" 22 #import "WebRTC/RTCVideoCodecFactory.h"
24 #ifndef HAVE_NO_MEDIA 23 #ifndef HAVE_NO_MEDIA
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
121 return [self audioTrackWithSource:audioSource trackId:trackId]; 120 return [self audioTrackWithSource:audioSource trackId:trackId];
122 } 121 }
123 122
124 - (RTCAudioTrack *)audioTrackWithSource:(RTCAudioSource *)source 123 - (RTCAudioTrack *)audioTrackWithSource:(RTCAudioSource *)source
125 trackId:(NSString *)trackId { 124 trackId:(NSString *)trackId {
126 return [[RTCAudioTrack alloc] initWithFactory:self 125 return [[RTCAudioTrack alloc] initWithFactory:self
127 source:source 126 source:source
128 trackId:trackId]; 127 trackId:trackId];
129 } 128 }
130 129
131 - (RTCAVFoundationVideoSource *)avFoundationVideoSourceWithConstraints:
132 (nullable RTCMediaConstraints *)constraints {
133 #ifdef HAVE_NO_MEDIA
134 return nil;
135 #else
136 return [[RTCAVFoundationVideoSource alloc] initWithFactory:self constraints:co nstraints];
137 #endif
138 }
139
140 - (RTCVideoSource *)videoSource { 130 - (RTCVideoSource *)videoSource {
141 rtc::scoped_refptr<webrtc::ObjcVideoTrackSource> objcVideoTrackSource( 131 rtc::scoped_refptr<webrtc::ObjcVideoTrackSource> objcVideoTrackSource(
142 new rtc::RefCountedObject<webrtc::ObjcVideoTrackSource>()); 132 new rtc::RefCountedObject<webrtc::ObjcVideoTrackSource>());
143 return [[RTCVideoSource alloc] 133 return [[RTCVideoSource alloc]
144 initWithNativeVideoSource:webrtc::VideoTrackSourceProxy::Create(_signaling Thread.get(), 134 initWithNativeVideoSource:webrtc::VideoTrackSourceProxy::Create(_signaling Thread.get(),
145 _workerThr ead.get(), 135 _workerThr ead.get(),
146 objcVideoT rackSource)]; 136 objcVideoT rackSource)];
147 } 137 }
148 138
149 - (RTCVideoTrack *)videoTrackWithSource:(RTCVideoSource *)source 139 - (RTCVideoTrack *)videoTrackWithSource:(RTCVideoSource *)source
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
187 _hasStartedAecDump = _nativeFactory->StartAecDump(fd, maxSizeInBytes); 177 _hasStartedAecDump = _nativeFactory->StartAecDump(fd, maxSizeInBytes);
188 return _hasStartedAecDump; 178 return _hasStartedAecDump;
189 } 179 }
190 180
191 - (void)stopAecDump { 181 - (void)stopAecDump {
192 _nativeFactory->StopAecDump(); 182 _nativeFactory->StopAecDump();
193 _hasStartedAecDump = NO; 183 _hasStartedAecDump = NO;
194 } 184 }
195 185
196 @end 186 @end
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698