UpPreviousNext







Date: 1993-11-21
From: John
Subject: Gridlines

My Dear Mr. Duk:

I also think my maps argue against gridlines at every coordinate and agree that we should explore gridlines at 2,3,4, or 5 coordinate intervals. My point about gridlines was simply this: when you you begin mucking with the map pixel by pixel it becomes necessary to consider the gridlines in your calculations.

There are two basic approaches to gridlines. The first is to draw and smooth the map as if there were no gridlines and then, as a final step, paint gridlines over the surface of the map, destroying one-pixel-wide strips in the process. I am opposed to this approach because when the grid interval is more than one, not all coordinate blocks will include a gridline and thus some blocks will be slightly larger than others.

The second approach, the one I favor, is to create gridlines by slightly separating the blocks every 2,3,4, or 5 coordinates. The reason this adds an extra wrinkle to the calculations is that when pixels are adjacent to a gridline, their neighboring pixels are not the pixels which make up the line, but pixels on the other side of the line. Thus the pixel immediately west of 182,75 is 181,75, but the pixel immediately west of 181,75 is not 180,75 but 179,75. The good news is that this is a very minor wrinkle, easily handled by an extra calculation or two.

I also agree that the lacy coastline produced by my algorithm (it used to be "the" algorithm; now it's "my" algorithm *sigh*) is "interesting but distracting." Given the massive time investment I made in order to finally taste the fruits of this approach I am disappointed but will bravely carry on in search of a better way.

I am hours away from buying a Newton so that I can learn how to program the damn things; I'll tell you al about it on the next tape. So what are your travel plans for the week ahead? Joining your sister for the carving of the bird?

Yours in haste,

Epicurious J.

UpPreviousNext