extractText static method
image to text
String _ocrText = await FlutterTesseractOcr.extractText(url, language: langs, args: {
"preserve_interword_spaces": "1",});
Implementation
static Future<String> extractText(String imagePath,
{String? language, Map? args}) async {
assert(await File(imagePath).exists(), true);
final String tessData = await _loadTessData();
final String extractText =
await _channel.invokeMethod('extractText', <String, dynamic>{
'imagePath': imagePath,
'tessData': tessData,
'language': language,
'args': args,
});
return extractText;
}