Skip to content

Commit

Permalink
85.0.4183.4
Browse files Browse the repository at this point in the history
  • Loading branch information
wenxin3262 committed Sep 20, 2020
1 parent 63497ff commit dedf7b7
Show file tree
Hide file tree
Showing 82 changed files with 546 additions and 422 deletions.
68 changes: 37 additions & 31 deletions WebRTC.framework/Headers/RTCAudioSession.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,78 +21,81 @@ extern NSInteger const kRTCAudioSessionErrorLockRequired;
/** Unknown configuration error occurred. */
extern NSInteger const kRTCAudioSessionErrorConfiguration;

@class RTCAudioSession;
@class RTCAudioSessionConfiguration;
@class RTC_OBJC_TYPE(RTCAudioSession);
@class RTC_OBJC_TYPE(RTCAudioSessionConfiguration);

// Surfaces AVAudioSession events. WebRTC will listen directly for notifications
// from AVAudioSession and handle them before calling these delegate methods,
// at which point applications can perform additional processing if required.
RTC_OBJC_EXPORT
@protocol RTCAudioSessionDelegate <NSObject>
@protocol RTC_OBJC_TYPE
(RTCAudioSessionDelegate)<NSObject>

@optional
@optional
/** Called on a system notification thread when AVAudioSession starts an
* interruption event.
*/
- (void)audioSessionDidBeginInterruption:(RTCAudioSession *)session;
- (void)audioSessionDidBeginInterruption:(RTC_OBJC_TYPE(RTCAudioSession) *)session;

/** Called on a system notification thread when AVAudioSession ends an
* interruption event.
*/
- (void)audioSessionDidEndInterruption:(RTCAudioSession *)session
- (void)audioSessionDidEndInterruption:(RTC_OBJC_TYPE(RTCAudioSession) *)session
shouldResumeSession:(BOOL)shouldResumeSession;

/** Called on a system notification thread when AVAudioSession changes the
* route.
*/
- (void)audioSessionDidChangeRoute:(RTCAudioSession *)session
- (void)audioSessionDidChangeRoute:(RTC_OBJC_TYPE(RTCAudioSession) *)session
reason:(AVAudioSessionRouteChangeReason)reason
previousRoute:(AVAudioSessionRouteDescription *)previousRoute;

/** Called on a system notification thread when AVAudioSession media server
* terminates.
*/
- (void)audioSessionMediaServerTerminated:(RTCAudioSession *)session;
- (void)audioSessionMediaServerTerminated:(RTC_OBJC_TYPE(RTCAudioSession) *)session;

/** Called on a system notification thread when AVAudioSession media server
* restarts.
*/
- (void)audioSessionMediaServerReset:(RTCAudioSession *)session;
- (void)audioSessionMediaServerReset:(RTC_OBJC_TYPE(RTCAudioSession) *)session;

// TODO(tkchin): Maybe handle SilenceSecondaryAudioHintNotification.

- (void)audioSession:(RTCAudioSession *)session didChangeCanPlayOrRecord:(BOOL)canPlayOrRecord;
- (void)audioSession:(RTC_OBJC_TYPE(RTCAudioSession) *)session
didChangeCanPlayOrRecord:(BOOL)canPlayOrRecord;

/** Called on a WebRTC thread when the audio device is notified to begin
* playback or recording.
*/
- (void)audioSessionDidStartPlayOrRecord:(RTCAudioSession *)session;
- (void)audioSessionDidStartPlayOrRecord:(RTC_OBJC_TYPE(RTCAudioSession) *)session;

/** Called on a WebRTC thread when the audio device is notified to stop
* playback or recording.
*/
- (void)audioSessionDidStopPlayOrRecord:(RTCAudioSession *)session;
- (void)audioSessionDidStopPlayOrRecord:(RTC_OBJC_TYPE(RTCAudioSession) *)session;

/** Called when the AVAudioSession output volume value changes. */
- (void)audioSession:(RTCAudioSession *)audioSession didChangeOutputVolume:(float)outputVolume;
- (void)audioSession:(RTC_OBJC_TYPE(RTCAudioSession) *)audioSession
didChangeOutputVolume:(float)outputVolume;

/** Called when the audio device detects a playout glitch. The argument is the
* number of glitches detected so far in the current audio playout session.
*/
- (void)audioSession:(RTCAudioSession *)audioSession
- (void)audioSession:(RTC_OBJC_TYPE(RTCAudioSession) *)audioSession
didDetectPlayoutGlitch:(int64_t)totalNumberOfGlitches;

/** Called when the audio session is about to change the active state.
*/
- (void)audioSession:(RTCAudioSession *)audioSession willSetActive:(BOOL)active;
- (void)audioSession:(RTC_OBJC_TYPE(RTCAudioSession) *)audioSession willSetActive:(BOOL)active;

/** Called after the audio session sucessfully changed the active state.
*/
- (void)audioSession:(RTCAudioSession *)audioSession didSetActive:(BOOL)active;
- (void)audioSession:(RTC_OBJC_TYPE(RTCAudioSession) *)audioSession didSetActive:(BOOL)active;

/** Called after the audio session failed to change the active state.
*/
- (void)audioSession:(RTCAudioSession *)audioSession
- (void)audioSession:(RTC_OBJC_TYPE(RTCAudioSession) *)audioSession
failedToSetActive:(BOOL)active
error:(NSError *)error;

Expand All @@ -103,10 +106,11 @@ RTC_OBJC_EXPORT
* case of this is when CallKit activates the audio session for the application
*/
RTC_OBJC_EXPORT
@protocol RTCAudioSessionActivationDelegate <NSObject>
@protocol RTC_OBJC_TYPE
(RTCAudioSessionActivationDelegate)<NSObject>

/** Called when the audio session is activated outside of the app by iOS. */
- (void)audioSessionDidActivate:(AVAudioSession *)session;
/** Called when the audio session is activated outside of the app by iOS. */
- (void)audioSessionDidActivate : (AVAudioSession *)session;

/** Called when the audio session is deactivated outside of the app by iOS. */
- (void)audioSessionDidDeactivate:(AVAudioSession *)session;
Expand All @@ -121,7 +125,7 @@ RTC_OBJC_EXPORT
* activated only once. See |setActive:error:|.
*/
RTC_OBJC_EXPORT
@interface RTCAudioSession : NSObject <RTCAudioSessionActivationDelegate>
@interface RTC_OBJC_TYPE (RTCAudioSession) : NSObject <RTC_OBJC_TYPE(RTCAudioSessionActivationDelegate)>

/** Convenience property to access the AVAudioSession singleton. Callers should
* not call setters on AVAudioSession directly, but other method invocations
Expand Down Expand Up @@ -196,9 +200,9 @@ RTC_OBJC_EXPORT
- (instancetype)init NS_UNAVAILABLE;

/** Adds a delegate, which is held weakly. */
- (void)addDelegate:(id<RTCAudioSessionDelegate>)delegate;
- (void)addDelegate:(id<RTC_OBJC_TYPE(RTCAudioSessionDelegate)>)delegate;
/** Removes an added delegate. */
- (void)removeDelegate:(id<RTCAudioSessionDelegate>)delegate;
- (void)removeDelegate:(id<RTC_OBJC_TYPE(RTCAudioSessionDelegate)>)delegate;

/** Request exclusive access to the audio session for configuration. This call
* will block if the lock is held by another object.
Expand Down Expand Up @@ -237,19 +241,21 @@ RTC_OBJC_EXPORT
error:(NSError **)outError;
@end

@interface RTCAudioSession (Configuration)
@interface RTC_OBJC_TYPE (RTCAudioSession)
(Configuration)

/** Applies the configuration to the current session. Attempts to set all
* properties even if previous ones fail. Only the last error will be
* returned.
* |lockForConfiguration| must be called first.
*/
- (BOOL)setConfiguration:(RTCAudioSessionConfiguration *)configuration error:(NSError **)outError;
/** Applies the configuration to the current session. Attempts to set all
* properties even if previous ones fail. Only the last error will be
* returned.
* |lockForConfiguration| must be called first.
*/
- (BOOL)setConfiguration : (RTC_OBJC_TYPE(RTCAudioSessionConfiguration) *)configuration error
: (NSError **)outError;

/** Convenience method that calls both setConfiguration and setActive.
* |lockForConfiguration| must be called first.
*/
- (BOOL)setConfiguration:(RTCAudioSessionConfiguration *)configuration
- (BOOL)setConfiguration:(RTC_OBJC_TYPE(RTCAudioSessionConfiguration) *)configuration
active:(BOOL)active
error:(NSError **)outError;

Expand Down
4 changes: 2 additions & 2 deletions WebRTC.framework/Headers/RTCAudioSessionConfiguration.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ RTC_EXTERN const double kRTCAudioSessionLowComplexityIOBufferDuration;

// Struct to hold configuration values.
RTC_OBJC_EXPORT
@interface RTCAudioSessionConfiguration : NSObject
@interface RTC_OBJC_TYPE (RTCAudioSessionConfiguration) : NSObject

@property(nonatomic, strong) NSString *category;
@property(nonatomic, assign) AVAudioSessionCategoryOptions categoryOptions;
Expand All @@ -41,7 +41,7 @@ RTC_OBJC_EXPORT
/** Returns the configuration that WebRTC needs. */
+ (instancetype)webRTCConfiguration;
/** Provide a way to override the default configuration. */
+ (void)setWebRTCConfiguration:(RTCAudioSessionConfiguration *)configuration;
+ (void)setWebRTCConfiguration:(RTC_OBJC_TYPE(RTCAudioSessionConfiguration) *)configuration;

@end

Expand Down
2 changes: 1 addition & 1 deletion WebRTC.framework/Headers/RTCAudioSource.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
NS_ASSUME_NONNULL_BEGIN

RTC_OBJC_EXPORT
@interface RTCAudioSource : RTCMediaSource
@interface RTC_OBJC_TYPE (RTCAudioSource) : RTC_OBJC_TYPE(RTCMediaSource)

- (instancetype)init NS_UNAVAILABLE;

Expand Down
6 changes: 3 additions & 3 deletions WebRTC.framework/Headers/RTCAudioTrack.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,15 @@

NS_ASSUME_NONNULL_BEGIN

@class RTCAudioSource;
@class RTC_OBJC_TYPE(RTCAudioSource);

RTC_OBJC_EXPORT
@interface RTCAudioTrack : RTCMediaStreamTrack
@interface RTC_OBJC_TYPE (RTCAudioTrack) : RTC_OBJC_TYPE(RTCMediaStreamTrack)

- (instancetype)init NS_UNAVAILABLE;

/** The audio source for this audio track. */
@property(nonatomic, readonly) RTCAudioSource *source;
@property(nonatomic, readonly) RTC_OBJC_TYPE(RTCAudioSource) * source;

@end

Expand Down
2 changes: 1 addition & 1 deletion WebRTC.framework/Headers/RTCCVPixelBuffer.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ NS_ASSUME_NONNULL_BEGIN

/** RTCVideoFrameBuffer containing a CVPixelBufferRef */
RTC_OBJC_EXPORT
@interface RTCCVPixelBuffer : NSObject <RTCVideoFrameBuffer>
@interface RTC_OBJC_TYPE (RTCCVPixelBuffer) : NSObject <RTC_OBJC_TYPE(RTCVideoFrameBuffer)>

@property(nonatomic, readonly) CVPixelBufferRef pixelBuffer;
@property(nonatomic, readonly) int cropX;
Expand Down
2 changes: 1 addition & 1 deletion WebRTC.framework/Headers/RTCCallbackLogger.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ typedef void (^RTCCallbackLoggerMessageAndSeverityHandler)(NSString *message,
// This class intercepts WebRTC logs and forwards them to a registered block.
// This class is not threadsafe.
RTC_OBJC_EXPORT
@interface RTCCallbackLogger : NSObject
@interface RTC_OBJC_TYPE (RTCCallbackLogger) : NSObject

// The severity level to capture. The default is kRTCLoggingSeverityInfo.
@property(nonatomic, assign) RTCLoggingSeverity severity;
Expand Down
2 changes: 1 addition & 1 deletion WebRTC.framework/Headers/RTCCameraPreviewView.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
* AVCaptureSession.
*/
RTC_OBJC_EXPORT
@interface RTCCameraPreviewView : UIView
@interface RTC_OBJC_TYPE (RTCCameraPreviewView) : UIView

/** The capture session being rendered in the view. Capture session
* is assigned to AVCaptureVideoPreviewLayer async in the same
Expand Down
6 changes: 3 additions & 3 deletions WebRTC.framework/Headers/RTCCameraVideoCapturer.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@
NS_ASSUME_NONNULL_BEGIN

RTC_OBJC_EXPORT
// Camera capture that implements RTCVideoCapturer. Delivers frames to a RTCVideoCapturerDelegate
// (usually RTCVideoSource).
// Camera capture that implements RTCVideoCapturer. Delivers frames to a
// RTCVideoCapturerDelegate (usually RTCVideoSource).
NS_EXTENSION_UNAVAILABLE_IOS("Camera not available in app extensions.")
@interface RTCCameraVideoCapturer : RTCVideoCapturer
@interface RTC_OBJC_TYPE (RTCCameraVideoCapturer) : RTC_OBJC_TYPE(RTCVideoCapturer)

// Capture session that is used for capturing. Valid from initialization to dealloc.
@property(readonly, nonatomic) AVCaptureSession *captureSession;
Expand Down
4 changes: 2 additions & 2 deletions WebRTC.framework/Headers/RTCCertificate.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
NS_ASSUME_NONNULL_BEGIN

RTC_OBJC_EXPORT
@interface RTCCertificate : NSObject <NSCopying>
@interface RTC_OBJC_TYPE (RTCCertificate) : NSObject <NSCopying>

/** Private key in PEM. */
@property(nonatomic, readonly, copy) NSString *private_key;
Expand All @@ -37,7 +37,7 @@ RTC_OBJC_EXPORT
* provided.
* - name: "ECDSA" or "RSASSA-PKCS1-v1_5"
*/
+ (nullable RTCCertificate *)generateCertificateWithParams:(NSDictionary *)params;
+ (nullable RTC_OBJC_TYPE(RTCCertificate) *)generateCertificateWithParams:(NSDictionary *)params;

@end

Expand Down
4 changes: 2 additions & 2 deletions WebRTC.framework/Headers/RTCCodecSpecificInfo.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ NS_ASSUME_NONNULL_BEGIN
* Corresponds to webrtc::CodecSpecificInfo.
*/
RTC_OBJC_EXPORT
@protocol RTCCodecSpecificInfo <NSObject>
@end
@protocol RTC_OBJC_TYPE
(RTCCodecSpecificInfo)<NSObject> @end

NS_ASSUME_NONNULL_END
2 changes: 1 addition & 1 deletion WebRTC.framework/Headers/RTCCodecSpecificInfoH264.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ typedef NS_ENUM(NSUInteger, RTCH264PacketizationMode) {
};

RTC_OBJC_EXPORT
@interface RTCCodecSpecificInfoH264 : NSObject <RTCCodecSpecificInfo>
@interface RTC_OBJC_TYPE (RTCCodecSpecificInfoH264) : NSObject <RTC_OBJC_TYPE(RTCCodecSpecificInfo)>

@property(nonatomic, assign) RTCH264PacketizationMode packetizationMode;

Expand Down
28 changes: 8 additions & 20 deletions WebRTC.framework/Headers/RTCConfiguration.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
#import "RTCCryptoOptions.h"
#import "RTCMacros.h"

@class RTCIceServer;
@class RTC_OBJC_TYPE(RTCIceServer);

/**
* Represents the ice transport policy. This exposes the same states in C++,
Expand Down Expand Up @@ -70,18 +70,18 @@ typedef NS_ENUM(NSInteger, RTCSdpSemantics) {
NS_ASSUME_NONNULL_BEGIN

RTC_OBJC_EXPORT
@interface RTCConfiguration : NSObject
@interface RTC_OBJC_TYPE (RTCConfiguration) : NSObject

/** If true, allows DSCP codes to be set on outgoing packets, configured using
* networkPriority field of RTCRtpEncodingParameters. Defaults to false.
*/
@property(nonatomic, assign) BOOL enableDscp;

/** An array of Ice Servers available to be used by ICE. */
@property(nonatomic, copy) NSArray<RTCIceServer *> *iceServers;
@property(nonatomic, copy) NSArray<RTC_OBJC_TYPE(RTCIceServer) *> *iceServers;

/** An RTCCertificate for 're' use. */
@property(nonatomic, nullable) RTCCertificate *certificate;
@property(nonatomic, nullable) RTC_OBJC_TYPE(RTCCertificate) * certificate;

/** Which candidates the ICE agent is allowed to use. The W3C calls it
* |iceTransportPolicy|, while in C++ it is called |type|. */
Expand Down Expand Up @@ -173,9 +173,9 @@ RTC_OBJC_EXPORT
*
* UnifiedPlan will cause RTCPeerConnection to create offers and answers with
* multiple m= sections where each m= section maps to one RTCRtpSender and one
* RTCRtpReceiver (an RTCRtpTransceiver), either both audio or both video. This
* will also cause RTCPeerConnection to ignore all but the first a=ssrc lines
* that form a Plan B stream.
* RTCRtpReceiver (an RTCRtpTransceiver), either both audio or both
* video. This will also cause RTCPeerConnection) to ignore all but the first a=ssrc
* lines that form a Plan B stream.
*
* For users who wish to send multiple audio/video streams and need to stay
* interoperable with legacy WebRTC implementations or use legacy APIs,
Expand All @@ -197,24 +197,12 @@ RTC_OBJC_EXPORT

@property(nonatomic, assign) BOOL allowCodecSwitching;

/**
* If MediaTransportFactory is provided in PeerConnectionFactory, this flag informs PeerConnection
* that it should use the MediaTransportInterface.
*/
@property(nonatomic, assign) BOOL useMediaTransport;

/**
* If MediaTransportFactory is provided in PeerConnectionFactory, this flag informs PeerConnection
* that it should use the MediaTransportInterface for data channels.
*/
@property(nonatomic, assign) BOOL useMediaTransportForDataChannels;

/**
* Defines advanced optional cryptographic settings related to SRTP and
* frame encryption for native WebRTC. Setting this will overwrite any
* options set through the PeerConnectionFactory (which is deprecated).
*/
@property(nonatomic, nullable) RTCCryptoOptions *cryptoOptions;
@property(nonatomic, nullable) RTC_OBJC_TYPE(RTCCryptoOptions) * cryptoOptions;

/**
* Time interval between audio RTCP reports.
Expand Down
2 changes: 1 addition & 1 deletion WebRTC.framework/Headers/RTCCryptoOptions.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ NS_ASSUME_NONNULL_BEGIN
* as Objective-C doesn't support nested structures.
*/
RTC_OBJC_EXPORT
@interface RTCCryptoOptions : NSObject
@interface RTC_OBJC_TYPE (RTCCryptoOptions) : NSObject

/**
* Enable GCM crypto suites from RFC 7714 for SRTP. GCM will only be used
Expand Down
Loading

0 comments on commit dedf7b7

Please sign in to comment.