避免多次绘制对象集(华电国际/ MDPI / LDPI) [英] Avoid Multiple Drawable Sets (hdpi/mdpi/ldpi)

查看:154
本文介绍了避免多次绘制对象集(华电国际/ MDPI / LDPI)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有一种方法,以避免多套单位分辨率可绘制的?我有近50幅图像(简单的图标居多,没有使用任何需要9个补丁),似乎是一个大量的冗余工作,调整所有50在Photoshop中,也考虑到返工,如果我不得不改变一些图标,未来

Is there a way to avoid having multiple sets of drawables per resolution? I have close to 50 images (simple icons mostly, not using anything needing 9-patch), seems like a lot of redundant work to resize all 50 in Photoshop, also considering the rework if I have to change some of the icons in the future.

我理解需要适应多种密度,但有什么办法避免它可以说只是通过提供高品质的图像,然后实施规模为DP / DIP?

I understand the need for adjusting to multiple densities, but is there any way to avoid it lets say just by providing a high quality image and then enforcing the size as DP/DIP?

另外,我看到我的Andr​​oid项目除了拥有只是一个绘制对象文件夹,* HDPI / MDPI / LDPI,有什么意义,如果我只是我的所有图像资源放置到该文件夹​​,而不是特定的分辨率? (假设我确定我的照片调整大小的设备)

Also I see that my Android project has just a 'Drawable' folder in addition to *hdpi/mdpi/ldpi, what are the implications if I just place all my image resources to that folder instead of resolution specific? (assuming that I'm ok with my images being resized by the device)

推荐答案

如果你不关心所有的具有不同密度的潜在问题,比继续前进,把你所有的可绘制成可绘制文件夹。他们将正确的回升。但是你会发现,最好是比差看,从长远来看应用更大的应用程序的大小。

If you don't care about all the potential issues with different densities, than go ahead and put all your drawables into drawables folder. They will be picked up correctly. But you'll find that it's better to have larger application size than worse looking app in the long run.

此外,它通常是安全的把9修补程序,以可绘,因为他们通常不包含密度具体数据(如复杂的图像)。

Also, its usually safe to put 9-patches to 'drawables' as they usually do not contains density specific data (like complex images).

这篇关于避免多次绘制对象集(华电国际/ MDPI / LDPI)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆