本文介绍了Android Studio Emulator:无法添加库 vulkan-1.dll:失败的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我在 Windows 10 Pro 64 位中从 Android Studio 运行模拟器时,它显示以下错误:

When I run the emulator from Android Studio in Windows 10 Pro 64-bit, then it shows the below error:

13-01-2021
10:42 AM    Emulator: handleCpuAcceleration: feature check for hvf

10:42 AM    Emulator: cannot add library vulkan-1.dll: failed

10:42 AM    Emulator: cannot add library vulkan-1.dll: failed

10:42 AM    Emulator: Process finished with exit code -1073741819 (0xC0000005)

并且模拟器没有打开.我已经卸载了当前版本(4.1.1)并安装了Android Studio 4.0.1,但问题没有解决.现在我使用的是最新版本的 Android Studio,即 4.1.1.

And the emulator is not opening. I've uninstalled the current version (4.1.1) and installed 4.0.1 of Android Studio, but problem is not solved. Now I'm in the latest version of Android Studio i.e., 4.1.1.

这是 flutter doctor 的输出:

推荐答案

如果您使用的是 Android 10 或 11,则无法更改 Emulated性能(图形)

If you’re using Android 10 or 11, then you can’t change the EmulatedPerformance (Graphics)

为此,编辑 AVD 的 config.ini 文件.在 Windows 下是位于 C:/Users//.android/avd//config.ini(在我的例子中是 Nexus_5X_API_29.avd).

So for that, Edit the config.ini file of the AVD. Under Windows it’slocated under C:/Users/<user_name>/.android/avd//config.ini(in my case is Nexus_5X_API_29.avd).

在文本编辑器中更改行

hw.gpu.mode=auto

hw.gpu.mode=off

(即使在 Android 虚拟设备中打开此设置也会保留安卓工作室经理.它只是在那里不可编辑.

(This setting remains even if opened in the Android Virtual DeviceManager of Android Studio. It’s just not editable there.

我也试过这个,我在另一个 AVD 中找到的:

I also tried this, which I found in another AVD:

hw.gpu.enabled=yes
hw.gpu.mode=software

但这会被 Android 虚拟设备更改为no"/off"经理.到目前为止,我没有再看下去.hw.gpu.mode=off 为我).

But this is then changed to "no" / "off" by the Android Virtual DeviceManager. I didn’t look any further so far. hw.gpu.mode=off worked forme).

这篇关于Android Studio Emulator:无法添加库 vulkan-1.dll:失败的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-05 11:13