You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 4, 2023. It is now read-only.
Copy file name to clipboardExpand all lines: docs/ML_KIT.md
+8-2Lines changed: 8 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -118,8 +118,9 @@ The exact details of using the live camera view depend on whether or not you're
118
118
You can use any view-related property you like as we're extending `ContentView`.
119
119
So things like `class`, `row`, `width`, `horizontalAlignment`, `style` are all valid properties.
120
120
121
-
Plugin-specific are the optional properties `processEveryNthFrame` and `torchOn`, and optional event `scanResult`.
122
-
You can `processEveryNthFrame`set to a lower value than the default (5) to put less strain on the device.
121
+
Plugin-specific are the optional properties `processEveryNthFrame`, `preferFrontCamera` (default `false`), and `torchOn`, and the optional `scanResult` event.
122
+
123
+
You can set`processEveryNthFrame`set to a lower value than the default (5) to put less strain on the device.
123
124
Especially 'Face detection' seems a bit more CPU intensive, but for'Text recognition' the default is fine.
124
125
125
126
> Look at [the demo app](https://github.com/EddyVerbruggen/nativescript-plugin-firebase/tree/master/demo-ng) to see how to wire up that `onTextRecognitionResult` function, and how to wire `torchOn` to a `Switch`.
@@ -140,6 +141,7 @@ Now you're able to use the registered element in the view:
140
141
width="260"
141
142
height="380"
142
143
processEveryNthFrame="10"
144
+
preferFrontCamera="false"
143
145
[torchOn]="torchOn"
144
146
(scanResult)="onTextRecognitionResult($event)">
145
147
</MLKitTextRecognition>
@@ -158,6 +160,7 @@ Declare a namespace at the top of the embedding page, and use it anywhere on the
0 commit comments