无法在Android Studio的模拟器上安装ARCore [英] Can't Install ARCore on emulator for Android Studio
问题描述
我不知道是否可以问这个问题,但我真的不知道如何在Android仿真设备上使用ARCore. 根据官方指南,我应该在像素/像素2设备上使用API 8.1,以便运行任何使用ARCore的应用.遗憾的是,这些模拟器没有对Play商店的支持,没有Play商店,我将无法在设备上安装ARCore. Play商店内置的设备映像不能运行ARCore. 我对如何以这种方式为ARCore测试任何东西感到非常困惑. 我需要它来开发用于大学课程的应用程序,并且需要熟悉增强现实开发,但是由于这个问题,我什至无法入门.
I don't know if I'm allowed to ask this question but I really can't figure out how to use ARCore on Android Emulated Device. According to the official guide I'm supposed to use API 8.1 on pixel/pixel 2 device in order to run any app which uses ARCore. Sadly those emulator don't come with the support for Play Store, and without Play Store I can't Instal ARCore on the device. The device images that come with built in Play Store can't run ARCore instead. I'm really confused about how am I supposed to test anything for ARCore in this way. I need it to develop an app for a University program and I need to become familiar with Augmented Reality Development but I can't even get started because of this issue.
推荐答案
更新时间:2020年3月30日.
要使用此仿真器,首先必须创建一个支持AR的虚拟设备.我正在macOS Catalina 10.15.4上运行Android Studio 4.0.
For using this emulator, at first, you have to create a virtual device with support of AR. I'm running Android Studio 4.0 on macOS Catalina 10.15.4.
您可以按照 Android Studio的说明创建具有AR支持的虚拟设备一个>.
我创建了两个虚拟设备:第一个用于Google Pixel
,第二个用于Huawei
.
I created two virtual devices: the first is for Google Pixel
and the second is for Huawei
.
转到Tools
– AVD Manager
主菜单,然后创建您的AVD.我的窗口看起来像这样:
Go to Tools
– AVD Manager
main menu and create you AVD. My window looks like this:
确保将Camera Back设置为VirtualScene
.
Make sure that Camera Back is set to VirtualScene
.
要获得有效的仿真器,您需要执行以下步骤:
-
设置Android调试桥.我为Mac设置了
adb
.Set up Android Debug Bridge. I set up
adb
for Mac.从GitHub下载 ARCore_1.15_x86_for_emulator.apk 存储库.
Download ARCore_1.15_x86_for_emulator.apk from GitHub repository.
运行您的AVD.
在Bash Terminal中键入以下命令(以确保端口为5554):
Type in Bash Terminal the following command (to be sure that the port is 5554):
adb devices
-
结果:
Result:
// emulator-5554 device
-
转到
ARCore_1.15_x86_for_emulator.apk
所在的文件夹.例如: Go to the folder where
ARCore_1.15_x86_for_emulator.apk
is located. For instance:cd ~/Desktop
-
键入终端以在虚拟设备运行时为AVD 安装ARCore :
adb install -r ARCore_1.15_x86_for_emulator.apk
-
为要使用的其他AVD重复前面的步骤.
Repeat previous steps for additional AVDs you’d like to use.
高兴!
这篇关于无法在Android Studio的模拟器上安装ARCore的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!