Sets rotation of the image, indicating the rotation from the upright
orientation.
Since the camera may deliver images that are rotated (e.g., if the user holds the
device upside down), specifying the rotation with the image indicates how to make the
image upright.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2020-08-08 UTC."],[],[],null,["# FirebaseVisionImageMetadata.Builder\n\npublic static class **FirebaseVisionImageMetadata.Builder** extends [Object](//developer.android.com/reference/java/lang/Object.html) \nBuilder class of [FirebaseVisionImageMetadata](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata). \n\n### Public Constructor Summary\n\n|---|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| | [FirebaseVisionImageMetadata.Builder](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata.Builder#FirebaseVisionImageMetadata.Builder())() Creates a new builder to build [FirebaseVisionImageMetadata](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata). |\n\n### Public Method Summary\n\n|-----------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [FirebaseVisionImageMetadata](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata) | [build](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata.Builder#build())() Builds an instance of [FirebaseVisionImageMetadata](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata). |\n| [FirebaseVisionImageMetadata.Builder](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata.Builder) | [setFormat](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata.Builder#setFormat(int))(int format) Sets the format of the image stored in [ByteBuffer](//developer.android.com/reference/java/nio/ByteBuffer.html). |\n| [FirebaseVisionImageMetadata.Builder](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata.Builder) | [setHeight](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata.Builder#setHeight(int))(int height) Sets height of the image, which must be a positive integer. |\n| [FirebaseVisionImageMetadata.Builder](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata.Builder) | [setRotation](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata.Builder#setRotation(int))(int rotation) Sets rotation of the image, indicating the rotation from the upright orientation. |\n| [FirebaseVisionImageMetadata.Builder](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata.Builder) | [setWidth](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata.Builder#setWidth(int))(int width) Sets width of the image, which must be a positive integer. |\n\n### Inherited Method Summary\n\nFrom class java.lang.Object \n\n|----------------------------------------------------------------------------|--------------------------------------------------------------------------------|\n| [Object](//developer.android.com/reference/java/lang/Object.html) | clone() |\n| boolean | equals([Object](//developer.android.com/reference/java/lang/Object.html) arg0) |\n| void | finalize() |\n| final [Class](//developer.android.com/reference/java/lang/Class.html)\\\u003c?\\\u003e | getClass() |\n| int | hashCode() |\n| final void | notify() |\n| final void | notifyAll() |\n| [String](//developer.android.com/reference/java/lang/String.html) | toString() |\n| final void | wait(long arg0, int arg1) |\n| final void | wait(long arg0) |\n| final void | wait() |\n\nPublic Constructors\n-------------------\n\n#### public **FirebaseVisionImageMetadata.Builder** ()\n\nCreates a new builder to build [FirebaseVisionImageMetadata](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata).\n\nPublic Methods\n--------------\n\n#### public [FirebaseVisionImageMetadata](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata) **build**\n()\n\nBuilds an instance of [FirebaseVisionImageMetadata](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata). \n\n#### public [FirebaseVisionImageMetadata.Builder](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata.Builder) **setFormat** (int format)\n\nSets the format of the image stored in [ByteBuffer](//developer.android.com/reference/java/nio/ByteBuffer.html). It\nmust be one of [FirebaseVisionImageMetadata.ImageFormat](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata.ImageFormat). \n\n#### public [FirebaseVisionImageMetadata.Builder](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata.Builder) **setHeight** (int height)\n\nSets height of the image, which must be a positive integer. \n\n#### public [FirebaseVisionImageMetadata.Builder](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata.Builder) **setRotation** (int rotation)\n\nSets rotation of the image, indicating the rotation from the upright\norientation.\n\nSince the camera may deliver images that are rotated (e.g., if the user holds the\ndevice upside down), specifying the rotation with the image indicates how to make the\nimage upright.\n\nCurrently, only [ROTATION_0](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata#ROTATION_0), [ROTATION_90](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata#ROTATION_90), [ROTATION_180](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata#ROTATION_180) and [ROTATION_270](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata#ROTATION_270) are supported. \n\n#### public [FirebaseVisionImageMetadata.Builder](/docs/reference/android/com/google/firebase/ml/vision/common/FirebaseVisionImageMetadata.Builder) **setWidth** (int width)\n\nSets width of the image, which must be a positive integer."]]