PPI(Pixel Per Inch)是图像分辨率所使用的单位,意思是:在图像中每英寸所表达的像素数目。从输出设备(如打印机)的角度来说,图像的分辨率越高,所打印出来的图像也就越细致与精密。 DPI(Dot Per Inch)是打印分辨率使用的单位,意思是:每英寸所表达的打印点数。
the number of pixels in one inch is called dpi (dots per inch). Let’s find out what is dpi equal to in this case. Remembering the basics: c2 = a2 + b2, where c is a number of pixels on the diagonal. c is a number of pixels that fits into 3.7 inches. a and b are the sides of the screen.
c = 3,7 * dpi
(3,7 * dpi)2 = 4802 + 8002
dpi2 = 870400 / 13,69 = 63579
dpi = 252. So into one inch of the screen fits the number of pixels which is equal to 252.
Absolute values:
The following units of measure are used (MU):
dp or dip - Density-independent Pixels. Abstract unit of measure, that allows applications to look alike on different screens and resolutions.
sp - Scale-independent Pixels. The same as dp, but is used for font sizes in View-elements.
pt - 1/72 of an inch, is defined by the physical screen size. This MU if from typoghraphy.
px - pixel, not recommended to use, as the application will look different on different screens.
mm - a millimeter, defined by the physical size of the screen.
in - an inch, defined by the physical size of the screen.