CameraParams Class

data class CameraParams(val outputDir: String? = null, val tmpPrefix: String? = null, val authority: String? = null, val singleShot: Boolean = false, val shotOnTap: Boolean = true, val autoShotMode: Int = FrameObserver.Observation.CUTOUT_READY or FrameObserver.Observation.DEVICE_READY) : Parcelable

How the camera screen should behave for this launch.

Parameters

  • outputDir — where captured pages are written.
  • tmpPrefix — prefix for the temporary files it creates.
  • authority — the authority of a FileProvider your application declares, used to hand results back as content:// URIs your app can grant. Leave it null and the results come back as plain file:// URIs instead, which other apps cannot open.
  • singleShot — true to return after one page instead of letting the user capture several
  • shotOnTap — true to capture when the user taps the preview.
  • autoShotMode — whether to capture automatically once the document is framed.

Constructors

CameraParams

constructor(outputDir: String? = null, tmpPrefix: String? = null, authority: String? = null, singleShot: Boolean = false, shotOnTap: Boolean = true, autoShotMode: Int = FrameObserver.Observation.CUTOUT_READY or FrameObserver.Observation.DEVICE_READY)

Properties

authority

val authority: String? = null

The authority of a FileProvider your application declares.

autoShotMode

val autoShotMode: Int

A list of conditions for auto shot

outputDir

val outputDir: String? = null

A directory to store shots

shotOnTap

val shotOnTap: Boolean = true

Perform a shot on tap on the screen

singleShot

val singleShot: Boolean = false

Finish camera activity after first shot

tmpPrefix

val tmpPrefix: String? = null

A prefix for shot files

Top