1
0
This repository has been archived on 2025-03-31. You can view files and clone it, but cannot push or open issues or pull requests.
Source-SnapChatCamera/ManagedCapturer/SCCaptureDeviceAuthorizationChecker.h
2018-08-08 02:23:44 +03:00

32 lines
830 B
Objective-C

//
// SCCaptureDeviceAuthorizationChecker.h
// Snapchat
//
// Created by Sun Lei on 15/03/2018.
//
@class SCQueuePerformer;
#import <SCBase/SCMacros.h>
#import <Foundation/Foundation.h>
/*
In general, the function of SCCaptureDeviceAuthorizationChecker is to speed up the checking of AVMediaTypeVideo
authorization. It would cache the authorization value. 'preloadVideoCaptureAuthorization' would be called very early
after the app is launched to populate the cached value. 'authorizedForVideoCapture' could be called to get the value
synchronously.
*/
@interface SCCaptureDeviceAuthorizationChecker : NSObject
SC_INIT_AND_NEW_UNAVAILABLE
- (instancetype)initWithPerformer:(SCQueuePerformer *)performer NS_DESIGNATED_INITIALIZER;
- (BOOL)authorizedForVideoCapture;
- (void)preloadVideoCaptureAuthorization;
@end