新建项目,Android模拟器报错:Could not initialize OpenglES emulation, use ‘-gpu off’ to disable it.

来源:互联网 发布:淘宝哪家supreme复刻 编辑:程序博客网 时间:2024/05/16 05:19

小白博主刚安装好Android Studio,新建了第一个项目,没做任何更改,依照推荐选择了模拟器,直接运行,模拟器就报错:

emulator: WARNING: Classic qemu does not support SMP. The hw.cpu.ncore option from your config file is ignored. 

init: Could not find wglGetExtensionsStringARB! 
getGLES1ExtensionString: Could not find GLES 1.x config! 
Failed to obtain GLES 1.x extensions string! 
emulator: device fd:1112 
HAXM is working and emulator runs in fast virt mode 
emulator: ERROR: Could not initialize OpenglES emulation, use ‘-gpu off’ to disable it. 

Could not initialize emulated framebuffer 

网上百度,查到了相关解决方案,这里记录一下:

既选择分辨率最小的模拟器,取消使用本机的GPU即可.(如下图所示)

1.点击run,进去设备选择器Device Chooser,在启动模拟器菜单处新增模拟器;


2.新建一个模拟器,选择最小分辨率,这里选择的是2.7寸的QVGA;

3.关键一步:取消Use Host GPU处的默认勾选即可.


小白们,重新运行一遍,是不是可以启动模拟器了,虽然丑爆了,但是毕竟功能上运行了.


0 0