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.

60 lines
1.5 KiB

  1. //
  2. // SCManagedCaptureDevice.h
  3. // Snapchat
  4. //
  5. // Created by Liu Liu on 4/22/15.
  6. // Copyright (c) 2015 Liu Liu. All rights reserved.
  7. //
  8. #import <SCCameraFoundation/SCManagedCaptureDevicePosition.h>
  9. #import <SCCameraFoundation/SCManagedCaptureDeviceProtocol.h>
  10. #import <AVFoundation/AVFoundation.h>
  11. #import <Foundation/Foundation.h>
  12. extern CGFloat const kSCMaxVideoZoomFactor;
  13. extern CGFloat const kSCMinVideoZoomFactor;
  14. @class SCManagedCaptureDevice;
  15. @protocol SCManagedCaptureDeviceDelegate <NSObject>
  16. @optional
  17. - (void)managedCaptureDevice:(SCManagedCaptureDevice *)device didChangeAdjustingExposure:(BOOL)adjustingExposure;
  18. - (void)managedCaptureDevice:(SCManagedCaptureDevice *)device didChangeExposurePoint:(CGPoint)exposurePoint;
  19. - (void)managedCaptureDevice:(SCManagedCaptureDevice *)device didChangeFocusPoint:(CGPoint)focusPoint;
  20. @end
  21. @interface SCManagedCaptureDevice : NSObject <SCManagedCaptureDeviceProtocol>
  22. @property (nonatomic, weak) id<SCManagedCaptureDeviceDelegate> delegate;
  23. // These two class methods are thread safe
  24. + (instancetype)front;
  25. + (instancetype)back;
  26. + (instancetype)dualCamera;
  27. + (instancetype)deviceWithPosition:(SCManagedCaptureDevicePosition)position;
  28. + (BOOL)is1080pSupported;
  29. + (BOOL)isMixCaptureSupported;
  30. + (BOOL)isNightModeSupported;
  31. + (BOOL)isEnhancedNightModeSupported;
  32. + (CGSize)defaultActiveFormatResolution;
  33. + (CGSize)nightModeActiveFormatResolution;
  34. - (BOOL)softwareZoom;
  35. - (SCManagedCaptureDevicePosition)position;
  36. - (BOOL)isAvailable;
  37. @end