RawImageLoadOptions

data class RawImageLoadOptions(var cropRect: Rect = Rect(), var origin: ImageOrigin = ImageOrigin.TOP_LEFT, var canvasColor: CanvasColor = CanvasColor.WHITE, var orientation: ImageRotation = ImageRotation.NONE) : Parcelable

Options for loading images that come from sensor.

Constructors

Link copied to clipboard
constructor(source: Map<String, Any?>)
constructor(json: JSONObject)
constructor(cropRect: Rect = Rect(), origin: ImageOrigin = ImageOrigin.TOP_LEFT, canvasColor: CanvasColor = CanvasColor.WHITE, orientation: ImageRotation = ImageRotation.NONE)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard

CanvasColor color to use when converting images with alpha channel to images without alpha channel.

Link copied to clipboard

If the rect is not empty, the image will be cropped to this rect before processing.

Link copied to clipboard

Rotation that should be applied to the image to recover correct orientation. Is applied before cropping.

Link copied to clipboard

Location of the image origin in the image coordinate system. During loading images are flipped such that after the flip their new origin is in their top-left corner. For example, an image coming from the front camera might have its origin set to the top-right, which will flip it along its vertical axis to create a mirror effect.

Functions

Link copied to clipboard
Link copied to clipboard
fun toJson(config: ToJsonConfiguration = ToJsonConfiguration.default()): JSONObject