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
Copy file name to clipboardExpand all lines: README.md
+4-2Lines changed: 4 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,7 +2,7 @@
2
2
3
3
# React Native Document Scanner (iOS only)
4
4
5
-
Live document detection library. Returns a base64 encoded string of the captured image, allowing you to easily store it or use it as you wish !
5
+
Live document detection library. Returns either a URI or a base64 encoded string of the captured image, allowing you to easily store it or use it as you wish !
6
6
7
7
Features :
8
8
- Live detection
@@ -47,6 +47,7 @@ class YourComponent extends Component {
47
47
return (
48
48
<View>
49
49
<DocumentScanner
50
+
useBase64
50
51
onPictureTaken={data=>this.setState({
51
52
image:data.croppedImage,
52
53
initialImage:data.initialImage,
@@ -83,6 +84,7 @@ class YourComponent extends Component {
83
84
| saturation |`1`|`float`| Increase or decrease camera saturation. Set `0` for black & white |
84
85
| contrast |`1`|`float`| Increase or decrease camera contrast. Normal as default |
85
86
| quality |`0.8`|`float`| Image compression. Reduces both image size and quality |
87
+
| useBase64 |`false`|`bool`| If base64 representation should be passed instead of image uri's |
86
88
87
89
## Manual capture
88
90
@@ -119,7 +121,7 @@ Enum (0, 1 or 2) corresponding to the type of rectangle found
| onPictureTaken |`data`|`object`| Returns the captured image in an object `{ croppedImage: 'BASE64 string', initialImage: 'BASE64 string', rectangleCoordinates: 'object of coordinates' }`|
124
+
| onPictureTaken |`data`|`object`| Returns the captured image in an object `{ croppedImage: ('URI or BASE64 string'), initialImage: 'URI or BASE64 string', rectangleCoordinates: 'object of coordinates' }`|
0 commit comments