Put the picture into the appropriate drawable file

Note on drawable details: The rule for the system to automatically find image resources is [the most suitable dpi drawable]-->[higher dpi drawable]-->[nodpi's drawable]-->[slightly lower than the most suitable dpi If the image resource is placed in the wrong location of the drawable, the memory consumption of loading an image will be too large. If an image is placed in a drawable folder with a lower dpi than the current device, the system will consider it This is for low-dpi devices, so the image will be enlarged, which will consume more memory; if an image is placed in a drawable folder with a higher dpi than the current device, the system will consider it to be for It is prepared for high-dpi devices, so this image will be reduced. In fact, the image reduction display has no side effects. In order to avoid such a situation, developers and UI designers should all move closer to high-dpi, but the higher the resolution of the image itself It is quite large, and basically it can't save any memory, so it is not that the closer to the high dpi, the better, not necessarily; as for the scaling ratio, it is based on the highest value of each dpi density, such as [160 ~ 240] The range is based on 240;

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=326059097&siteId=291194637