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.

42 lines
1.3 KiB

  1. //
  2. // SCCaptureCore.h
  3. // Snapchat
  4. //
  5. // Created by Lin Jia on 10/2/17.
  6. //
  7. //
  8. #import "SCCaptureStateMachineContext.h"
  9. #import "SCCapturer.h"
  10. #import <SCFoundation/SCPerforming.h>
  11. #import <Foundation/Foundation.h>
  12. @class SCCaptureConfigurator;
  13. /*
  14. SCCaptureCore abstracts away the hardware aspect of a camera. SCCaptureCore is the V2 version of the
  15. SCManagedCapturerV1.
  16. SCCaptureCore itself does very little things actually. Its main job is to expose APIs of camera hardware to outside
  17. customers. The actual heavy lifting is done via delegating the jobs to multiple worker classes.
  18. We generally categorize the operation of camera hardware into 2 categories:
  19. 1) make camera hardware do state transition. Such as what is shown in this graph:
  20. https://docs.google.com/presentation/d/1KWk-XSgO0wFAjBZXsl_OnHBGpi_pd9-ds6Wje8vX-0s/edit#slide=id.g2017e46295_1_10
  21. 2) config camera hardware setting, such as setting the camera to be front or back, such as setting camera hardware to
  22. be certain resolution, or to activate night mode.
  23. Indeed, we create 2 working classes to do the heavy lifting. Both of them are under construction. Feel free to checkout
  24. SCCaptureConfigurator, which is responsible for 2).
  25. */
  26. @interface SCCaptureCore : NSObject <SCCapturer>
  27. @property (nonatomic, strong, readonly) SCCaptureStateMachineContext *stateMachine;
  28. @end