I have been repeatedly trying to get an Android Virtual Device working with Hardware Acceleration on my laptop with a GTX 1650 Ti. The Android Virtual Device works with Swiftshaeder (running with -gpu swiftshader_indirect) with huge lag and running very slowly, but whenever I run it with the gpu, it gives me an error that OpenGLES failed to inialize. My Graphics Card should support OpenGLES, but I can not get it working.
The Error Message:
init: Could not find wglGetExtensionsString! arbFound 0 listarbNull/empty 1 0 extFound 0 extNull/empty 1 0 remote 0
OpenGL Core Profile not supported.
getGLES2ExtensionString: Could not find GLES 2.x config!
Failed to obtain GLES 2.x extensions string!
Could not initialize emulated framebuffer
Failed to open /qemu.conf, err: 2
HAX is working and emulator runs in fast virt mode.
emulator: ERROR: OpenGLES emulation failed to initialize. Please consider the following troubleshooting steps:
1. Make sure your GPU drivers are up to date.
2. Erase and re-download the emulator ($ANDROID_SDK_ROOT/emulator).
3. Try software rendering: Go to Extended Controls > Settings > Advanced tab and change "OpenGL ES renderer (requires restart)" to "Swiftshader".
Or, run emulator from command line with "-gpu swiftshader_indirect". 4. Please file an issue to https://issuetracker.google.com/issues?q=componentid:192727 and provide your complete CPU/GPU info plus OS and display setup.
crashhandler_die: fatal: OpenGLES emulation failed to initialize. Please consider the following troubleshooting steps:
1. Make sure your GPU drivers are up to date.
2. Erase and re-download the emulator ($ANDROID_SDK_ROOT/emulator).
3. Try software rendering: Go to Extended Controls > Settings > Advanced tab and change "OpenGL ES renderer (requires restart)" to "Swiftshader".
Or, run emulator from command line with "-gpu swiftshader_indirect". 4. Please file an issue to https://issuetracker.google.com/issues?q=componentid:192727 and provide your complete CPU/GPU info plus OS and display setup.
Note: I know similar questions have been asked, but every solution is saying use Software Encoding. That is not what I am looking for, as Hardware Encoding should work. Software Encoding has terrible performance, and with a dedicated Graphics Card, there should be no issue for hardware encoding, especially with one as modern as the GTX 1650 Ti.
Related
I get the following error whenever I try to run the emulator in android studio.
I am using the latest version of android studio.
WARNING | unexpected system image feature string, emulator might not function correctly, please try updating the emulator. init: Could not find wglGetExtensionsString! arbFound 0 listarbNull/empty 1 0 extFound 0 extNull/empty 1 0 remote 0 OpenGL Core Profile not supported. ERROR | Could not find GLES 2.x config! ERROR | Failed to obtain GLES 2.x extensions string! ERROR | Could not initialize emulated framebuffer ERROR | Failed to open /qemu.conf, err: 2 INFO | added library vulkan-1.dll HAX is working and emulator runs in fast virt mode. INFO | Started GRPC server at 127.0.0.1:8554, security: Local INFO | Advertising in: C:\Users\Ayush Singh\AppData\Local\Temp\avd\running\pid_14224.ini ERROR | OpenGLES emulation failed to initialize. Please consider the following troubleshooting steps: 1. Make sure your GPU drivers are up to date. 2. Erase and re-download the emulator ($ANDROID_SDK_ROOT/emulator). 3. Try software rendering: Go to Extended Controls > Settings > Advanced tab and change "OpenGL ES renderer (requires restart)" to "Swiftshader". Or, run emulator from command line with "-gpu swiftshader_indirect". 4. Please file an issue to https://issuetracker.google.com/issues?q=componentid:192727 and provide your complete CPU/GPU info plus OS and display setup. ERROR | crashhandler_die: fatal: OpenGLES emulation failed to initialize. Please consider the following troubleshooting steps: 1. Make sure your GPU drivers are up to date. 2. Erase and re-download the emulator ($ANDROID_SDK_ROOT/emulator). 3. Try software rendering: Go to Extended Controls > Settings > Advanced tab and change "OpenGL ES renderer (requires restart)" to "Swiftshader". Or, run emulator from command line with "-gpu swiftshader_indirect". 4. Please file an issue to https://issuetracker.google.com/issues?q=componentid:192727 and provide your complete CPU/GPU info plus OS and display setup. INFO | Android emulator version 31.2.10.0 (build_id 8420304) (CL:N/A)
I recently changed my computer and took the opportunity to move from Mageia to Fedora. But I can't do any Android development anymore because, as stated in the title, starting any AVD makes the whole system to freeze (screen, mouse and keybord) if the AVD can't connect to adb daemon. The only thing I can do is hard shutdown.
The problem here is adb daemon is always started when I try to launch an AVD as the service is enabled by default, so that shouldn't happen.
What I've been able to collect so far is a few logs in a file by lauching the emulator from command-line. All it says before freezing is:
emulator: INFO: GrpcServices.cpp:301: Started GRPC server at 127.0.0.1:8554, security: Local
emulator: ERROR: AdbHostServer.cpp:102: Unable to connect to adb daemon on port: 5037
But, if I manually restart the adb service just before lauching the AVD, I don't experience the freeze. Instead, I get the following errors before the AVD crashes:
cannot add library .../android-sdk-linux/emulator/qemu/linux-x86_64/lib64/vulkan/libvulkan.so: failed
added library .../android-sdk-linux/emulator/lib64/vulkan/libvulkan.so
cannot add library .../android-sdk-linux/emulator/lib64/vulkan/libvulkan.so.1: full
My best guess here is there's something bad going on with the graphic card. Something I am seemingly the only one to exprerience as I couldn't find any relevant result on internet. I must mention here that I've already tried to run several AVDs in multiple API versions, both software and hardware rendered graphics and I always get the same result.
My system configuration is
AMD Ryzen 9
Nvidia GeForce RTX 2070 using the Nouveau drivers
kernel 5.11.
If anyone ever stumbles upon this question facing the same issue than me, that was solved by getting rid of the Nouveau drivers and using Nvidia's proprietary drivers. A handful of other disturbing bugs on my computer were solved by doing just that.
I really don't understand why some Linux distribution still strongly advise to use the Nouveau drivers over Nvidia'as when they have a such a really poor support of the GPUs...
Recently I updated my Android SDK and emulator. After that I'm not able to run the 'Hello world' program. While loading the emulator I am getting warnings and error like this.
OpenGL backend 'angle' without OpenGL ES 1.x library detected. Using GLESv2 only.
emulator: WARNING: encryption is off
TextureDraw: Could not create/link program: Failed to create D3D shaders.
Hax is enabled
Hax ram_size 0x40000000
HAX is working and emulator runs in fast virt mode.
audio: Failed to create voice `goldfish_audio'
qemu-system-i386.exe: warning: opening audio output failed
audio: Failed to create voice `goldfish_audio_in'
qemu-system-i386.exe: warning: opening audio input failed
audio: Failed to create voice `dac'
audio: Failed to create voice `adc'
draw: no program
draw: no program
.
.
.
ANGLE: egl::`anonymous-namespace'::CreateDisplayFromAttribs: make D3D display
ANGLE: D3D9: rx::Renderer9::generateConfigs
I tried lots of uninstall and update, downgrade of sdk, etc., but nothing is working and I'm not able to get the exact problem.
I have installed 2 SDK platforms:
Android 7.0
Android 4.2
My SDK tools are:
I had the same problem, the solution is to change "the amount of physical RAM" when you create a virtual device android... make 512 MB because your computer can't read a space (1.5 GB ) in RAM.
How to create a virtual device correctly to solve this problem?
First, open Android Studio, then click Tools > Android > AVD Manager.
Second, click Create virtual Device after choose a device (for example : nexus 4) and click Next and Select a system Image, then click Next.
Third, click Show Advanced Settings; scroll until you see "RAM" and change the value to a lower value, for example 512MB.
Whenever I attempt to run my android program, android studio throws this error: Unable to obtain result of ADB version.
As a result, initializing ADB fails, and none of my created Virtual Devices are detected.
What helped me get around this problem was the post by prashant2400
(e.g. Go control panel -> System->advance System settings-> Advanced tab->performance->settings->Advance->Virtual memory change). Android Studio: Unable to obtain result of 'adb version'
I had to meddle with this Virtual Memory paging file size, and ADB works after restarting the PC. However, the same problem happens again a day later when i resume coding... and I keep meddling with this page file size and restarting the workstation. How can I fix this problem permanently?
Emulator I am trying to run:
Nexus 5 API 26 (Playstore enabled / API 26 / Android8 / x86 / 1GB)
Android Studio:
2.3.3
PC Specs:
Intel(R) Core(TM) i5-3470 CPU # 3.20GHz
8GB RAM
64 bit operating system, x64-based processor
Any help will be greatly appreciated. I am thinking of buying more RAM (e.g. 8GB to 16GB) if it may help, but I think it's an issue with the latest build of Android Studio 2.3.3
Managed to resolve this problem on my own.
It turns out that it was a timeout issue whereby, the default 5s to wait to get the ADB version was too short. I simply had to increase the connection timeout settings to wait longer as per below.
[1] Go to: File --> Settings --> Tools (Expand Left Panel) --> Tasks
[2] Set the Connection timeout longer (default was 5secs). I set to 10secs.
Regards
When starting my emulator from Eclipse or from the command line (Win7x32), I see no emulator window popup and the process hangs.
From the command-line, with -verbose, I see logs until the two lines:
emulator: using 'winaudio' audio input backend
emulator: using 'winaudio' audio output backend
... and then nothing.
When I start from the command line with -verbose and -noaudio options, the emulator starts up.
I can modify the Eclipse avd startup settings to have -noaudio, but I'd like to find a way to get audio working.
The commands emulator -help-audio-in and emulator -help-audio-out show winaudio and winaudio & sdl, available, respectively.
Does anyone have pointers as to how to get audio working with my emulator?
Edit
After this happened again, I discovered it was a faulty audio driver - basically a Windows audio driver issue. Reinstalling the driver (and removing any usb-attached audio hardware like webcams, etc.) allowed the emulator to start w/o hanging # winaudio statements.
As above, after this happened again, I discovered it was a faulty audio driver - basically a Windows audio driver issue.
Reinstalling the driver (and removing any usb-attached audio hardware like webcams, etc.) allowed the emulator to start w/o hanging # winaudio statements.