FIRVisionImageMetadata.h 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. #import <Foundation/Foundation.h>
  2. NS_ASSUME_NONNULL_BEGIN
  3. /**
  4. * @enum VisionDetectorImageOrientation
  5. * This enum specifies where the origin (0,0) of the image is located. The constant has the same
  6. * value as defined by EXIF specifications.
  7. */
  8. typedef NS_ENUM(NSUInteger, FIRVisionDetectorImageOrientation) {
  9. /**
  10. * Orientation code indicating the 0th row is the top and the 0th column is the left side.
  11. */
  12. FIRVisionDetectorImageOrientationTopLeft = 1,
  13. /**
  14. * Orientation code indicating the 0th row is the top and the 0th column is the right side.
  15. */
  16. FIRVisionDetectorImageOrientationTopRight,
  17. /**
  18. * Orientation code indicating the 0th row is the bottom and the 0th column is the right side.
  19. */
  20. FIRVisionDetectorImageOrientationBottomRight,
  21. /**
  22. * Orientation code indicating the 0th row is the bottom and the 0th column is the left side.
  23. */
  24. FIRVisionDetectorImageOrientationBottomLeft,
  25. /**
  26. * Orientation code indicating the 0th row is the left side and the 0th column is the top.
  27. */
  28. FIRVisionDetectorImageOrientationLeftTop,
  29. /**
  30. * Orientation code indicating the 0th row is the right side and the 0th column is the top.
  31. */
  32. FIRVisionDetectorImageOrientationRightTop,
  33. /**
  34. * Orientation code indicating the 0th row is the right side and the 0th column is the bottom.
  35. */
  36. FIRVisionDetectorImageOrientationRightBottom,
  37. /**
  38. * Orientation code indicating the 0th row is the left side and the 0th column is the
  39. * bottom.
  40. */
  41. FIRVisionDetectorImageOrientationLeftBottom,
  42. } NS_SWIFT_NAME(VisionDetectorImageOrientation);
  43. /**
  44. * Metadata of an image used in feature detection.
  45. */
  46. NS_SWIFT_NAME(VisionImageMetadata)
  47. @interface FIRVisionImageMetadata : NSObject
  48. /**
  49. * The display orientation of the image. Defaults to `.topLeft`.
  50. */
  51. @property(nonatomic) FIRVisionDetectorImageOrientation orientation;
  52. @end
  53. NS_ASSUME_NONNULL_END