Update android install steps

This commit is contained in:
mrousavy 2021-03-07 11:23:41 +01:00
parent 6004abcec5
commit 28896ab4cc
2 changed files with 23 additions and 3 deletions

View File

@ -62,7 +62,18 @@ Open your project's `AndroidManifest.xml` and add the following lines inside the
<uses-permission android:name="android.permission.RECORD_AUDIO" /> <uses-permission android:name="android.permission.RECORD_AUDIO" />
``` ```
Make sure your Android SDK version is `30` or higher, see [the example app's `build.gradle`](https://github.com/cuvent/react-native-vision-camera/blob/main/example/android/build.gradle#L6-L9) for reference. #### Compatibility
VisionCamera requires a minimum Android SDK version of 21, and a target SDK version of 30 or higher. See [the example app's `build.gradle`](https://github.com/cuvent/react-native-vision-camera/blob/main/example/android/build.gradle#L6-L9) for reference.
Open your project's `build.gradle`, and set the following values:
```
buildToolsVersion = "30.0.0"
minSdkVersion = 21
compileSdkVersion = 30
targetSdkVersion = 30
```
## Permissions ## Permissions

View File

@ -43,8 +43,17 @@ Before opening an issue, make sure you try the following:
2. Set `buildToolsVersion` to `30.0.0` or higher 2. Set `buildToolsVersion` to `30.0.0` or higher
3. Set `compileSdkVersion` to `30` or higher 3. Set `compileSdkVersion` to `30` or higher
4. Set `targetSdkVersion` to `30` or higher 4. Set `targetSdkVersion` to `30` or higher
3. If you're experiencing weird behaviour, check the logs in Android Studio/Logcat (<kbd>⌘</kbd> + <kbd>6</kbd>) to find out more. 5. Set `minSdkVersion` to `21` or higher
4. If a camera device is not being returned by `getAvailableCameraDevices()`, make sure it meets the minimum requirements - that is minum supported harwdware level of `LIMITED` and above. See [this section in the Android docs](https://developer.android.com/reference/android/hardware/camera2/CameraDevice) for more information. 6. Update the Gradle Build-Tools version to `4.1.2` or higher:
```
classpath("com.android.tools.build:gradle:4.1.2")
```
3. Make sure your Gradle Wrapper version is 6.5 or higher. In `gradle-wrapper.properties`, set:
```
distributionUrl=https\://services.gradle.org/distributions/gradle-6.5-all.zip
```
4. If you're experiencing weird behaviour, check the logs in Android Studio/Logcat (<kbd>⌘</kbd> + <kbd>6</kbd>) to find out more.
5. If a camera device is not being returned by `getAvailableCameraDevices()`, make sure it meets the minimum requirements - that is minum supported harwdware level of `LIMITED` and above. See [this section in the Android docs](https://developer.android.com/reference/android/hardware/camera2/CameraDevice) for more information.
## Issues ## Issues