10/24/2
This commit is contained in:
@@ -34,8 +34,13 @@ class TextExtractionController extends GetxController {
|
||||
}
|
||||
|
||||
Future<void> pickAndExtractText() async {
|
||||
final pickedImage =
|
||||
await ImagePicker().pickImage(source: ImageSource.camera);
|
||||
final pickedImage = await ImagePicker().pickImage(
|
||||
source: ImageSource.camera,
|
||||
preferredCameraDevice: CameraDevice.rear,
|
||||
maxHeight: Get.height * .7,
|
||||
maxWidth: Get.width * .9,
|
||||
imageQuality: 99,
|
||||
);
|
||||
if (pickedImage != null) {
|
||||
isloading = true;
|
||||
update();
|
||||
@@ -51,7 +56,8 @@ class TextExtractionController extends GetxController {
|
||||
languages.join('+'), // Combine multiple languages with '+'
|
||||
args: {
|
||||
"psm": "4",
|
||||
"preserve_interword_spaces": "1",
|
||||
"preserve_interword_spaces":
|
||||
"1", // "rectangle": Rect.fromLTWH(100, 100, 200, 200),
|
||||
} // Additional options if needed
|
||||
);
|
||||
isloading = false;
|
||||
@@ -73,7 +79,6 @@ class TextExtractionController extends GetxController {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
class TextMLGoogleRecognizerController extends GetxController {
|
||||
@override
|
||||
void onInit() {
|
||||
|
||||
Reference in New Issue
Block a user