Issues with AVD Manager (v21.0.1 and 21.1rc2): xxhdpi not supported

♀尐吖头ヾ 提交于 2019-12-11 18:53:50

问题


I'm having trouble creating a custom AVD for XPeria ZL phone using the Device Definitions tab.

I noticed the AVD manager is unable to parse devices.xml file if one of them uses the xxhdpi density.

As a side note, the emulator is no longer able to scale display to real size.

Has anyone faced these issue and was able to fix it? I really need to emulate that device for a POC we are working on.


回答1:


For the first issue, about the error in parsing after adding xxhdpi devices, try updating the Android SDK Tools to 21.1, this really should solve the problem.

For your second issue, making the emulator work with xxhdpi resources, this can be accomplished with a few additional adb-commands after the emulator has started. Taken from an installation troubleshooting page at developer.sonymobile.com (http://developer.sonymobile.com/knowledge-base/sdks/sony-add-on-sdk/install-the-sony-add-on-sdk/), the following statement is available:

In the Android SDK Tools version 21.1, the xxhdpi screen resolution for the emulator display is not yet supported. However, you could do a manual override of the LCD properties of the emulator. This will ensure that the correct resources are being dispatched for the Xperia™ Z emulator. To do so, please execute the following in your command line after the Xperia™ Z emulator has completed the boot sequence:

adb shell setprop qemu.sf.lcd_density 480

adb shell stop

adb shell start

The emulator will then restart. After it has rebooted the emulator should use the correct screen density and UI scaling. We recommend you to execute these commends using a batch file or a shell script if you are using these settings often.



来源:https://stackoverflow.com/questions/14365056/issues-with-avd-manager-v21-0-1-and-21-1rc2-xxhdpi-not-supported

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!