Can't Install ARCore on emulator for Android Studio

ⅰ亾dé卋堺 提交于 2019-11-29 10:45:58

For using an emulator, at first, you have to create a virtual device with AR support. I'm running Android Studio 3.4 on macOS Mojave.

You can follow the Android Studio instructions to Create a Virtual Device with AR support.

I created two virtual devices: the first is for Google Pixel 2 and the second is for Huawei P Smart 2019.

Go to ToolsAVD Manager main menu and create you AVD. My window looks like this:

Make sure that Camera Back is set to VirtualScene.

Here are some steps you have to do in order to get a working emulator:

  • Set up Android Debug Bridge. I set up adb for Mac.

  • Download ARCore_1.10_x86_for_emulator.apk from GitHub repository.

  • Run your AVD.

  • Type in Bash Terminal the following command (to be sure that the port is 5554):

    adb devices
    
  • Result:

    // emulator-5554    device
    
  • Go to the folder where ARCore_1.10_x86_for_emulator.apk is located. For instance:

    cd ~/Desktop
    
  • Type in Terminal for installing ARCore for AVD while the virtual device is running:

    adb install -r ARCore_1.10_x86_for_emulator.apk      
    
  • Repeat previous steps for additional AVDs you’d like to use.

  • Delight!

Hope this helps.

Just install to emulator ARCore_1_1_x86_for_emulator.apk. Just drug to emulator. Check this link https://github.com/google-ar/arcore-android-sdk/releases/tag/v1.1.0

Sergei's answer was right at the time, but the version of the ARCore app in his link (v1.1.0) is now too old. The following worked for me (after many false starts):

VIRTUAL DEVICE SPECIFICATIONS

Device: Pixel API 27

System image: Oreo / API Level 27 / ABI x86 / Android 8.1 (Google Play)

LINK TO ARCORE APK: https://www.apkmirror.com/apk/google-inc/arcore/arcore-1-5-18091013-release/arcore-1-5-180910139-android-apk-download/download/

Download the ARCore APK to your desktop. In Android Studio, set up and then start the virtual device as specified above, open the Play Store app on it and sign in. Then drag the ARCORE APK file onto the virtual device; it should silently install. Finally, run hellosceneform on the virtual device.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!