Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to fix " Emulator: Warning: QXcbIntegration: Cannot create platform OpenGL context, neither GLX nor EGL are enabled ((null):0, (null))"

I'am working on xfce "Xubuntu", I have updated my android studio, and every time I execute any project with emulator I get this two errors:

Emulator: Warning: QXcbIntegration: Cannot create platform OpenGL context, neither GLX nor EGL are enabled ((null):0, (null))

Emulator: emulator: ERROR: VkCommonOperations.cpp:496: Failed to create Vulkan instance.

like image 423
computer tricks Avatar asked Oct 02 '19 00:10

computer tricks


1 Answers

I got the first error.

Emulator: Warning: QXcbIntegration: Cannot create platform OpenGL context, neither GLX >nor EGL are enabled ((null):0, (null))

The error remained but the emulator is running properly. I changed the following two settings with the next two values in the config.ini file from the avd folder.

hw.gpu.enabled = no

hw.gpu.mode = swiftshader_indirect

The avd folder should be located similarly: /home/[your_linux_username]/.android/avd/Nexus_One_API_22.avd/

Nexus_One_API_22 is the name of the avd.

like image 159
Adrian Avatar answered Nov 03 '22 19:11

Adrian