blob: c5baf20c1db4db4816a80e4bf9e913ee930154ba [file] [log] [blame]
Anders Carlsson7bca8ca2018-08-30 09:30:29 +02001/*
2 * Copyright 2015 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
15NS_ASSUME_NONNULL_BEGIN
16
17/** Constraint keys for media sources. */
Anders Carlsson7bca8ca2018-08-30 09:30:29 +020018/** The value for this key should be a base64 encoded string containing
19 * the data from the serialized configuration proto.
20 */
21RTC_EXTERN NSString *const kRTCMediaConstraintsAudioNetworkAdaptorConfig;
22
23/** Constraint keys for generating offers and answers. */
24RTC_EXTERN NSString *const kRTCMediaConstraintsIceRestart;
25RTC_EXTERN NSString *const kRTCMediaConstraintsOfferToReceiveAudio;
26RTC_EXTERN NSString *const kRTCMediaConstraintsOfferToReceiveVideo;
27RTC_EXTERN NSString *const kRTCMediaConstraintsVoiceActivityDetection;
28
29/** Constraint values for Boolean parameters. */
30RTC_EXTERN NSString *const kRTCMediaConstraintsValueTrue;
31RTC_EXTERN NSString *const kRTCMediaConstraintsValueFalse;
32
Mirko Bonadeie8d57242018-09-17 10:22:56 +020033RTC_OBJC_EXPORT
Mirko Bonadeia81e9c82020-05-04 16:14:32 +020034@interface RTC_OBJC_TYPE (RTCMediaConstraints) : NSObject
Anders Carlsson7bca8ca2018-08-30 09:30:29 +020035
36- (instancetype)init NS_UNAVAILABLE;
37
38/** Initialize with mandatory and/or optional constraints. */
39- (instancetype)
40 initWithMandatoryConstraints:(nullable NSDictionary<NSString *, NSString *> *)mandatory
41 optionalConstraints:(nullable NSDictionary<NSString *, NSString *> *)optional
42 NS_DESIGNATED_INITIALIZER;
43
44@end
45
46NS_ASSUME_NONNULL_END