what exactly is device pixel ratio?

前端 未结 4 2012
故里飘歌
故里飘歌 2020-11-22 07:40

this is mentioned every article about mobile web, but nowhere I can found an explanation of what exactly does this attribute measure.
Can anyone please elaborate what do

4条回答
  •  清酒与你
    2020-11-22 08:01

    https://developer.mozilla.org/en/CSS/Media_queries#-moz-device-pixel-ratio

    -moz-device-pixel-ratio
    Gives the number of device pixels per CSS pixel.

    this is almost self-explaining. the number describes the ratio of how much "real" pixels (physical pixerls of the screen) are used to display one "virtual" pixel (size set in CSS).

提交回复
热议问题