Package-level declarations

Types

Link copied to clipboard
fun interface CodeAnalyzerListener

Listener interface for handling results from the code analysis process.

Link copied to clipboard

Result from code scanner.

Link copied to clipboard
actual enum CodeType : Enum<CodeType>
expect enum CodeType : Enum<CodeType>

Represents the types of codes that can be scanned.

actual enum CodeType : Enum<CodeType>
Link copied to clipboard
class CodeTypeNotSupportedException(val codeType: CodeType, message: String = "Code type ") : Exception

Exception thrown when a specific CodeType is not supported by the device's camera scanner.

Link copied to clipboard
class CornerPointer(val x: Int, val y: Int)

Represents a corner point of a detected code in DP.

Link copied to clipboard
class FrameRect(val left: Int, val top: Int, val right: Int, val bottom: Int)

Represents a rectangle frame, used for scanning codes.

Functions

Link copied to clipboard
actual fun CameraSession.rememberCodeImageAnalyzer(codeTypes: List<CodeType>, onError: (Throwable) -> Unit, codeAnalyzerListener: CodeAnalyzerListener): ImageAnalyzer
expect fun CameraSession.rememberCodeImageAnalyzer(codeTypes: List<CodeType> = listOf(CodeType.QRCode), onError: (Throwable) -> Unit = {}, codeAnalyzerListener: CodeAnalyzerListener): ImageAnalyzer

Creates and remembers an ImageAnalyzer for scanning barcodes and QR codes.

actual fun CameraSession.rememberCodeImageAnalyzer(codeTypes: List<CodeType>, onError: (Throwable) -> Unit, codeAnalyzerListener: CodeAnalyzerListener): ImageAnalyzer