PPI和DPI原來是一回事咐柜。

DPI如何換算PPI,這個問題讓我糾結(jié)了好幾天了通孽,以前做UI一直用72PPI的序宦,再換了蘋果電腦R屏以后,突然發(fā)現(xiàn)PS的預置模版分辨率不是72PPI了背苦!


9DB0152D-141C-48BC-9A2C-FE2E0C0E82AD.png

workflow-ios-sizes-in-points.png

一時之間搞不明白了互捌。于是開始各種惡補,幾天下來行剂,被各種顯示器的密度秕噪,各種換算方式一下子就整暈了。帶著疑問去跟人討論厚宰,沒人說的清楚腌巾,就說按72做沒錯 至于為啥也說不清楚,甚至有人直接拋個白眼給我固阁,讓我先把PS弄熟練了再來問問題...秉著知其然亦需知其所以然的念頭 我執(zhí)著的找啊找壤躲,找到了下面引用的文章,好了”溉迹現(xiàn)在終于不糾結(jié)了碉克,做UI的話PPI和DPI原來是一回事。用72PPI也好并齐,用更高的分辨率也好漏麦,其實都一樣客税。機器不太慢的話,我還是建議用大于150PPI的分辨率做撕贞,因為有時候更耻,項目上線后很久,甲方會找到你捏膨,說我要印宣傳冊或打印啥的秧均,讓你提供圖標和界面截圖給他,那時難道你重新畫嗎号涯?不過這樣也會導致文件過大目胡,請慎重對待。

Pixels per inch is just a tag

Image pixel density for web and app design is often seen as a confusing topic. I’m not sure why this is — when stripped back to the bare essentials, the reality is far less complex than you might think.

Bitmap images are two dimensional grids of pixels, with a width and a height. They often also contain meta data, which may include pixel density. Pixel density is often described as pixels pixels per inch (PPI) or dots per inch (DPI).
The two names, PPI and DPI, mean essentially the same thing — the number of pixels contained within a vertical or horizontal inch. 300PPI means that there’s 300 pixels contained within each one inch row. A one inch by one inch square in a 300PPI image contains 90,000 pixels, because it is a 300 × 300 pixel square. Most displays have a fixed resolution grid, so their pixel density can’t change. A Retina iPad Air display is 264PPI, because there’s 264 elements per inch in the display that can each only ever represent one pixel.
The pixel density stored in image files is different. It’s just meta data that’s saved alongside the image data. It can be changed at any time without affecting the image data at all. It should be considered a relic from the printing industry, because in general, web and app development display all images so that one pixel in the image equals one on screen, ignoring the embedded pixel density information.
Pixels per inch (PPI) vs dots per inch (DPI) vs lines per inch (LPI)

Purists will probably use PPI to describe on screen pixel density and DPI to describe print density, but I think this is a battle that’s drawing to a close. Apple, Microsoft and Google all seem to prefer using DPI in their literature. Curiously, Apple’s iPhone 4S and iPad specs describe their displays using PPI.
For screen design, PPI and DPI are interchangeable.
For print design, DPI only exists to indicate the final size the image might be printed. It’s sometimes used to generate thumbnail images to help performance in layout apps. It can also be used to indicate optimal print size — InDesign, Xpress and others treat 100% image size as meaning “the physical size you’ve used the image in your layout matches the pixel density tag contained in the image”. That’s a great feature. If the images are set up correctly, you know how large you can make images without risking pixelation. It’s still just a tag associated with the image. A handy tag, but a tag nonetheless.
Lines per inch (LPI) is a printing-specific term that describes how close together the halftone lines are. Not all printing is 300DPI — coarser line screens, like those used for newspaper and large format printing (billboards etc), mean lower pixel density images can be used.
The history of 72PPI

The original Mac, the Macintosh 128K, featured a 512 × 342 pixel, 72PPI black and white display. Because of this, OS X has considered 72PPI to be baseline where one image pixel equals one display pixel, even though most Mac displays are far higher density than 72PPI.
OS X’s Preview can view one image pixel as one display pixel, or it can scale using the PPI tag within the file.

It’s just metadata

If you’d like to set up your Retina iPad Photoshop documents at 264PPI, be my guest. You could also set them up at 72PPI. It really doesn’t matter, as long as the final result is images with the correct pixel dimensions.
However, if you plan to use Photoshop and different pixel densities for each document, dragging layers and copying layer styles between documents scales layer styles — dragging a layer from a 326PPI Retina iPhone document to a 264PPI Retina iPad document will mean all layer styles get scaled by 20% (then rounded to the nearest integer).
And that’s probably not what you want. Also, OS X’s Preview will display 72PPI images at the exact size, no matter how you have it set up.
It is for these reasons I assign 72PPI to all my design documents, and I recommend you do the same. To change the pixel density of your Photoshop document without resizing the image data, open the Image Size dialogue, uncheck Resize Image and type in the desired pixel density.

最后編輯于
?著作權歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
  • 序言:七十年代末链快,一起剝皮案震驚了整個濱河市誉己,隨后出現(xiàn)的幾起案子,更是在濱河造成了極大的恐慌域蜗,老刑警劉巖巨双,帶你破解...
    沈念sama閱讀 210,978評論 6 490
  • 序言:濱河連續(xù)發(fā)生了三起死亡事件,死亡現(xiàn)場離奇詭異霉祸,居然都是意外死亡筑累,警方通過查閱死者的電腦和手機,發(fā)現(xiàn)死者居然都...
    沈念sama閱讀 89,954評論 2 384
  • 文/潘曉璐 我一進店門脉执,熙熙樓的掌柜王于貴愁眉苦臉地迎上來疼阔,“玉大人,你說我怎么就攤上這事半夷∑爬龋” “怎么了?”我有些...
    開封第一講書人閱讀 156,623評論 0 345
  • 文/不壞的土叔 我叫張陵巫橄,是天一觀的道長淘邻。 經(jīng)常有香客問我,道長湘换,這世上最難降的妖魔是什么宾舅? 我笑而不...
    開封第一講書人閱讀 56,324評論 1 282
  • 正文 為了忘掉前任,我火速辦了婚禮彩倚,結(jié)果婚禮上筹我,老公的妹妹穿的比我還像新娘。我一直安慰自己帆离,他們只是感情好蔬蕊,可當我...
    茶點故事閱讀 65,390評論 5 384
  • 文/花漫 我一把揭開白布。 她就那樣靜靜地躺著哥谷,像睡著了一般岸夯。 火紅的嫁衣襯著肌膚如雪麻献。 梳的紋絲不亂的頭發(fā)上,一...
    開封第一講書人閱讀 49,741評論 1 289
  • 那天猜扮,我揣著相機與錄音勉吻,去河邊找鬼。 笑死旅赢,一個胖子當著我的面吹牛齿桃,可吹牛的內(nèi)容都是我干的。 我是一名探鬼主播煮盼,決...
    沈念sama閱讀 38,892評論 3 405
  • 文/蒼蘭香墨 我猛地睜開眼源譬,長吁一口氣:“原來是場噩夢啊……” “哼!你這毒婦竟也來了孕似?” 一聲冷哼從身側(cè)響起,我...
    開封第一講書人閱讀 37,655評論 0 266
  • 序言:老撾萬榮一對情侶失蹤刮刑,失蹤者是張志新(化名)和其女友劉穎喉祭,沒想到半個月后,有當?shù)厝嗽跇淞掷锇l(fā)現(xiàn)了一具尸體雷绢,經(jīng)...
    沈念sama閱讀 44,104評論 1 303
  • 正文 獨居荒郊野嶺守林人離奇死亡泛烙,尸身上長有42處帶血的膿包…… 初始之章·張勛 以下內(nèi)容為張勛視角 年9月15日...
    茶點故事閱讀 36,451評論 2 325
  • 正文 我和宋清朗相戀三年,在試婚紗的時候發(fā)現(xiàn)自己被綠了翘紊。 大學時的朋友給我發(fā)了我未婚夫和他白月光在一起吃飯的照片蔽氨。...
    茶點故事閱讀 38,569評論 1 340
  • 序言:一個原本活蹦亂跳的男人離奇死亡,死狀恐怖帆疟,靈堂內(nèi)的尸體忽然破棺而出鹉究,到底是詐尸還是另有隱情,我是刑警寧澤踪宠,帶...
    沈念sama閱讀 34,254評論 4 328
  • 正文 年R本政府宣布自赔,位于F島的核電站,受9級特大地震影響柳琢,放射性物質(zhì)發(fā)生泄漏绍妨。R本人自食惡果不足惜,卻給世界環(huán)境...
    茶點故事閱讀 39,834評論 3 312
  • 文/蒙蒙 一柬脸、第九天 我趴在偏房一處隱蔽的房頂上張望他去。 院中可真熱鬧,春花似錦倒堕、人聲如沸灾测。這莊子的主人今日做“春日...
    開封第一講書人閱讀 30,725評論 0 21
  • 文/蒼蘭香墨 我抬頭看了看天上的太陽行施。三九已至允坚,卻和暖如春,著一層夾襖步出監(jiān)牢的瞬間蛾号,已是汗流浹背稠项。 一陣腳步聲響...
    開封第一講書人閱讀 31,950評論 1 264
  • 我被黑心中介騙來泰國打工, 沒想到剛下飛機就差點兒被人妖公主榨干…… 1. 我叫王不留鲜结,地道東北人展运。 一個月前我還...
    沈念sama閱讀 46,260評論 2 360
  • 正文 我出身青樓,卻偏偏與公主長得像精刷,于是被迫代替她去往敵國和親拗胜。 傳聞我的和親對象是個殘疾皇子,可洞房花燭夜當晚...
    茶點故事閱讀 43,446評論 2 348

推薦閱讀更多精彩內(nèi)容

  • 如果你在東京街頭,遇到一個眼睛微笑得像月牙一樣的女孩纫事,見到她勘畔,替我問個好,她曾經(jīng)是我深愛過的女孩丽惶,她叫赤名莉香炫七。”...
    溫佛佳閱讀 1,646評論 19 52
  • 疏影似花非花墜钾唬,前塵如煙沒于界 笑怨嗔癡兩心醉万哪,凝眸挽指是為誰 輕舞水袖暗香動,紅箋寫意情綿...
    粉紅小兜閱讀 150評論 0 2
  • 感賞今天又是美好而充實的一天抡秆!下午放學后沒有去運動也不急著回家煮晚餐奕巍,在店里陪大妹聊了一會兒店里的情況。真的很感謝...
    旦子閱讀 197評論 0 2
  • 句將隨興得儒士,興不與人期伍绳。 多少感懷事,一時清雅詩乍桂。 野吟何激越冲杀,春醉未推辭。 細雨社燕子睹酌,輕風堤柳絲权谁。 明知流水早...
    雪窗_武立之閱讀 349評論 0 2