Jon Hjelle | da99da8 | 2016-01-20 13:40:30 -0800 | [diff] [blame] | 1 | /* |
| 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 | NS_ASSUME_NONNULL_BEGIN |
| 14 | |
Tze Kwang Chin | f3cb49f | 2016-03-22 10:57:40 -0700 | [diff] [blame] | 15 | @class RTCAVFoundationVideoSource; |
Tze Kwang Chin | f3cb49f | 2016-03-22 10:57:40 -0700 | [diff] [blame] | 16 | @class RTCAudioTrack; |
| 17 | @class RTCConfiguration; |
| 18 | @class RTCMediaConstraints; |
| 19 | @class RTCMediaStream; |
| 20 | @class RTCPeerConnection; |
| 21 | @class RTCVideoSource; |
| 22 | @class RTCVideoTrack; |
| 23 | @protocol RTCPeerConnectionDelegate; |
| 24 | |
Jon Hjelle | da99da8 | 2016-01-20 13:40:30 -0800 | [diff] [blame] | 25 | @interface RTCPeerConnectionFactory : NSObject |
Tze Kwang Chin | f3cb49f | 2016-03-22 10:57:40 -0700 | [diff] [blame] | 26 | |
| 27 | - (instancetype)init NS_DESIGNATED_INITIALIZER; |
| 28 | |
Tze Kwang Chin | f3cb49f | 2016-03-22 10:57:40 -0700 | [diff] [blame] | 29 | /** Initialize an RTCAVFoundationVideoSource with constraints. */ |
| 30 | - (RTCAVFoundationVideoSource *)avFoundationVideoSourceWithConstraints: |
| 31 | (nullable RTCMediaConstraints *)constraints; |
Tze Kwang Chin | f3cb49f | 2016-03-22 10:57:40 -0700 | [diff] [blame] | 32 | |
| 33 | /** Initialize an RTCAudioTrack with an id. */ |
| 34 | - (RTCAudioTrack *)audioTrackWithTrackId:(NSString *)trackId; |
| 35 | |
| 36 | /** Initialize an RTCVideoTrack with a source and an id. */ |
| 37 | - (RTCVideoTrack *)videoTrackWithSource:(RTCVideoSource *)source |
| 38 | trackId:(NSString *)trackId; |
| 39 | |
| 40 | /** Initialize an RTCMediaStream with an id. */ |
| 41 | - (RTCMediaStream *)mediaStreamWithStreamId:(NSString *)streamId; |
| 42 | |
| 43 | /** Initialize an RTCPeerConnection with a configuration, constraints, and |
| 44 | * delegate. |
| 45 | */ |
| 46 | - (RTCPeerConnection *)peerConnectionWithConfiguration: |
| 47 | (RTCConfiguration *)configuration |
| 48 | constraints: |
| 49 | (RTCMediaConstraints *)constraints |
| 50 | delegate: |
| 51 | (nullable id<RTCPeerConnectionDelegate>)delegate; |
| 52 | |
Jon Hjelle | da99da8 | 2016-01-20 13:40:30 -0800 | [diff] [blame] | 53 | @end |
| 54 | |
| 55 | NS_ASSUME_NONNULL_END |