Skip to content

Commit 1ae5859

Browse files
hiroshihorienpazkevich
authored andcommitted
Allow custom audio processing by exposing AudioProcessingModule (webrtc-sdk#85)
* apm * progress * expose raw buffer * config * runtime delegate update * always create audio processing adapter * delegate nullable * dynamic delegate update thread safety * fix delegate life cycle when swapped * refactor * avoid crash when no apm is passed in * format * make delegate weak & docs * fix memory issue
1 parent f4d37c7 commit 1ae5859

File tree

2 files changed

+1
-6
lines changed

2 files changed

+1
-6
lines changed

sdk/objc/api/peerconnection/RTCAudioTrack.mm

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -212,6 +212,7 @@ - (instancetype)initWithFactory:(RTC_OBJC_TYPE(RTCPeerConnectionFactory) *)facto
212212
NSParameterAssert(type == RTCMediaStreamTrackTypeAudio);
213213
if (self = [super initWithFactory:factory nativeTrack:nativeTrack type:type]) {
214214
RTC_LOG(LS_INFO) << "RTCAudioTrack init";
215+
_lock = OS_UNFAIR_LOCK_INIT;
215216
_renderers = [NSHashTable weakObjectsHashTable];
216217
_audioConverter = new rtc::RefCountedObject<webrtc::AudioSinkConverter>(self, &_lock);
217218
}

sdk/objc/api/peerconnection/RTCPeerConnectionFactory+Native.h

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -73,12 +73,6 @@ NS_ASSUME_NONNULL_BEGIN
7373
initWithEncoderFactory:(nullable id<RTC_OBJC_TYPE(RTCVideoEncoderFactory)>)encoderFactory
7474
decoderFactory:(nullable id<RTC_OBJC_TYPE(RTCVideoDecoderFactory)>)decoderFactory;
7575

76-
- (instancetype)
77-
initWithBypassVoiceProcessing:(BOOL)bypassVoiceProcessing
78-
encoderFactory:(nullable id<RTC_OBJC_TYPE(RTCVideoEncoderFactory)>)encoderFactory
79-
decoderFactory:
80-
(nullable id<RTC_OBJC_TYPE(RTCVideoDecoderFactory)>)decoderFactory;
81-
8276
/** Initialize an RTCPeerConnection with a configuration, constraints, and
8377
* dependencies.
8478
*/

0 commit comments

Comments
 (0)