确定图像大小为多个机器人屏幕尺寸/密度 [英] Determining image sizes for multiple android screen sizes/densities

查看:115
本文介绍了确定图像大小为多个机器人屏幕尺寸/密度的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在检讨支持多画面文档在Android,我只是需要一些额外的澄清...

I've been reviewing the Supporting Multiple Screens documentation on the Android and I just need some additional clarification...

这是我的理解,设计三个独特的接口(LDPI,MDPI和HDPI)将着手以最小的缩放/失真,支持所有潜在的android屏幕的最佳途径。

It's my understanding that designing three unique interfaces (ldpi, mdpi, and hdpi) would be the best way to go about supporting all the potential android screens with minimal scaling/distortion.

是的,我知道有张贴类似的问题,但是...如果我创建一个图像为基准MDPI(比方说我的形象是300x210,只是举例)如何我确定什么大小,我需要重新创建形象LDPI&安培;华电国际? <一href="http://stackoverflow.com/questions/1922697/not-understanding-how-to-use-different-density-images-for-1-6">This帖子以及谷歌搜索使我相信,LDPI是MDPI图像的仅有75%,而华电国际是MDPI图像的150%。这是准确的?

Yes, I know there are similar questions posted, however... If I create an image for the benchmark mdpi (let's say my image is 300x210, just for example) how to I determine what size I will need to recreate that image at ldpi & hdpi? This post as well as a google search leads me to believe that ldpi is just 75% of the mdpi image, and the hdpi is 150% of the mdpi image. Is this accurate?

推荐答案

-ldpi 是〜120DPI, -mdpi 是〜160dpi, -hdpi 是〜240dpi。

-ldpi is ~120dpi, -mdpi is ~160dpi, -hdpi is ~240dpi.

所以,一个320px的宽图像2 -mdpi 。如果你想有一个2图像 -ldpi ,你希望它是240px(原件= 75%)。如果你想要一个2画上 -hdpi ,你需要480px(原件= 150%)。

So, a 320px wide image is 2" in -mdpi. If you want a 2" image on -ldpi, you want it to be 240px (=75% of original). If you want a 2" picture on -hdpi, you need 480px (=150% of original).

因此​​,你的分析是准确的。

Hence, your analysis is accurate.

这篇关于确定图像大小为多个机器人屏幕尺寸/密度的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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