From 397a729ed9eadda4c89e4f5c545e4d4998e1f029 Mon Sep 17 00:00:00 2001 From: Oleksandr Leuschenko <4376913+olexale@users.noreply.github.com> Date: Thu, 22 Oct 2020 14:11:52 +0300 Subject: [PATCH 1/2] Update README.md --- README.md | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 9c6f745..bc19c34 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ [![Codemagic build status](https://api.codemagic.io/apps/5cb0a01178f5790010ab6978/5cb0a01178f5790010ab6977/status_badge.svg)](https://codemagic.io/apps/5cb0a01178f5790010ab6978/5cb0a01178f5790010ab6977/latest_build) [![flutter awesome](https://img.shields.io/badge/Awesome-Flutter-blue.svg?longCache=true&style=flat-square)](https://github.com/Solido/awesome-flutter) [![pub package](https://img.shields.io/pub/v/arkit_plugin.svg)](https://pub.dartlang.org/packages/arkit_plugin) -**Note**: ARKit is only supported by mobile devices with A9 or later processors (iPhone 6s/7/SE/8/X, iPad 2017/Pro) on iOS 11 and newer. For some features iOS 12 is required. +**Note**: ARKit is only supported by mobile devices with A9 or later processors (iPhone 6s/7/SE/8/X, iPad 2017/Pro) on iOS 11 and newer. For some features iOS 12 or newer is required. ## Usage @@ -12,17 +12,18 @@ Follow the [installation instructions](https://pub.dartlang.org/packages/arkit_p ### Update Info.plist -The plugin use native view from ARKit, which is not yet supported by default. To make it work add the following code to `Info.plist`: -```xml - io.flutter.embedded_views_preview - YES -``` ARKit uses the device camera, so do not forget to provide the `NSCameraUsageDescription`. You may specify it in `Info.plist` like that: ```xml NSCameraUsageDescription Describe why your app needs AR here. ``` +Prior to Flutter 1.22, platform views were in developers preview, hence if you want to use the plugin with old Flutter versions you need to add the following code to `Info.plist`: +```xml + io.flutter.embedded_views_preview + YES +``` + ### Write the app The simplest code example: @@ -110,6 +111,12 @@ post_install do |installer| end ``` +## FAQ +- **Is it possible to use this plugin on Android?** +No, as ARKit is not available on Android. You might want to try [ARCore plugin](https://pub.dev/packages/arcore_flutter_plugin) instead. +- **My app crashes when I open the AR scene several times. Why?** +Most probably that's because you didn't call `dispose` method on the ARKit controller. + ## Contributing If you find a bug or would like to request a new feature, just [open an issue](https://github.com/olexale/arkit_flutter_plugin/issues/new). Your contributions are always welcome! From d0d108cb3c275f6e925878908e2bc591b4a8d82b Mon Sep 17 00:00:00 2001 From: Oleksandr Leuschenko <4376913+olexale@users.noreply.github.com> Date: Thu, 22 Oct 2020 14:15:57 +0300 Subject: [PATCH 2/2] Update README.md --- README.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/README.md b/README.md index bc19c34..5f6259a 100644 --- a/README.md +++ b/README.md @@ -116,6 +116,13 @@ end No, as ARKit is not available on Android. You might want to try [ARCore plugin](https://pub.dev/packages/arcore_flutter_plugin) instead. - **My app crashes when I open the AR scene several times. Why?** Most probably that's because you didn't call `dispose` method on the ARKit controller. +- **One of the features I need is merged in the repository, but is not available on pub.dev. How can I use the latest version?** +You may use the latest version by changing the `pubspec.yaml` dependency to: +```yaml +dependencies: + arkit_plugin: + git: git://github.com/olexale/arkit_flutter_plugin.git +``` ## Contributing