计算 iPhone 上的像素大小 [英] Calculating pixel size on an iPhone

查看:23
本文介绍了计算 iPhone 上的像素大小的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

iPhone SDK 中有没有办法计算单个像素的大小(以毫米为单位)?

Is there a way in the iPhone SDK to calculate the size (in millimeters) of a single pixel?

推荐答案

嗯,像素的大小是一个常数.当前 iPhone 或 iPod touch 的屏幕尺寸为 2" x 3" (50.8 mm x 76.2 mm),分辨率为 320 x 480 像素.

Well, the size of a pixel is a constant. The screen size of a current iPhone or iPod touch 2" x 3" (50.8 mm x 76.2 mm) and the resolution is 320 x 480 pixel.

50.8/320(或 76.2/480)=> 1 像素的大小为 0.15875 毫米 x 0.15875 毫米

50.8 / 320 (or 76.2 / 480) => the size of 1 pixel is 0.15875 mm x 0.15875 mm

这篇关于计算 iPhone 上的像素大小的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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