recognize

open suspend override fun recognize(frame: ImageProxy): RecognizedText

Runs ML Kit on frame and returns the recognized lines.

Returns no lines when the frame has no backing image. It does not close the frame. It returns, also when cancelled, only after ML Kit has stopped reading the frame, so the caller can close it right away.

Return

the recognized lines.

Parameters

frame

the CameraX frame to read.