This repository has been archived by the owner on Sep 4, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 76
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Alexey
committed
Jul 20, 2017
1 parent
24110b6
commit 61e88f1
Showing
15 changed files
with
1,051 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
/* | ||
* Copyright 2017 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. | ||
*/ | ||
|
||
#import <Foundation/Foundation.h> | ||
|
||
#import <WebRTC/RTCMacros.h> | ||
#import <WebRTC/RTCVideoCapturer.h> | ||
|
||
NS_ASSUME_NONNULL_BEGIN | ||
|
||
RTC_EXPORT | ||
// Camera capture that implements RTCVideoCapturer. Delivers frames to a RTCVideoCapturerDelegate | ||
// (usually RTCVideoSource). | ||
@interface RTCCameraVideoCapturer : RTCVideoCapturer | ||
|
||
// Capture session that is used for capturing. Valid from initialization to dealloc. | ||
@property(readonly, nonatomic) AVCaptureSession *captureSession; | ||
|
||
// Returns list of available capture devices that support video capture. | ||
+ (NSArray<AVCaptureDevice *> *)captureDevices; | ||
// Returns list of formats that are supported by this class for this device. | ||
+ (NSArray<AVCaptureDeviceFormat *> *)supportedFormatsForDevice:(AVCaptureDevice *)device; | ||
|
||
// Starts and stops the capture session asynchronously. | ||
- (void)startCaptureWithDevice:(AVCaptureDevice *)device | ||
format:(AVCaptureDeviceFormat *)format | ||
fps:(NSInteger)fps; | ||
// Stops the capture session asynchronously. | ||
- (void)stopCapture; | ||
|
||
@end | ||
|
||
NS_ASSUME_NONNULL_END |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
/* | ||
* Copyright 2017 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. | ||
*/ | ||
|
||
#import <WebRTC/RTCVideoFrame.h> | ||
|
||
NS_ASSUME_NONNULL_BEGIN | ||
|
||
@class RTCVideoCapturer; | ||
|
||
RTC_EXPORT | ||
@protocol RTCVideoCapturerDelegate <NSObject> | ||
- (void)capturer:(RTCVideoCapturer *)capturer didCaptureVideoFrame:(RTCVideoFrame *)frame; | ||
@end | ||
|
||
RTC_EXPORT | ||
@interface RTCVideoCapturer : NSObject | ||
|
||
@property(nonatomic, readonly, weak) id<RTCVideoCapturerDelegate> delegate; | ||
|
||
- (instancetype)initWithDelegate:(id<RTCVideoCapturerDelegate>)delegate; | ||
|
||
@end | ||
|
||
NS_ASSUME_NONNULL_END |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.