2014 snapchat source code
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
831 B

  1. //
  2. // SCCaptureDeviceAuthorization.h
  3. // Snapchat
  4. //
  5. // Created by Xiaomu Wu on 8/19/14.
  6. // Copyright (c) 2014 Snapchat, Inc. All rights reserved.
  7. //
  8. #import <Foundation/Foundation.h>
  9. @interface SCCaptureDeviceAuthorization : NSObject
  10. // Methods for checking / requesting authorization to use media capture devices of a given type.
  11. + (BOOL)notDeterminedForMediaType:(NSString *)mediaType;
  12. + (BOOL)deniedForMediaType:(NSString *)mediaType;
  13. + (BOOL)restrictedForMediaType:(NSString *)mediaType;
  14. + (void)requestAccessForMediaType:(NSString *)mediaType completionHandler:(void (^)(BOOL granted))handler;
  15. // Convenience methods for media type == AVMediaTypeVideo
  16. + (BOOL)notDeterminedForVideoCapture;
  17. + (BOOL)deniedForVideoCapture;
  18. + (void)requestAccessForVideoCaptureWithCompletionHandler:(void (^)(BOOL granted))handler;
  19. @end