2016-01-11 14:39:01 -08:00
|
|
|
/*
|
|
|
|
|
* Copyright 2015 The WebRTC project authors. All Rights Reserved.
|
|
|
|
|
*
|
|
|
|
|
* Use of this source code is governed by a BSD-style license
|
|
|
|
|
* that can be found in the LICENSE file in the root of the source
|
|
|
|
|
* tree. An additional intellectual property rights grant can be found
|
|
|
|
|
* in the file PATENTS. All contributing project authors may
|
|
|
|
|
* be found in the AUTHORS file in the root of the source tree.
|
|
|
|
|
*/
|
|
|
|
|
|
2018-08-30 09:30:29 +02:00
|
|
|
#import "RTCVideoSource.h"
|
2016-01-11 14:39:01 -08:00
|
|
|
|
2016-08-30 11:56:05 -07:00
|
|
|
#import "RTCMediaSource+Private.h"
|
|
|
|
|
|
2019-01-11 09:11:00 -08:00
|
|
|
#include "api/media_stream_interface.h"
|
2018-10-05 15:39:24 +02:00
|
|
|
#include "rtc_base/thread.h"
|
2016-01-11 14:39:01 -08:00
|
|
|
|
|
|
|
|
NS_ASSUME_NONNULL_BEGIN
|
|
|
|
|
|
2016-01-20 13:25:44 -08:00
|
|
|
@interface RTCVideoSource ()
|
2016-01-11 14:39:01 -08:00
|
|
|
|
|
|
|
|
/**
|
2016-03-08 01:27:48 +01:00
|
|
|
* The VideoTrackSourceInterface object passed to this RTCVideoSource during
|
2016-01-11 14:39:01 -08:00
|
|
|
* construction.
|
|
|
|
|
*/
|
2016-03-08 01:27:48 +01:00
|
|
|
@property(nonatomic, readonly) rtc::scoped_refptr<webrtc::VideoTrackSourceInterface>
|
|
|
|
|
nativeVideoSource;
|
2016-01-11 14:39:01 -08:00
|
|
|
|
2016-03-08 01:27:48 +01:00
|
|
|
/** Initialize an RTCVideoSource from a native VideoTrackSourceInterface. */
|
2018-07-11 15:35:40 +03:00
|
|
|
- (instancetype)initWithFactory:(RTCPeerConnectionFactory *)factory
|
|
|
|
|
nativeVideoSource:
|
|
|
|
|
(rtc::scoped_refptr<webrtc::VideoTrackSourceInterface>)nativeVideoSource
|
2016-01-11 14:39:01 -08:00
|
|
|
NS_DESIGNATED_INITIALIZER;
|
|
|
|
|
|
2018-07-11 15:35:40 +03:00
|
|
|
- (instancetype)initWithFactory:(RTCPeerConnectionFactory *)factory
|
|
|
|
|
nativeMediaSource:(rtc::scoped_refptr<webrtc::MediaSourceInterface>)nativeMediaSource
|
|
|
|
|
type:(RTCMediaSourceType)type NS_UNAVAILABLE;
|
2016-01-11 14:39:01 -08:00
|
|
|
|
2018-07-11 15:35:40 +03:00
|
|
|
- (instancetype)initWithFactory:(RTCPeerConnectionFactory *)factory
|
|
|
|
|
signalingThread:(rtc::Thread *)signalingThread
|
|
|
|
|
workerThread:(rtc::Thread *)workerThread;
|
2018-03-07 10:32:03 +01:00
|
|
|
|
2016-01-11 14:39:01 -08:00
|
|
|
@end
|
|
|
|
|
|
|
|
|
|
NS_ASSUME_NONNULL_END
|