Flutter Plugin for AR (Augmented Reality) - Supports ARKit on iOS and ARCore on Android devices

Overview

ar_flutter_plugin

Flutter Plugin for AR (Augmented Reality) - Supports ARKit for iOS and ARCore for Android devices.

Many thanks to Oleksandr Leuschenko for the arkit_flutter_plugin and to Gian Marco Di Francesco for the arcore_flutter_plugin which both served as a great basis and starting point for this project.

Getting Started

This plugin is still a work in progress. Keep posted for updates or contribute by creating a pull request!

If you still want to use the plugin before it's officially released, add the following to your pubspec.yaml file:

dependencies:
  ar_flutter_plugin:
    git: git://github.com/CariusLars/ar_flutter_plugin.git

To try out the plugin, it is best to have a look at one of the following examples implemented in the Example app:

Example Name Description Link to Code
Debug Options Simple AR scene with toggles to visualize the world origin, feature points and tracked planes Debug Options Code
Local & Online Objets AR scene with buttons to place GLTF objects from the flutter asset folders or GLB objects from the internet at a given position, rotation and scale. Additional buttons allow to modify scale, position and orientation with regard to the world origin after objects have been placed Local & Online Objects Code
Objects & Anchors on Planes AR Scene in which tapping on a plane creates an anchor with a 3D model attached to it Objects & Anchors on Planes Code
Cloud Anchors NOT IMPLEMENTED YET. Will allow to place, upload and download objects. Cloud Anchors Code

Roadmap

The first goal of this plugin is to provide collaborative AR functionality through cloud anchors on Android and iOS. The plugin will provide an easy interface for placing custom models (ideally from the web) onto planes and sharing the annotations across devices through app-specific channels (to allow "subscription" of certain annotations). GPS-tagging anchors will be supported to allow efficient querying of anchors by a device's location. A first architecture could look like this:

ar_plugin_architecture

The cloud backends shown above are only exemplary, the plugin will allow the user to attach their own backend, an example utilizing Firebase will be added to the /example folder.

Later, additional functionality like image anchors, light estimation, etc. will be added to create a full-fledged cross-platform AR plugin for flutter.

Contributing

Contributions to this plugin are very welcome. To contribute code and discuss ideas, create a pull request or open an issue.

Comments
  • fix: session was not closed issue in Android

    fix: session was not closed issue in Android

    Hi Guys, I fixed error in Android!

    In version 0.6.0, the app turned off after 30 times dispose. In version 0.6.1, the app turned off after 70 times dispose. And now, The app does not turn off after dispose! The animation continued to be soft and the amount of heat generated became very low. Overall, it was optimized.

    opened by Koobonik 14
  • Add support to calculate distance between device and anchor and distance between two anchors

    Add support to calculate distance between device and anchor and distance between two anchors

    This pull request implements two functionalities that are required for many use cases:

    • calculate distance from device to anchor
    • calculate distance between two anchors

    The distance is counted in meters and uses the Vector 3 square root method.
    Method getCameraPose() that obtains device coordinates is required and was cloned from gps branch

    Methods added in ar_session_manager.dart along with the required platform code in Swift and Kotlin:

    • getPose(ARAnchor anchor): Returns the given anchor pose in Matrix4 format with respect to the world coordinate system of the ARView.
    • getDistanceBetweenAnchors(ARAnchor anchor1, ARAnchor anchor2): Returns the distance in meters between @anchor1 and @anchor2.
    • getDistanceFromAnchor(ARAnchor anchor): Returns the distance in meters between @anchor and device's camera.
    • getDistanceBetweenVectors(Vector3 vector1, Vector3 vector2): Returns the distance in meters between @vector1 and @vector2.
    opened by dnkoulouris 11
  • Most of my 3D models does not appear in view

    Most of my 3D models does not appear in view

    Most of my 3D models does not appear in the view widget For unknown reasons, only 1 of 10 models appears in the ARView(gltf)

    I use type: NodeType.webGLB and type: NodeType.localGLTF2 models (*.glb , *.gltf appropriately)

    No errors no warnings

    For gltf [ +142 ms] flutter: iOS platform view created! [ +174 ms] flutter: [ObjectTEST from iOS]

    For glb [ +153 ms] flutter: iOS platform view created! [ +49 ms] flutter: [ObjectTEST from iOS] [ +131 ms] Async Model Downloading Task completed: finished

    client: IOS 14.7.1 IPHONE SE(old model) environment: ar_flutter_plugin: ^0.6.1 Flutter (Channel master, 2.6.0-12.0.pre.675, on Mac OS X 10.15.7 19H524 darwin-x64, locale en-UA) Xcode - develop for iOS and macOS (Xcode 12.4) VS Code (version 1.48.2)

    Please help to solve the issue, my project strongly relies on the AR objects displayed

    opened by svyazist2005 7
  • Out of mem issue

    Out of mem issue

    Hi,

    Our model file is over 50MB and in GLD format that it always throw out of mem exception when loading the model.

    Do you have any idea to help us fix it? (setting android:largeHeap="true" is the same).

    We have tried by converting that GLD file to GLTF format, and it works fine. But it seems it only work when we put the GLTF file to asset folder. If we change to use custom file location, it throws File not found exception. Do you have any idea to fix it?

    Really appreciate for your help!

    opened by lecanhhiep 7
  • added scaling (pinch) functionality

    added scaling (pinch) functionality

    For Android i have added pinchgesture functionality in order to be able to scale the model. Only problem i did not found to set a limit on max or min scale. AndroidARView.zip libs.zip

    opened by SebastianAT 6
  • fix addNode to return true when node is added to anchor

    fix addNode to return true when node is added to anchor

    Hey, as mentioned in #113 the addNode function returns false every time when the node is added to an anchor. In the changes from v0.6.3 true is only returned if the node is added to the scene and not if the node is added to an anchor.

    I added the return for each Node-Type in Andorid and iOS. I have checked it for Andoroid but can't do it for iOS.

    opened by Levizzel 6
  • Help: How can I delete the selected object?

    Help: How can I delete the selected object?

    I was able to delete the last insert object with the code below, but i wanted to delect the current selected object, it would be appreciated if you can provide me a sample code of delete current selected object, thanks.

    Future onRemoveSingle() async { this.arAnchorManager.removeAnchor(this.anchors.last); }

    opened by raysonlim77 6
  • Model Show in Black and white

    Model Show in Black and white

    hello , everyone i have a aproblem with plugin in Colors , i see model show as grey or black and white , i don't know why (screenshot attached)!

    well done guys , really good plugin .

    image

    opened by ehabme 5
  • Issue when building

    Issue when building

    Google 3A PIXEL XL EMULATOR,

    RUNNIG ANY OF THE EXAMPLE CODES PRODUCE THIS ERROR

    Launching lib\main.dart on Android SDK built for x86 in debug mode...
    Running Gradle task 'assembleDebug'...
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionManager.java:58: error: cannot find symbol
                status = Environment.isExternalStorageManager()
                                    ^
      symbol:   method isExternalStorageManager()
      location: class Environment
    ....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionManager.java:144: error: cannot find symbol
                    if (Build.VERSION.SDK_INT < Build.VERSION_CODES.Q) {
                                                                   ^
      symbol:   variable Q
      location: class VERSION_CODES
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionManager.java:250: error: cannot find symbol
                        if (permission == PermissionConstants.PERMISSION_GROUP_MANAGE_EXTERNAL_STORAGE && Build.VERSION.SDK_INT < Build.VERSION_CODES.R) {
                                                                                              ^
      symbol:   variable R
      location: class VERSION_CODES
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionManager.java:264: error: cannot find symbol
                } else if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.R && permission == PermissionConstants.PERMISSION_GROUP_MANAGE_EXTERNAL_STORAGE) {
                                                                       ^
      symbol:   variable R
      location: class VERSION_CODES
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionManager.java:266: error: cannot find symbol
                            Settings.ACTION_MANAGE_APP_ALL_FILES_ACCESS_PERMISSION,
                                    ^
      symbol:   variable ACTION_MANAGE_APP_ALL_FILES_ACCESS_PERMISSION
      location: class Settings
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionManager.java:336: error: cannot find symbol
                    if (Build.VERSION.SDK_INT < Build.VERSION_CODES.R) {
                                                                   ^
      symbol:   variable R
      location: class VERSION_CODES
    C:\Users\Comma\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionManager.java:367: error: cannot find symbol
                        if (Build.VERSION.SDK_INT < Build.VERSION_CODES.R) {
                                                                       ^
      symbol:   variable R
      location: class VERSION_CODES
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionManager.java:371: error: cannot find symbol
                        return Environment.isExternalStorageManager()
                                          ^
      symbol:   method isExternalStorageManager()
      location: class Environment
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:33: error: cannot find symbol
                case Manifest.permission.ACCESS_BACKGROUND_LOCATION:
                                        ^
      symbol:   variable ACCESS_BACKGROUND_LOCATION
      location: class permission
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:47: error: cannot find symbol
                case Manifest.permission.BIND_CALL_REDIRECTION_SERVICE:
                                        ^
      symbol:   variable BIND_CALL_REDIRECTION_SERVICE
      location: class permission
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:60: error: cannot find symbol
                case Manifest.permission.ACCESS_MEDIA_LOCATION:
                                        ^
      symbol:   variable ACCESS_MEDIA_LOCATION
      location: class permission
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:62: error: cannot find symbol
                case Manifest.permission.ACTIVITY_RECOGNITION:
                                        ^
      symbol:   variable ACTIVITY_RECOGNITION
      location: class permission
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:64: error: cannot find symbol
                case Manifest.permission.MANAGE_EXTERNAL_STORAGE:
                                        ^
      symbol:   variable MANAGE_EXTERNAL_STORAGE
      location: class permission
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:72: error: cannot find symbol
                case Manifest.permission.BLUETOOTH_SCAN:
                                        ^
      symbol:   variable BLUETOOTH_SCAN
      location: class permission
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:74: error: cannot find symbol
                case Manifest.permission.BLUETOOTH_ADVERTISE:
                                        ^
      symbol:   variable BLUETOOTH_ADVERTISE
      location: class permission
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:76: error: cannot find symbol
                case Manifest.permission.BLUETOOTH_CONNECT:
                                        ^
      symbol:   variable BLUETOOTH_CONNECT
      location: class permission
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:115: error: cannot find symbol
                    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q) {
                                                                    ^
      symbol:   variable Q
      location: class VERSION_CODES
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:116: error: cannot find symbol
                        if (hasPermissionInManifest(context, permissionNames, Manifest.permission.ACCESS_BACKGROUND_LOCATION))
                                                                                              ^
      symbol:   variable ACCESS_BACKGROUND_LOCATION
      location: class permission
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:117: error: cannot find symbol
                            permissionNames.add(Manifest.permission.ACCESS_BACKGROUND_LOCATION);
                                                                   ^
      symbol:   variable ACCESS_BACKGROUND_LOCATION
      location: class permission
    C:\Users\Comma\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:139: error: cannot find symbol
                    if (android.os.Build.VERSION.SDK_INT > Build.VERSION_CODES.Q && hasPermissionInManifest(context, permissionNames, Manifest.permission.READ_PHONE_NUMBERS)) {
                                                                              ^
      symbol:   variable Q
      location: class VERSION_CODES
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:158: error: cannot find symbol
                    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q && hasPermissionInManifest(context, permissionNames, Manifest.permission.BIND_CALL_REDIRECTION_SERVICE))
                                                                    ^
      symbol:   variable Q
      location: class VERSION_CODES
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:158: error: cannot find symbol
                    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q && hasPermissionInManifest(context, permissionNames, Manifest.permission.BIND_CALL_REDIRECTION_SERVICE))
                                                                                              ^
      symbol:   variable BIND_CALL_REDIRECTION_SERVICE
      location: class permission
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:159: error: cannot find symbol
                        permissionNames.add(Manifest.permission.BIND_CALL_REDIRECTION_SERVICE);
                                                               ^
      symbol:   variable BIND_CALL_REDIRECTION_SERVICE
      location: class permission
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:195: error: cannot find symbol
                    if (Build.VERSION.SDK_INT < Build.VERSION_CODES.Q || (Build.VERSION.SDK_INT == Build.VERSION_CODES.Q && Environment.isExternalStorageLegacy())) {
                                                                   ^
      symbol:   variable Q
      location: class VERSION_CODES
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:195: error: cannot find symbol
                    if (Build.VERSION.SDK_INT < Build.VERSION_CODES.Q || (Build.VERSION.SDK_INT == Build.VERSION_CODES.Q && Environment.isExternalStorageLegacy())) {
                                                                                              ^
      symbol:   variable Q
      location: class VERSION_CODES
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:195: error: cannot find symbol
                    if (Build.VERSION.SDK_INT < Build.VERSION_CODES.Q || (Build.VERSION.SDK_INT == Build.VERSION_CODES.Q && Environment.isExternalStorageLegacy())) {
                                                                                              ^
      symbol:   method isExternalStorageLegacy()
      location: class Environment
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:210: error: cannot find symbol
                    if (Build.VERSION.SDK_INT < Build.VERSION_CODES.Q)
                                                                   ^
      symbol:   variable Q
      location: class VERSION_CODES
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:213: error: cannot find symbol
                    if(hasPermissionInManifest(context, permissionNames, Manifest.permission.ACCESS_MEDIA_LOCATION))
                                                                                            ^
      symbol:   variable ACCESS_MEDIA_LOCATION
      location: class permission
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:214: error: cannot find symbol
                        permissionNames.add(Manifest.permission.ACCESS_MEDIA_LOCATION);
                                                               ^
      symbol:   variable ACCESS_MEDIA_LOCATION
      location: class permission
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:220: error: cannot find symbol
                    if (Build.VERSION.SDK_INT < Build.VERSION_CODES.Q)
                                                                   ^
      symbol:   variable Q
      location: class VERSION_CODES
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:223: error: cannot find symbol
                    if (hasPermissionInManifest(context, permissionNames, Manifest.permission.ACTIVITY_RECOGNITION))
                                                                                             ^
      symbol:   variable ACTIVITY_RECOGNITION
      location: class permission
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:224: error: cannot find symbol
                        permissionNames.add(Manifest.permission.ACTIVITY_RECOGNITION);
                                                               ^
      symbol:   variable ACTIVITY_RECOGNITION
      location: class permission
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:235: error: cannot find symbol
                    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.R && hasPermissionInManifest(context, permissionNames, Manifest.permission.MANAGE_EXTERNAL_STORAGE ))
                                                                    ^
      symbol:   variable R
      location: class VERSION_CODES
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:235: error: cannot find symbol
                    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.R && hasPermissionInManifest(context, permissionNames, Manifest.permission.MANAGE_EXTERNAL_STORAGE ))
                                                                                              ^
      symbol:   variable MANAGE_EXTERNAL_STORAGE
      location: class permission
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:236: error: cannot find symbol
                        permissionNames.add(Manifest.permission.MANAGE_EXTERNAL_STORAGE);
                                                               ^
      symbol:   variable MANAGE_EXTERNAL_STORAGE
      location: class permission
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:259: error: cannot find symbol
                    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.S && hasPermissionInManifest(context, permissionNames, Manifest.permission.BLUETOOTH_SCAN ))
                                                                    ^
      symbol:   variable S
      location: class VERSION_CODES
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:259: error: cannot find symbol
                    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.S && hasPermissionInManifest(context, permissionNames, Manifest.permission.BLUETOOTH_SCAN ))
                                                                                              ^
      symbol:   variable BLUETOOTH_SCAN
      location: class permission
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:260: error: cannot find symbol
                        permissionNames.add(Manifest.permission.BLUETOOTH_SCAN);
                                                               ^
      symbol:   variable BLUETOOTH_SCAN
      location: class permission
    .....\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:265: error: cannot find symbol
                    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.S && hasPermissionInManifest(context, permissionNames, Manifest.permission.BLUETOOTH_ADVERTISE ))
                                                                    ^
      symbol:   variable S
      location: class VERSION_CODES
    ...\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:265: error: cannot find symbol
                    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.S && hasPermissionInManifest(context, permissionNames, Manifest.permission.BLUETOOTH_ADVERTISE ))
                                                                                              ^
      symbol:   variable BLUETOOTH_ADVERTISE
      location: class permission
    ...\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:266: error: cannot find symbol
                        permissionNames.add(Manifest.permission.BLUETOOTH_ADVERTISE);
                                                               ^
      symbol:   variable BLUETOOTH_ADVERTISE
      location: class permission
    ...\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:271: error: cannot find symbol
                    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.S && hasPermissionInManifest(context, permissionNames, Manifest.permission.BLUETOOTH_CONNECT ))
                                                                    ^
      symbol:   variable S
      location: class VERSION_CODES
    ...\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:271: error: cannot find symbol
                    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.S && hasPermissionInManifest(context, permissionNames, Manifest.permission.BLUETOOTH_CONNECT ))
                                                                                              ^
      symbol:   variable BLUETOOTH_CONNECT
      location: class permission
    ...\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\permission_handler-8.2.2\android\src\main\java\com\baseflow\permissionhandler\PermissionUtils.java:272: error: cannot find symbol
                        permissionNames.add(Manifest.permission.BLUETOOTH_CONNECT);
                                                               ^
      symbol:   variable BLUETOOTH_CONNECT
      location: class permission
    44 errors
    
    FAILURE: Build failed with an exception.
    
    * What went wrong:
    Execution failed for task ':permission_handler:compileDebugJavaWithJavac'.
    > Compilation failed; see the compiler error output for details.
    
    * Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
    
    * Get more help at https://help.gradle.org
    
    BUILD FAILED in 25s
    Exception: Gradle task assembleDebug failed with exit code 1
    

    Flutter Version is 2.5.1

    I followed the setting up following this article https://medium.com/flutterdevs/augmented-reality-in-flutter-1153b0ef2758

    Nothing seems to help

    opened by MalekHAMID 5
  • Thanks for this!

    Thanks for this!

    thanks for this starting this package, this was quite needed as I recently struggled with implementing AR in my android app. and that's a very ambitious goal and architecture which I hope to help and see soon come alive.

    In the current ar_core_flutter_plugin, it uses scenform, which was the major bottleneck. I also saw sceneform as a part of this, but also google-ar-core, I wanted to confirm and understand how this is better than the previous implementation and will it truly give flutter the power to utilize all AR features?

    P.S, I'd like to get involved more and contribute, it'd be great if you can create discord, gitter, or just open the discussions tab.

    opened by Sameerkash 5
  • iOS app pemission doesn't work

    iOS app pemission doesn't work

    When I enter the ar view despite the camera permission being enabled, the plugin remains in the grant permission screen

    -->this is my part of podfile i've added `post_install do |installer| installer.pods_project.targets.each do |target| flutter_additional_ios_build_settings(target) target.build_configurations.each do |config| if target.respond_to?(:product_type) and target.product_type == "com.apple.product-type.bundle" target.build_configurations.each do |config| config.build_settings['CODE_SIGNING_ALLOWED'] = 'NO' # Additional configuration options could already be set here

        # BEGINNING OF WHAT YOU SHOULD ADD
        config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] ||= [
          '$(inherited)',
    
          ## dart: PermissionGroup.camera
          'PERMISSION_CAMERA=1',
    
          ## dart: PermissionGroup.photos
          'PERMISSION_PHOTOS=1',
    
          ## dart: [PermissionGroup.location, PermissionGroup.locationAlways, PermissionGroup.locationWhenInUse]
          'PERMISSION_LOCATION=1',
    
          ## dart: PermissionGroup.sensors
          'PERMISSION_SENSORS=1',
    
          ## dart: PermissionGroup.bluetooth
          'PERMISSION_BLUETOOTH=1',
    
          # add additional permission groups if required
        ]
        # END OF WHAT YOU SHOULD ADD
        end
        end
      end
    end
    

    end`

    IMG_7023

    opened by giovannicampagnolo 4
  • Could not resolve com.google.ar:core:1.22.0.

    Could not resolve com.google.ar:core:1.22.0.

    FAILURE: Build failed with an exception.

    • What went wrong: A problem occurred configuring project ':firebase_dynamic_links'.

    Could not resolve all files for configuration ':firebase_dynamic_links:classpath'. Could not resolve com.android.tools.build:gradle:7.0.2. Required by: project :firebase_dynamic_links > Could not resolve com.android.tools.build:gradle:7.0.2. > Could not get resource 'https://dl.google.com/dl/android/maven2/com/android/tools/build/gradle/7.0.2/gradle-7.0.2.pom'. > Could not GET 'https://dl.google.com/dl/android/maven2/com/android/tools/build/gradle/7.0.2/gradle-7.0.2.pom'. > The server may not support the client's requested TLS protocol versions: (TLSv1.2, TLSv1.3). You may need to configure the client to allow other protocols to be used. See: https://docs.gradle.org/7.4/userguide/build_environment.html#gradle_system_properties > PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target Failed to notify project evaluation listener. Could not get unknown property 'android' for project ':firebase_dynamic_links' of type org.gradle.api.Project. Could not find method implementation() for arguments [project ':firebase_core'] on object of type org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler. Could not get unknown property 'android' for project ':firebase_dynamic_links' of type org.gradle.api.Project.

    • Try:

    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

    • Get more help at https://help.gradle.org

    BUILD FAILED in 14s Retrying Gradle Build: #1, wait time: 100ms [!] Gradle threw an error while downloading artifacts from the network.

    opened by ayushprateek 0
  • ScaffoldMessenger.showSnackBar crashing app when no Scaffold is present

    ScaffoldMessenger.showSnackBar crashing app when no Scaffold is present

    Hello!

    I have an ARView embedded in a CupertinoPageScaffold. When ARSessionManager throws any errors, it tries to access the a ScaffoldMessenger that doesn't exist because I'm not using a Material Scaffold. This causes a crash. Can you please make this so it fails gracefully if there's no Scaffold present?

    opened by colejd 0
  • Ios issue

    Ios issue

    Hi, I am trying to run this program. In Android, it's working well and fine. But in Ios the object is not showing, it just shows the camera is on. The following is the error in got in Xcode:

    [SceneKit] Error: missing value for attachment "alpha cutoff" [vertex: -1 fragment: 14] The operation couldn’t be completed. (NSURLErrorDomain error -1100.)

    [Session] ARSession <0x103dbcb40>: ARSessionDelegate is retaining 11 ARFrames. This can lead to future camera frames being dropped.

    can anybody help me, please?

    opened by ramyajaganathan 0
  • Place anchor based on XY screen coordinates and update ARCore SDK to 1.35.0

    Place anchor based on XY screen coordinates and update ARCore SDK to 1.35.0

    A pull request that adds functionality to place an anchor at the X,Y coordinates of the screen.

    I also did some updates to ARCore libraries, in order to have the most recent available versions.

    Just call:

    // Places anchor in given 2D coordinates (starting from the top-left side of the screen)
    placeBasedOnScreenCoordinates(double x, double y)
    

    and an Anchor will be placed at the exact spot

    opened by dnkoulouris 1
  • Occasional black screen on sample application.

    Occasional black screen on sample application.

    From flutter Android application (Android 12, Galaxy S21), I'm trying to use ar_flutter_plugin at flutter 3.3.5, and rarely, I got a black screen when enabling AR view. so, I tried sample application, and it was reproducible at sample application too.

    Curious thing is, there are no difference between normal situation and black screen in the perspective of log.

    Is there any solution for this? I was trying to solve this problem and propose PR for this, but I'm not sure what is reason of this because there are no clue in the log too.. error_log.txt normal_log.txt

    https://user-images.githubusercontent.com/6769075/203282290-6ff6c381-883b-4075-8f4c-f21cb2c82826.mp4

    opened by wangmir 0
Releases(v0.7.3)
Owner
Lars Carius
Lars Carius
Permission plugin for Flutter. This plugin provides a cross-platform (iOS, Android) API to request and check permissions.

On most operating systems, permissions aren't just granted to apps at install time. Rather, developers have to ask the user for permissions while the

Baseflow 1.7k Jan 3, 2023
File picker plugin for Flutter, compatible with both iOS & Android and desktop (go-flutter).

File Picker A package that allows you to use the native file explorer to pick single or multiple files, with extensions filtering support. Currently s

Miguel Ruivo 985 Jan 5, 2023
A Flutter plugin to easily handle realtime location in iOS and Android. Provides settings for optimizing performance or battery.

Flutter Location Plugin This plugin for Flutter handles getting location on Android and iOS. It also provides callbacks when location is changed. Gett

Guillaume Bernos 953 Dec 22, 2022
Flutter geolocation plugin for Android and iOS.

geolocation Flutter geolocation plugin for Android API 16+ and iOS 9+. Features: Manual and automatic location permission management Current one-shot

Loup 221 Dec 27, 2022
A Flutter plugin for displaying local notifications on Android, iOS and macOS

Flutter Local Notifications plugin This repository consists hosts the following packages flutter_local_notifications: code for the cross-platform faci

Michael Bui 2.1k Dec 30, 2022
Android and iOS Geolocation plugin for Flutter

Flutter Geolocator Plugin A Flutter geolocation plugin which provides easy access to platform specific location services (FusedLocationProviderClient

Baseflow 1k Jan 5, 2023
Telegram stickers importing Flutter plugin for iOS and Android

TelegramStickersImport — Telegram stickers importing Flutter plugin for iOS and Android TelegramStickersImport helps your users import third-party pro

Iurii Dorofeev 20 Dec 3, 2022
Plugin to retrieve a persistent UDID across app reinstalls on iOS and Android.

flutter_udid Plugin to retrieve a persistent UDID across app reinstalls on iOS and Android. Getting Started import 'package:flutter_udid/flutter_udid.

Leon Kukuk 183 Dec 21, 2022
Support to update the app badge on the launcher (both for Android and iOS)

Flutter App Badger plugin This plugin for Flutter adds the ability to change the badge of the app in the launcher. It supports iOS and some Android de

Edouard Marquez 258 Dec 25, 2022
A Flutter plugin that allows you to add an inline webview, to use a headless webview, and to open an in-app browser window.

Flutter InAppWebView Plugin A Flutter plugin that allows you to add an inline webview, to use an headless webview, and to open an in-app browser windo

Lorenzo Pichilli 2.3k Jan 8, 2023
A Flutter plugin that allows you to check if an app is installed/enabled, launch an app and get the list of installed apps.

Flutter AppAvailability Plugin A Flutter plugin that allows you to check if an app is installed/enabled, launch an app and get the list of installed a

Lorenzo Pichilli 89 Dec 2, 2022
A lightweight Flutter plugin for making payments and printing on MyPos

my_poster ?? my_poster is in beta - please provide feedback (and/or contribute) if you find issues ??️ A lightweight Flutter plugin for making payment

Antonio Mentone 3 Oct 10, 2022
Flutter library for iOS Widgets Extensions. Integrate a Widget into your App 🍏📱

flutter_widgetkit Flutter Library for the iOS ?? WidgetKit framework and Widget Communication Table of Contents ?? Introduction ??‍?? Installation ??‍

Fasky 227 Dec 31, 2022
Plugin to access VPN service for Flutter | Flutter 的 VPN 插件

Flutter VPN plugin This plugin help developers to access VPN service in their flutter app. 本插件帮助开发者在自己的应用内调用 VPN 服务。 The Android part was implemented

Xdea 277 Dec 28, 2022
Community WebView Plugin - Allows Flutter to communicate with a native WebView.

NOTICE We are working closely with the Flutter Team to integrate all the Community Plugin features in the Official WebView Plugin. We will try our bes

Flutter Community 1.4k Jan 7, 2023
Use dynamic and beautiful card view pagers to help you create great apps.

Use dynamic and beautiful card view pagers to help you create great apps. Preview New Feature v1.3.0 Change Alignment Left Center(Default) Right v1.4.

Jeongtae Kim 84 Dec 6, 2022
Flutter plugin for ARCore SDK, Android platform to build new augmented reality experiences

arcore_flutter_plugin Thanks to Oleksandr Leuschenko for inspiration and his precious code: arkit_flutter_plugin Usage I wrote 2 articles for setup yo

Gian Marco Di Francesco 360 Dec 25, 2022
ParkPort is a smartphone application that utilizes geolocation to guide the user to explore Tulsa's parks and collect augmented reality stamps.

A smartphone application that utilizes geolocation to guide the user to explore Tulsa's parks and collect augmented reality stamps.

Adam Taylor 5 Dec 20, 2022
A Flutter Augmented Reality based Furniture App which can help users to virtually try on furniture to their smartphone with personalized instructions

A Flutter Augmented Reality based Furniture App which can help users to virtually try on furniture to their smartphone with personalized instructions

Saksham Jain 9 Dec 10, 2022
Simple Augmented Reality App

Flutter DeepAR Star ⭐ the repo if you like what you see ?? . ✨ Requirements Any Operating System (ie. MacOS X, Linux, Windows) Any IDE with Flutter SD

Ghoudan Ayoub 3 Dec 28, 2022