UIImage+ext.h 721 B

1234567891011121314151617181920212223242526272829
  1. //
  2. // UIImage+ext.h
  3. // PanoramicCameraSDK
  4. //
  5. // Created by 王昭威 on 2023/1/14.
  6. //
  7. #import <UIKit/UIKit.h>
  8. #import <AVFoundation/AVFoundation.h>
  9. #import <CoreMedia/CoreMedia.h>
  10. NS_ASSUME_NONNULL_BEGIN
  11. @interface UIImage (ext)
  12. + (UIImageOrientation)imageOrientationByDeviceOrientation: (UIDeviceOrientation)deviceOrientation isFrontCamera: (BOOL)front;
  13. + (nullable UIImage*)sdkImageNamed:(NSString *)name;
  14. - (CVPixelBufferRef)toCVPixelBufferRef;
  15. - (float)checkRemake;
  16. - (float)checkRemakeForFrame: (CVPixelBufferRef)frameBuffer;
  17. - (instancetype)initWithBuffer:(CMSampleBufferRef)sampledBuffer isFrontCamera: (BOOL)front motionOrientation: (UIDeviceOrientation)motionOrientation;
  18. @end
  19. NS_ASSUME_NONNULL_END