Android 模拟器:无法获取 wglGetExtensionsStringARB 错误

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/11407501/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-20 07:17:46  来源:igfitidea点击:

Android emulator: could not get wglGetExtensionsStringARB error

androidandroid-emulatorandroid-2.2-froyoandroid-sdk-2.3

提问by Teererai Marange

I am getting this error in the android emulator logs since I updated the SDKManager and ADT:

由于我更新了 SDKManager 和 ADT,我在 android 模拟器日志中收到此错误:

[2012-07-10 15:51:23 - Emulator] could not get wglGetExtensionsStringARB

[2012-07-10 15:51:23 - 模拟器] 无法获得 wglGetExtensionsStringARB

What does it mean? And is there anything I can do about it?

这是什么意思?我能做些什么吗?

采纳答案by Prabhakar

I faced the similar problem. In my case I had created the new virtual device and had enabled the snapshot. I just unchecked the checkbox Go to AVD Manager-> Select the device-> click Editand uncheck the Enabledcheckbox. I hope this works.

我遇到了类似的问题。就我而言,我创建了新的虚拟设备并启用了快照。我只是取消选中复选框转到AVD Manager-> Select the device-> 单击Edit并取消选中该Enabled复选框。我希望这有效。

回答by Hoang Nguyen

When you create the emulator, you need to choose properties CPU/ABI is Intel Atom (installed it in SDK manager )

创建模拟器时,需要选择属性 CPU/ABI 是 Intel Atom(安装在 SDK manager 中)

回答by sachin pareek

just change your JDK I installed the JDK of SUN not Oracle and it works for me....

只需更改您的 JDK 我安装了 SUN 的 JDK 而不是 Oracle,它对我有用....

回答by jjthebig1

For me changing the Emulated Performancesetting to "Store a snapshot for faster startup" and unchecking "Use Host GPU" fixed the problem.

对我来说,将仿真性能设置更改为“存储快照以加快启动速度”并取消选中“使用主机 GPU”解决了该问题。

回答by LinuxDisciple

I ran into this issue running Android Studio 1.4. In the Android Virtual Device (AVD) Manager, I had checked the 'Use Host GPU' box, thinking this would give me some sort of boost in the emulator's speed.
Android Studio will let you choose a device that's configured that way, and it will show you the command it used to start the virtual device: Android Studio 'Run' window output

but for some reason, it doesn't warn you that the program crashed, and it doesn't show you the stderr message that you would see had you run it from the command line yourself: Output as run on the command line

When I ran it from Android Studio, I didn't see the dialog box in the screenshot above, though it shows up just fine when you run the command from the command line, so I just sat there patiently for a few minutes while nothing happened.
As pointed out elsewhere, the drivers needed for the Use Host GPU option are not yet available. Reading through that post, it appears that this setting can be used with some Intel CPUs but not the ARM chip I chose (see CPU/ABI setting below).

My solution was to just uncheck the "Use Host GPU" box which is near the bottom of the window opened through the 'edit' option after choosing the virtual device in the Android Virtual Devices tab in the AVD Manager. You can get to the AVD manager directly in Windows at
%ANDROID_HOME%\AVD Manager.exe
where in my Windows 8 install, %ANDROID_HOME% resolved to
c:\users\myusername\AppData\Local\Android\Sdk

我在运行 Android Studio 1.4 时遇到了这个问题。在 Android 虚拟设备 (AVD) 管理器中,我选中了“使用主机 GPU”框,认为这会给我一些模拟器速度的提升。
Android Studio 会让你选择一个以这种方式配置的设备,它会向你显示它用来启动虚拟设备的命令: 但出于某种原因,它不会警告你程序崩溃,也不会显示如果您自己从命令行运行它,您会看到 stderr 消息: 当我从 Android Studio 运行它时,我没有在上面的屏幕截图中看到对话框,尽管在您运行命令时它显示得很好从命令行,所以我只是耐心地坐在那里几分钟,什么也没发生。 Android Studio“运行”窗口输出

在命令行上运行的输出


使用主机 GPU 选项所需的驱动程序尚不可用。通读那篇文章,似乎此设置可用于某些 Intel CPU,但不适用于我选择的 ARM 芯片(请参阅下面的 CPU/ABI 设置)。

我的解决方案是在 AVD 管理器的 Android 虚拟设备选项卡中选择虚拟设备后,取消选中通过“编辑”选项打开的窗口底部附近的“使用主机 GPU”框。您可以直接在 Windows 中的
%ANDROID_HOME%\AVD Manager.exe
中访问 AVD 管理器,在我的 Windows 8 安装中,%ANDROID_HOME% 解析为
c:\users\myusername\AppData\Local\Android\Sdk

I don't have it running on Linux at the moment, but I'd assume it's in a similar path there, i.e.:
${ANDROID_HOME}/

After unchecking the 'Use Host GPU' box, I opted to check the 'Snapshot' box next to it (as I understand, that stores a copy of the already-built vm so it doesn't need to get rebuilt every time, which should save some startup time for future instances). Here are the full settings I used:
Edit Android Virtual Device (AVD) window screenshot

我目前没有在 Linux 上运行它,但我认为它在那里的路径类似,即:
${ANDROID_HOME}/

在取消选中“使用主机 GPU”框后,我选择选中“快照”旁边的框(据我所知,它存储了已经构建的虚拟机的副本,因此不需要每次都重新构建,这应该为将来的实例节省一些启动时间)。以下是我使用的完整设置:
编辑 Android 虚拟设备 (AVD) 窗口截图

回答by Mithilesh

First of all, use INTEL x86...this as CPU/ABI. Secondly, uncheck Snapshot if it is checked. Keep the Target upto Android 4.2.2

首先,使用INTEL x86...作为CPU/ABI。其次,如果选中,则取消选中快照。将目标保持在 Android 4.2.2

回答by RAJESH KUMAR ARUMUGAM

i had a same issue because of my Nvidea Graphics cardDriver Problem.

由于我的Nvidea 显卡驱动程序问题,我遇到了同样的问题。

If your System has Dedicated Graphics card then Check for the latest Driverand Install it.

如果您的系统有专用显卡,请检查最新的驱动程序并安装它。

Other wise simply Choose Emulated Performance as Softwarein Emulator Configurations enter image description here

否则,只需 在仿真器配置中 选择仿真性能作为软件即可在此处输入图片说明

After Updating the driver the issue is resolved :)

更新驱动后问题解决了:)