|
|
||
m = 1 (March 1, 2008) |
| ||
|
|
UPM | UPM stands for units per eM. These are whole numbers that generally describe the size of the coordinate space in which a font is designed. For example, with a UPM of 1000, each contour point of a font is roughly in an imaginary box of 1000 by 1000. The UPM defines a grid, so the higher the UPM, the finer the grid. The grid size for a UPM of 1000 is 1000x1000, or one million. Think of it as the ``megapixels'' in a font. Font specifications differ for various font formats, and most font specifications allow points to occur outside the UPM box (but not far outside).
|
Conversions | It is often said that truetype fonts can be losslessly converted into type 1 fonts. That can only be so if the UPM of the type 1 font is equal to or a multiple of that of the truetype font. With a conversion from truetype's 2048 to PostScript's 1000, a rounding loss is unavoidable. Furthermore, since new outline points inherent in the conversion have coordinates that need to be divided by three or two without leaving a remainder, the rule for lossless conversion is that the PostScript UPM divided by the truetype UPM should be a multiple of six. So, truetype's 2048 should become PostScript's 6 x 2048 = 12,288, or a multiple of that. And truetype's 16,384 should become PostScript's 98,304. The conversion from type 1 (cubic Bezier) to truetype (quadratic Bezier) on the other hand involves a loss, regardless of the UPM value. It is probably correct to say that not a single conversion in history has been lossless. |
m = 1 | Is it possible to design fonts with an "em" or UPM equal to one? That would mean that all vertices and all control points would have to be chosen from four points, [ 0 0 ], [ 0 1 ], [ 1 1 ] and [ 1 0 ], the four vertices of the unit square. Well, why don't we find out? On a snowy Montreal winter day, it took just a few hours to design some type one fonts with a FontMatrix equal to an astonishing [ 1 0 0 1 0 0 ]. Clearly, this had to be done by coding the process, because font editors generally give up: all control points and end points basically coincide, and mouseclicking is futile. There is a lot of beautiful amoebic life within the severe limitations imposed on the design. Just consider that there are 256 (4 to the power 4) possible Bezier curves based on those four corner points of the square, and that these can be joined together in many ways. It is quite impossible to show all the glyphs that can be obtained. Because of the winding rule and the nonlinearity of the Bezier curves, it is not easy to count the number of different glyphs obtainable, but it is clearly well over a billion. So, I took a more modest aim, and generated two sets of 256 glyphs at random, and called the experimental fonts UMP1a and UMP1b, with one having more Bezier components per glyph than the other. All little giflets on this page are drawn from these two fonts. |
Code | Here is a part of the code for one glyph, to show that we are just working within that unit box. /FontBBox [ 0 0 1 1 ] readonly def /FontMatrix [ 1 0 0 1 0 0 ] def ... /Barack-054 { 0 1 hsbw 0 0 rmoveto 1 0 -1 1 1 -1 rrcurveto -1 1 0 -1 1 1 rrcurveto -1 0 0 -1 0 0 rrcurveto closepath endchar } ND ... |
The font UMP1b |
|
The character palettes | The full character palettes: UMP1a, UMP1b. The name: why UMP and not UPM? Download the type 1 fonts: UMP1a and UMP1b. |
|
|