Pixel移动开发像素知识

版权声明:文章资料来源于网络,都是由作者自己总结下来以供参考学习~如涉及版权问题请联系作者! https://blog.csdn.net/C_hydar/article/details/84551496
  • px: CSS pixels 逻辑像素,浏览器使用的抽象单位
  • dp, pt:device independent pixels 设备无关像素
  • dpr:devicePixelRatio 设备像素缩放比

计算公式:1px = [(dpr)^2] *dp

  • DPI:打印机每英寸可以喷的墨汁点(印刷行业)
  • PPI:屏幕每英寸的像素数量,即单位英寸内的像素密度

PPI越高,像素数越高,图像越清晰;但可视度越低(小),系统默认设置缩放比越大

Retina屏(高清屏):dpr都是大于等于2 

猜你喜欢

转载自blog.csdn.net/C_hydar/article/details/84551496