diff --git a/example/RNExampleApp/android/app/src/main/assets/trainedData/anyline_capitals.traineddata b/example/RNExampleApp/android/app/src/main/assets/tessdata/anyline_capitals.traineddata similarity index 100% rename from example/RNExampleApp/android/app/src/main/assets/trainedData/anyline_capitals.traineddata rename to example/RNExampleApp/android/app/src/main/assets/tessdata/anyline_capitals.traineddata diff --git a/example/RNExampleApp/android/app/src/main/assets/trainedData/deu.traineddata b/example/RNExampleApp/android/app/src/main/assets/tessdata/deu.traineddata similarity index 100% rename from example/RNExampleApp/android/app/src/main/assets/trainedData/deu.traineddata rename to example/RNExampleApp/android/app/src/main/assets/tessdata/deu.traineddata diff --git a/example/RNExampleApp/android/app/src/main/assets/trainedData/eng_no_dict.traineddata b/example/RNExampleApp/android/app/src/main/assets/tessdata/eng_no_dict.traineddata similarity index 100% rename from example/RNExampleApp/android/app/src/main/assets/trainedData/eng_no_dict.traineddata rename to example/RNExampleApp/android/app/src/main/assets/tessdata/eng_no_dict.traineddata diff --git a/example/RNExampleApp/config/EnergyConfig.js b/example/RNExampleApp/config/EnergyConfig.js index 954793b3..43c33e48 100755 --- a/example/RNExampleApp/config/EnergyConfig.js +++ b/example/RNExampleApp/config/EnergyConfig.js @@ -48,7 +48,7 @@ export default { tintColor: 'F21C0A', offset: { x: 0, - y: 500 + y: 400 } } }, diff --git a/example/RNExampleApp/config/IbanConfig.js b/example/RNExampleApp/config/IbanConfig.js index d5f7edc2..db47bb35 100755 --- a/example/RNExampleApp/config/IbanConfig.js +++ b/example/RNExampleApp/config/IbanConfig.js @@ -51,7 +51,7 @@ export default { ocr: { "scanMode": "AUTO", "tesseractLanguages": ["eng_no_dict", "deu"], - "traineddataFiles": ["trainedData/eng_no_dict.traineddata", "trainedData/deu.traineddata"], + "traineddataFiles": ["tessdata/eng_no_dict.traineddata", "tessdata/deu.traineddata"], "charWhitelist": "ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890", "validationRegex": "^[A-Z]{2}([0-9A-Z]\\s*){13,32}$", "minConfidence": 65, diff --git a/example/RNExampleApp/config/VoucherConfig.js b/example/RNExampleApp/config/VoucherConfig.js index b20e8f73..5cd911ff 100644 --- a/example/RNExampleApp/config/VoucherConfig.js +++ b/example/RNExampleApp/config/VoucherConfig.js @@ -49,7 +49,7 @@ export default { ocr: { "scanMode": "AUTO", "tesseractLanguages": ["anyline_capitals"], - "traineddataFiles": ["trainedData/anyline_capitals.traineddata"], + "traineddataFiles": ["tessdata/anyline_capitals.traineddata"], "charWhitelist": "ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789", "validationRegex": "[A-Z0-9]{8}$", "minConfidence": 85 diff --git a/example/RNExampleApp/package.json b/example/RNExampleApp/package.json index 5cf7377d..ffcecd54 100644 --- a/example/RNExampleApp/package.json +++ b/example/RNExampleApp/package.json @@ -7,8 +7,8 @@ "reinstall": "yarn remove anyline-ocr-react-native-module && yarn add ../../plugin && react-native link", "reinstall-pods": "cd ios/ && rm -rf Pods Podfile.lock && pod install --verbose && cd .. && react-native link", "test": "jest", - "bundleAndroid": "react-native bundle --platform android --dev false --entry-file index.android.js --bundle-output android/app/src/main/assets/index.android.bundle --assets-dest android/app/src/main/res/", - "bundleiOS": "react-native bundle --entry-file index.ios.js --platform ios --dev false --bundle-output ios/main.jsbundle --assets-dest ios" + "bundleAndroid": "react-native bundle --platform android --dev false --entry-file index.js --bundle-output android/app/src/main/assets/index.android.bundle --assets-dest android/app/src/main/res/", + "bundleiOS": "react-native bundle --entry-file index.js --platform ios --dev false --bundle-output ios/main.jsbundle --assets-dest ios" }, "dependencies": { "anyline-ocr-react-native-module": "../../plugin", diff --git a/example/RNExampleApp/yarn.lock b/example/RNExampleApp/yarn.lock index f688d65a..6b050aaa 100644 --- a/example/RNExampleApp/yarn.lock +++ b/example/RNExampleApp/yarn.lock @@ -93,7 +93,7 @@ ansi@^0.3.0, ansi@~0.3.1: resolved "https://registry.yarnpkg.com/ansi/-/ansi-0.3.1.tgz#0c42d4fb17160d5a9af1e484bace1c66922c1b21" anyline-ocr-react-native-module@../../plugin: - version "3.19.0" + version "3.20.0" anymatch@^1.3.0: version "1.3.2" diff --git a/plugin/android/build.gradle b/plugin/android/build.gradle index c46c9121..0536f9cf 100755 --- a/plugin/android/build.gradle +++ b/plugin/android/build.gradle @@ -57,7 +57,7 @@ repositories { dependencies { compile fileTree(dir: "libs", include: ["*.jar"]) compile 'com.android.support:appcompat-v7:25.1.0' - compile 'io.anyline:anylinesdk:3.19.0@aar' + compile 'io.anyline:anylinesdk:3.20.0@aar' compile 'com.google.android.gms:play-services-vision:10.0.1' compile 'com.android.support:design:25.1.0' compile "com.facebook.react:react-native:+" // From node_modules diff --git a/plugin/android/src/main/java/com/anyline/reactnative/AnylineOcrActivity.java b/plugin/android/src/main/java/com/anyline/reactnative/AnylineOcrActivity.java index 21c0f8b1..83458e70 100755 --- a/plugin/android/src/main/java/com/anyline/reactnative/AnylineOcrActivity.java +++ b/plugin/android/src/main/java/com/anyline/reactnative/AnylineOcrActivity.java @@ -71,6 +71,7 @@ protected void onCreate(Bundle savedInstanceState) { String[] languages = new String[languageArray.length()]; for (int i = 0; i < languages.length; i++) { languages[i] = languageArray.getString(i); + Log.d("languages", languages[i]); } ocrConfig.setLanguages(languages); }