Android Studio - Error in launch emulator - Vulkan-1.dll

Viewed 6845

when I launch the emulator in Android Studio, the following two errors occur in the event log:

Emulator: handleCpuAcceleration: feature check for hvf
Emulator: cannot add library vulkan-1.dll: failed

Someone knows how to solve them? Thank you,

Marco

2 Answers

I met this situation when I upgrade android emulator to 30.7.5

You need to create

"advancedFeatures.ini"

inside android folder

C:\Users\YourUser.android\advancedFeatures.ini

put this text inside it

# Here's how to disable Vulkan apps to talk to the emulator.

# Add the following lines to ~/.android/advancedFeatures.ini (create this file if it doesn't exist already):

Vulkan = off
GLDirectMem = on

I think you don't have the JDK installed.

Check it out with this command (for example, on the command line):

flutter doctor

If there is an exclamation mark or a red cross next to the "Android toolchain" line, then you do not have the JDK installed.

The solution to this problem is very simple:

  1. Download JDK from this link;
  2. Extract it and rename the internal folder “jdk8u202-b08” to “openjdk” and copy it under HDD or SSD (so its path will be: C:\openjdk);
  3. Set Some Environment variables (search on google if you don't know). Name: "JAVA_HOME", path "C:\openjdk";
  4. To restart a computer.

This should help. Good luck!

Related