I’m rich with drug stores.

If New York City can’t have a bank on every corner, we definitely need a drug store every 300 feet.

new Duane Reade

Duane Reade will soon open a new store on the ground floor of my building. That makes at least seven drug stores within about a quarter mile of my front door. If I went out to a half mile, that number would easily triple. While this isn’t quite Greenpoint Avenue Rite Aid silly, I think we’re covered in the drug store department.

Here’s a map showing all the drug stores within a quarter mile of my apartment:

View Larger Map

And their approximate distances:

New Duane Reade
50 feet
Old Duane Reade (across 14th St)
240 feet
CVS (around the corner on First Ave)
375 feet
Walgreens (the old Elm Drug on First)
1060 feet
Duane Reade (Third Ave & 14th)
1120 feet
Rite Aid (14th btw Ave A & Ave B)
1280 feet
Duane Reade (Third Ave & 18th St)
1840 feet

It’s remarkable how Duane Reade turned this space around, it seems like about a month since they started construction and they’ve started stocking the shelves already. The Walgreen’s at Astor Square (2700 feet away) took far, far longer to open and the space was undoubtedly in better shape, the old Gristedes was a stinking, filthy wreck.

This hurt my brain

This hurt my brainFrom this Olympic Mascot Quiz. Rolling over the colors turned their background orange, producing an inadvertent Stroop Effect.

I’m Quatchi.

How to spell Hanukkah 2007

hanukkah spellings graph 2007

hanukkah spellings key 2007

Hanukkah fell very early this year, the first night was December 4th, so there wasn’t a lot of time to build up queries before the holiday started. I think that’s reflected in the lowered counts across the top of the field. While it would be nice to think there was starting to be some consensus about how to render the word in English, the dramatic falloff of the secondary Ch-spellings is most likely time-related. I’m going to keep an eye on the numbers over the next eight nights, if results increase significantly I’ll update the graph.

Here’s Google Trends graph showing results over time. Click the graph for more viewing options.

hanukkah usage trends

Previous years: 2004, 2005, 2006 (my CSV data file). 2004 numbers thanks to Jeremy Blachman

Multiple RegisterResource directives broken in Leopard

This is sort of a follow up on the old mod_rendezvous article I wrote for O’Reilly. While cleaning up my virtual hosts I discovered a bug in 10.5’s handling of multiple RegisterResource directives in mod_bonjour. This is expanded from a bug report I submitted to Apple (rdar://problem/5628484).

I keep functional mirrors all my development sites in separate Apache Virtual Hosts. Each one then gets it’s own port, which allows me to check them on local networks, in Parallels and, if I want, remotely via IP address.

To advertise two local vhosts over bonjour, something like this in httpd.conf should work:

<IfModule bonjour_module>
RegisterResource "Site 1" / 9001
RegisterResource "Site 2" / 9002

After restarting Apache (sudo apachectl graceful), local copies of Safari should see the two sites, “Site 1″ and “Site 2″ in Bonjour bookmark listings. In 10.4, they show up. In 10.5, only “Site 2″ shows up. No matter how many directives are included, only the last one will be visible.

I’d love to be wrong about this, but it seems that something broke this function in Leopard.

A faster way of checking Bonjour entries is to open a terminal window and run the following command:

mdns -B _http._tcp

That will show a live updating list of current multicast (Bonjour) entries. Under 10.4, I get the following after adding the above directives to httpd.conf:

16:10:14.517  Add     0 local.     _http._tcp.     Site 1
16:10:14.667  Add     0 local.     _http._tcp.     Site 2

However with 10.5, I get this:

16:12:52.597  Add     1 local.     _http._tcp.     Site 2
16:12:52.598  Add     1 local.     _http._tcp.     Site 2
16:12:52.598  Add     0 local.     _http._tcp.     Site 2

What I’d really love to do is figure out how to register and respond to multiple Bonjour names. That way I could have each vhost be a named host and each staged site accessible at a url like site1.local and site2.local. So far I haven’t had any luck getting that working.

Kettle chips taste-off

Kettle chips taste-off

We got our Kettle Chips Fire and Spice assortment today.

Orange Ginger Wasabi
Tasted like passover. Despite all the mentioned ingredients, the most prominent taste was horseradish. If they’d named it horseradish, it probably would have worked better. This was the most surprising and unusual flavor.
Mango Chili
I thought it tasted mostly like ketchup, with a some extra citrus notes afterwards. Still, this might be my favorite of the bunch.
Salsa Fresca
First taste was astronaut salsa. Freeze-dried tomatoes or something. Definitely my least favorite. Bleh.
Death Valley Chipotle
Tasted like off-the-shelf chili powder. That’s not a good thing. Yes there was a nice lingering heat, but key flavors were just salt, oregano and dried red pepper. No, mostly just salt. This might be the most disappointing flavor of the bunch.
Wicked hot sauce
Nothing special, seems like something I’d had before. Kind of a yawner.

Consensus: no home runs this year. The names of the flavors were consistently better than the flavors themselves. If I had to pick one to sell, I’d probably go with the Death Valley Chipotle, with Mango Chili second. Chipotle wasn’t my favorite, but it was unusual for a chip flavor and the name resonates well.

This promotion itself was brilliant. Everyone in the office was excited to try the new flavors, the packaging was well thought out and the whole experience is an example of what smart, creative branding can accomplish.

Rotating sub-pixel text rendering

John Gruber of Daring Fireball (thanks for the link!) knows a lot about font-rendering, however in a recent post discussing screen-rotation and sub-pixel text rendering he let this slip:

“I tested it on my Cinema Display with the screen rotated 90°, and, to my eyes, sub-pixel anti-aliasing still looked good.”

That is just preposterous. Aside from his observation being completely wrong, he also revealed a bug in OS X: The current system doesn’t recognize rotated pixel orientations, sub-pixel rendering on rotated screens should probably be disabled automatically. (rdar://problem/5627732)

Here are two screenshots of my browser’s address bar as displayed on my Cinema Display, which clearly shows the difference. The top image is Leopard’s default sub-pixel rendering. The second image is the same bar photographed with my display rotated 90°, the photo was then rotated back in Photoshop for better comparison.

Comparison of rotated sub-pixel type

The text was apparently calculated against the presumed horizontal LCD primary orientation. But because the pixels were rotated, several of the letterform stems (verticals) are drawing as full-pixel-width colored lines. The first “h” is especially glaring, its stem and stroke are drawn as a pair of dark red and light blue lines.

Sub-pixel rendering takes advantage of a known horizontal alignment of the three color primaries that make up each physical pixel. The algorithm seems to render text at 3x the horizontal resolution, ignoring the color information and treating each third-pixel as a valid light source to use for drawing letterforms. That 3x width is then striped with red, green and blue to match screen’s component primary ordering. (That was an educated guess)

As Steve Weller stated in the post John linked, the human eye has “pathetic color-resolution”. This fact is exploited all over the place in video, with many formats sampling color only once for every four luminance pixels.

Several things are at play here:

  1. Human vision is the bifocal product of horizontally arranged eyes.
  2. Most written human language uses letterforms which are vertically oriented and horizontally distinguished. Especially Latin-derived languages.
  3. Most human languages read horizontally.
  4. Human vision tends to be less color sensitive for motion, or when scanning information (like reading)

It all just kind of worked out perfectly. Digital color reproduction combined our horizontal predisposition with our soft and slow perception of color, and then arranged color primaries horizontally. Text also reads horizontally, and since the viewer is rapidly moving their eyes, we perceive shape and contrast before color. Additionally, Latinate languages evolved letterforms which utilize horizontal variations against a largely regular vertical syncopation. Presto: sub-pixel rendering just seems fantastically obvious.

Regarding John’s closing supposition,

“I’m not sure the iPhones rotating display is reason enough to rule out sub-pixel rendering.”

Based on everything leading up to sub-pixel rendering in the first place, most of the benefits would be lost if the underlying pixel grid was vertically oriented. The sensitivity of computer text falls across the horizontal axis. Adding resolution to the vertical axis isn’t worth the effort.

Sub-pixel rendering is ultimately a transitional technology anyway, a half-step that improves the now while waiting for a better and inevitable future to arrive. Once we start seeing iPhone level pixel-densities all over the place, sub-pixel rendering will began its transition to technology footnote.

Digital displays will someday reach a point where every physical pixel is capable of producing every color of visible light. (And someone will doubtlessly push into near infrared and ultra-violet, claiming increased realism and fidelity). Future displays will also be operating at a density where anti-aliasing may not be necessary at all.

I still think Apple’s decision to use standard anti-aliasing for the Leopard menu bar was a mistake. Unless they’ve got some spiffy high-pixel-density cinema displays ready for MacWorld and enable system-wide resolution independence in 10.5.x, switching to standard anti-aliased text rendering in the menu bar was a change that should have been postponed. The necessary hardware pool just isn’t here yet and the result is an interface that looks markedly worse than it did under previous releases.

So long Gregory’s, thanks for all the coffee

There was a sign up on the door of Gregory’s Coffee this morning.
Gregory's Coffee

Signs on doors are almost never good.

Gregory's Coffee is Closed

I called their Park Avenue store to ask what happened. The woman I spoke to sounded sad about it, but would only say the store had closed. The neighborhood is going to miss them. Everyone I told at Noemi’s school drop-off this morning was surprised at the news.

Gregory’s was one of three connected one-story storefronts on the corner of 14th and First Avenue.

14th St storefronts

I’ve never really understood how the bodega next door stays in business — or avoids the Health Department. The Hot Dog place has also never seemed especially permanent (or clean for that matter). But the biggest thing I don’t understand is how there is still a one-story building on a busy corner across the street from Stuyvesant Town. That location is worth a fortune and I won’t be at all surprised if I wake up one morning and find the whole thing being demolished.

Next Page »