blob: 8e475dd21e2258b88e53f478c1663f703109124a [file] [log] [blame]
Jon Hjellef6c318e2016-01-11 14:39:01 -08001/*
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
Anders Carlsson7bca8ca2018-08-30 09:30:29 +020011#import "RTCVideoSource.h"
Jon Hjellef6c318e2016-01-11 14:39:01 -080012
tkchind4bfbfc2016-08-30 11:56:05 -070013#import "RTCMediaSource+Private.h"
14
Steve Anton10542f22019-01-11 09:11:00 -080015#include "api/media_stream_interface.h"
Yves Gerey2e00abc2018-10-05 15:39:24 +020016#include "rtc_base/thread.h"
Jon Hjellef6c318e2016-01-11 14:39:01 -080017
18NS_ASSUME_NONNULL_BEGIN
19
Mirko Bonadeia81e9c82020-05-04 16:14:32 +020020@interface RTC_OBJC_TYPE (RTCVideoSource)
21()
Jon Hjellef6c318e2016-01-11 14:39:01 -080022
Mirko Bonadeia81e9c82020-05-04 16:14:32 +020023 /**
24 * The VideoTrackSourceInterface object passed to this RTCVideoSource during
25 * construction.
26 */
27 @property(nonatomic,
28 readonly) rtc::scoped_refptr<webrtc::VideoTrackSourceInterface> nativeVideoSource;
Jon Hjellef6c318e2016-01-11 14:39:01 -080029
perkja3ede6c2016-03-08 01:27:48 +010030/** Initialize an RTCVideoSource from a native VideoTrackSourceInterface. */
Mirko Bonadeia81e9c82020-05-04 16:14:32 +020031- (instancetype)initWithFactory:(RTC_OBJC_TYPE(RTCPeerConnectionFactory) *)factory
Yura Yaroshevich01cee072018-07-11 15:35:40 +030032 nativeVideoSource:
33 (rtc::scoped_refptr<webrtc::VideoTrackSourceInterface>)nativeVideoSource
Jon Hjellef6c318e2016-01-11 14:39:01 -080034 NS_DESIGNATED_INITIALIZER;
35
Mirko Bonadeia81e9c82020-05-04 16:14:32 +020036- (instancetype)initWithFactory:(RTC_OBJC_TYPE(RTCPeerConnectionFactory) *)factory
Yura Yaroshevich01cee072018-07-11 15:35:40 +030037 nativeMediaSource:(rtc::scoped_refptr<webrtc::MediaSourceInterface>)nativeMediaSource
38 type:(RTCMediaSourceType)type NS_UNAVAILABLE;
Jon Hjellef6c318e2016-01-11 14:39:01 -080039
Mirko Bonadeia81e9c82020-05-04 16:14:32 +020040- (instancetype)initWithFactory:(RTC_OBJC_TYPE(RTCPeerConnectionFactory) *)factory
Yura Yaroshevich01cee072018-07-11 15:35:40 +030041 signalingThread:(rtc::Thread *)signalingThread
42 workerThread:(rtc::Thread *)workerThread;
Anders Carlsson9823ee42018-03-07 10:32:03 +010043
Saúl Ibarra Corretgé4d0760e2021-08-06 16:17:12 +020044- (instancetype)initWithFactory:(RTC_OBJC_TYPE(RTCPeerConnectionFactory) *)factory
45 signalingThread:(rtc::Thread *)signalingThread
46 workerThread:(rtc::Thread *)workerThread
47 isScreenCast:(BOOL)isScreenCast;
48
Jon Hjellef6c318e2016-01-11 14:39:01 -080049@end
50
51NS_ASSUME_NONNULL_END