π End-to-end encrypted cloud for everything.
Dart 2faandroidauthye2eeencryptionend-to-end-encryptionfluttergolanggoogle-photosgoogle-photos-alternativeiosopensourcephotosprivacyprivacy-toolstypescriptzero-knowledge
Use mobile_ocr for text detection
laurenspriemac7891e7e5ce
diff --git a/mobile/apps/photos/lib/ui/viewer/file/file_app_bar.dart b/mobile/apps/photos/lib/ui/viewer/file/file_app_bar.dartindex 512e005e2d..b22466d909 100644--- a/mobile/apps/photos/lib/ui/viewer/file/file_app_bar.dart+++ b/mobile/apps/photos/lib/ui/viewer/file/file_app_bar.dart@@ -281,7 +281,7 @@ class FileAppBarState extends State<FileAppBar> {),);- // Text detection for internal iOS users (images and live photos, but not videos)+ // Text detection for internal mobile users (images and live photos, but not videos)if (flagService.textDetection && widget.file.fileType != FileType.video) {items.add(EntePopupMenuItem(diff --git a/mobile/apps/photos/lib/ui/viewer/file/text_detection_page.dart b/mobile/apps/photos/lib/ui/viewer/file/text_detection_page.dartindex 8387069207..fdcb1ba639 100644--- a/mobile/apps/photos/lib/ui/viewer/file/text_detection_page.dart+++ b/mobile/apps/photos/lib/ui/viewer/file/text_detection_page.dart@@ -1,9 +1,9 @@import 'package:flutter/material.dart';import 'package:flutter/services.dart';-import "package:logging/logging.dart";+import 'package:logging/logging.dart';+import 'package:mobile_ocr/mobile_ocr.dart';import 'package:photos/ui/common/loading_widget.dart';import 'package:photos/ui/notification/toast.dart';-import 'package:text_detector/text_detector.dart';class TextDetectionPage extends StatefulWidget {final String imagePath;@@ -28,7 +28,6 @@ class _TextDetectionPageState extends State<TextDetectionPage> {autoDetect: true,backgroundColor: Colors.black,showUnselectedBoundaries: true,- singleShotMode: true,loadingWidget: const Center(child: EnteLoadingWidget(color: Colors.white, size: 24),),diff --git a/mobile/apps/photos/plugins/ente_feature_flag/lib/src/service.dart b/mobile/apps/photos/plugins/ente_feature_flag/lib/src/service.dartindex 3922e4fdb8..d30267d908 100644--- a/mobile/apps/photos/plugins/ente_feature_flag/lib/src/service.dart+++ b/mobile/apps/photos/plugins/ente_feature_flag/lib/src/service.dart@@ -66,7 +66,8 @@ class FlagService {String get embedUrl => flags.embedUrl;- bool get textDetection => internalUser && Platform.isIOS;+ bool get textDetection =>+ internalUser && (Platform.isIOS || Platform.isAndroid);bool get addToAlbumFeature => internalUser;diff --git a/mobile/apps/photos/pubspec.lock b/mobile/apps/photos/pubspec.lockindex 4e2a9e61f4..9c97f3502e 100644--- a/mobile/apps/photos/pubspec.lock+++ b/mobile/apps/photos/pubspec.lock@@ -1676,6 +1676,15 @@ packages:url: "https://pub.dev"source: hostedversion: "13.12.6"+ mobile_ocr:+ dependency: "direct main"+ description:+ path: "."+ ref: HEAD+ resolved-ref: be47e93959e40ae290643596069a7e2b344c0dca+ url: "https://github.com/laurenspriem/mobile_ocr"+ source: git+ version: "1.0.0"mockito:dependency: "direct dev"description:@@ -2632,15 +2641,6 @@ packages:url: "https://pub.dev"source: hostedversion: "0.6.8"- text_detector:- dependency: "direct main"- description:- path: "."- ref: HEAD- resolved-ref: a2d2b2e0ae5705009f8d3a5e9645caf1c5ef5ace- url: "https://github.com/neeraj-pilot/text_detector.git"- source: git- version: "1.0.0"thermal:dependency: "direct main"description:diff --git a/mobile/apps/photos/pubspec.yaml b/mobile/apps/photos/pubspec.yamlindex 1bcb452055..1aa958f741 100644--- a/mobile/apps/photos/pubspec.yaml+++ b/mobile/apps/photos/pubspec.yaml@@ -136,6 +136,9 @@ dependencies:media_kit_libs_video:media_kit_video:ml_linalg: ^13.11.31+ mobile_ocr:+ git:+ url: https://github.com/laurenspriem/mobile_ocrmodal_bottom_sheet: ^3.0.0motion_photos:git: "https://github.com/ente-io/motion_photo.git"@@ -201,9 +204,6 @@ dependencies:syncfusion_flutter_sliders: ^29.1.38synchronized: ^3.3.0+3system_info_plus: ^0.0.6- text_detector:- git:- url: https://github.com/neeraj-pilot/text_detector.gitthermal: ^1.1.11timezone: ^0.10.0tuple: ^2.0.0