1 /* 2 * Copyright 2016 The WebRTC project authors. All Rights Reserved. 3 * 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 6 * tree. An additional intellectual property rights grant can be found 7 * in the file PATENTS. All contributing project authors may 8 * be found in the AUTHORS file in the root of the source tree. 9 */ 10 11 #import <Foundation/Foundation.h> 12 13 #import "RTCMacros.h" 14 15 NS_ASSUME_NONNULL_BEGIN 16 17 RTC_EXTERN const NSString *const kRTCRtxCodecName; 18 RTC_EXTERN const NSString *const kRTCRedCodecName; 19 RTC_EXTERN const NSString *const kRTCUlpfecCodecName; 20 RTC_EXTERN const NSString *const kRTCFlexfecCodecName; 21 RTC_EXTERN const NSString *const kRTCOpusCodecName; 22 RTC_EXTERN const NSString *const kRTCIsacCodecName; 23 RTC_EXTERN const NSString *const kRTCL16CodecName; 24 RTC_EXTERN const NSString *const kRTCG722CodecName; 25 RTC_EXTERN const NSString *const kRTCIlbcCodecName; 26 RTC_EXTERN const NSString *const kRTCPcmuCodecName; 27 RTC_EXTERN const NSString *const kRTCPcmaCodecName; 28 RTC_EXTERN const NSString *const kRTCDtmfCodecName; 29 RTC_EXTERN const NSString *const kRTCComfortNoiseCodecName; 30 RTC_EXTERN const NSString *const kRTCVp8CodecName; 31 RTC_EXTERN const NSString *const kRTCVp9CodecName; 32 RTC_EXTERN const NSString *const kRTCH264CodecName; 33 34 /** Defined in http://w3c.github.io/webrtc-pc/#idl-def-RTC_OBJC_TYPE(RTCRtpCodecParameters) */ 35 RTC_OBJC_EXPORT 36 @interface RTC_OBJC_TYPE (RTCRtpCodecParameters) : NSObject 37 38 /** The RTP payload type. */ 39 @property(nonatomic, assign) int payloadType; 40 41 /** 42 * The codec MIME subtype. Valid types are listed in: 43 * http://www.iana.org/assignments/rtp-parameters/rtp-parameters.xhtml#rtp-parameters-2 44 * 45 * Several supported types are represented by the constants above. 46 */ 47 @property(nonatomic, readonly, nonnull) NSString *name; 48 49 /** 50 * The media type of this codec. Equivalent to MIME top-level type. 51 * 52 * Valid values are kRTCMediaStreamTrackKindAudio and 53 * kRTCMediaStreamTrackKindVideo. 54 */ 55 @property(nonatomic, readonly, nonnull) NSString *kind; 56 57 /** The codec clock rate expressed in Hertz. */ 58 @property(nonatomic, readonly, nullable) NSNumber *clockRate; 59 60 /** 61 * The number of channels (mono=1, stereo=2). 62 * Set to null for video codecs. 63 **/ 64 @property(nonatomic, readonly, nullable) NSNumber *numChannels; 65 66 /** The "format specific parameters" field from the "a=fmtp" line in the SDP */ 67 @property(nonatomic, readonly, nonnull) NSDictionary *parameters; 68 69 - (instancetype)init NS_DESIGNATED_INITIALIZER; 70 71 @end 72 73 NS_ASSUME_NONNULL_END 74