LKS_PerspectiveLayer.h 822 B

12345678910111213141516171819202122232425262728293031323334
  1. #ifdef SHOULD_COMPILE_LOOKIN_SERVER
  2. //
  3. // LKS_PerspectiveLayer.h
  4. // LookinServer
  5. //
  6. // Created by Li Kai on 2019/5/17.
  7. // https://lookin.work
  8. //
  9. #import <QuartzCore/QuartzCore.h>
  10. #import "LKS_PerspectiveDataSource.h"
  11. typedef NS_ENUM (NSUInteger, LKS_PerspectiveDimension) {
  12. LKS_PerspectiveDimension2D,
  13. LKS_PerspectiveDimension3D
  14. };
  15. @interface LKS_PerspectiveLayer : CALayer <LKS_PerspectiveDataSourceDelegate>
  16. - (instancetype)initWithDataSource:(LKS_PerspectiveDataSource *)dataSource;
  17. /// 2D 还是 3D
  18. @property(nonatomic, assign) LKS_PerspectiveDimension dimension;
  19. /// 旋转的角度
  20. @property(nonatomic, assign, readonly) CGFloat rotation;
  21. - (void)setRotation:(CGFloat)rotation animated:(BOOL)animated completion:(void (^)(void))completionBlock;
  22. @end
  23. #endif /* SHOULD_COMPILE_LOOKIN_SERVER */