extractTextFromImage method
Extract text from image file and apply cleaning.
Implementation
Future<String> extractTextFromImage(String imagePath) async {
try {
final RecognizedTextResult result = await recognizeText(imagePath);
final String cleaned = _cleanExtractedText(result.text);
return cleaned;
} catch (e) {
dev.log('Error extracting text from image: $e');
return '';
}
}