You can pass in either mutable or immutable Bitmap. However
once Bitmap is passed
in, to keep data integrity you shouldn't modify content in it.
Use BitmapExtractor
to get Bitmap you passed
in.
| MlImage | |
| BitmapMlImageBuilder |
setRotation(int rotation)
Sets value for
MlImage.getRotation().
|
Creates the builder with a mandatory Bitmap.
Also calls
setRotation(int) to set the optional properties. If not set, the values will
be set with default:
| bitmap | image data object. |
|---|
Creates the builder to build MlImage from
a file.
Also calls
setRotation(int) to set the optional properties. If not set, the values will
be set with default:
| context | the application context. |
|---|---|
| uri | the path to the resource file. |
| IOException |
|---|
Sets value for MlImage.getRotation().
| IllegalArgumentException | if the rotation value is not 0, 90, 180 or 270. |
|---|