Wednesday, August 29, 2012

Apple MacBook Pro Retina: DPI Adaptation to the Rescue

You'll find numerous reviews about the 2012 Apple MacBook Pro with Retina Display. But one feature that nobody seems to be mentioning is the DPI Matching they've built into Mac OS X to accommodate the display.

Here's the big win for everybody: you can drag a window from one display to another, and the window appears to be the same size. It looks better on the Retina display, but it doesn't get smaller or larger.

Remembering the Uberbox

While a Computer Science student in 1998, I proposed the problems you'd have with a super-high-resolution display, for example, 1,000,000 by 1,000,000, i.e., a million-megapixel display. (Except that way back then, we spoke in kilopixels, and saved our old emails to floppy disk at 14400 bps.) 

The key problem was that so many things are scaled to the popular Dots-Per-Inch (DPI) levels of current displays. One prospective employer mentioned that people shouldn't expect their 640x480 monitors to work well for modern web pages. "If there's somebody not using 800x600, they just need to upgrade," he said in 1995 or so.

Needless to say, if Paul actually had offered me a job, I would have turned him down flat! How could anyone be so cruel. The underlying logic was that the web pages should be made to fit a certain specific pixel count. But every good computer scientist knows that the quality of the rendering should be the only factor dependent on the pixel size: the apparent size of the text or graphics should always be constant.[1]

That is, if you want a 4-inch-tall object on the screen, then it should be 4 inches tall regardless of the display resolution -- dots per inch. A high dots-per-inch should give a better quality of image, because the resolution is greater, and finer details can be rendered. Likewise, 36-point Capital-M character should be about half an inch tall.

Apple has suffered the same problem, until now. In the past, when you bought the high-resolution display on a MacBook Pro, then your 36-point text would be smaller than if you had bought the conventional display. 

So the old rule was that higher resolution meant smaller text. But with Apple's new 220 dpi display on the MacBook Pro, that would be unmanageable. For example, that "36-point" 1/2-inch-tall text on a legacy 72 dpi display would shrink to only 1/6" of an inch tall on a 220-dpi display. 

So Apple made things better: sometime recently, they added DPI-matching to Mac OS X, and it's really impressive. So now, in some cases, objects remain the same physical rendered size, regardless of the display. But the quality improves when they're displayed on the Retina display.

Photos of the Rendered Results

As an example, look at this magnified Letter A. The text is the same size. When I drag the window to the 110 dpi 27" display, the rendered quality goes down, but the rendered size stays the same. First, we have the letter A on a 110 dpi 27" Apple Display

Magnified Letter A, shown on 110 dpi 27" Apple Display.

However, when I drag the same letter A onto my Macbook Pro Retina display, the quality goes up, and the measured size on the screen stays the same.
Magnified Letter A, shown on 220 dpi 15" Macbook Pro Retina display.

It helps that both displays are current Apple products. When I drag the same magnified letter A over to an old 1280x1024 DisplayPort-connected LCD on the same computer, the rendered size gets bigger:
The same magnified Letter A, shown on a 96 dpi 1280x1024 "BenQ" LCD display.

So, why the inconsistency? My guesses:
  • Perhaps Mac OS X doesn't know the DPI for the BenQ?
  • Has Apple has only made this feature work on Apple-brand displays? 
  • Or is it because the BenQ is connected via DisplayLink, and the DisplayLink driver doesn't quite function just like every other display? 
  • Or is it some silly oversight?
Note that my method here involves using the magnification feature built into "Universal Access", I.e., Option-Cmd-8. Then I disabled antialiasing, so the jaggies were visible.