Handwritten Fonts Modeling Based on Fat Lines of Variable Width Stanislav Klimenko Moscow Physicotechnical Institute Moscow, Russia Leonid Mestetskiy Moscow State University Moscow, Russia Andrey Semenov Tver State University Tver, Russia
Fonts Describing The 16-th International Conference in Central Europe on Computer Graphics, Visualization and Computer Vision'2008 Outline description is union of Bezier curves 2
Fonts Describing Disadvantages of outline description: 1. Implementation of “alive” handwriting is difficulty 2. Doesn’t allow implementing variations of stroke width of pen 3. The problem of preservation of contour smoothness ? 3
Handwritten Fonts 4
1.Representation of a font as a trace of pen «with a variable width» 2.Obtaining of a font in the form of curves with a width on the scanned image Our approach 5
- Fat curve with axis P(t)=(u(t),v(t)) and thickness r(t) Fat Curve is family of circles of variable radius with centers on smooth curve 6
Elementary Fat B-Spline Curve 7
Composite Fat B-Spline Curve 8
The hand-written alphabet (Russian) Personal hand-written font Our task 9
Step 1 The person writes separate letters by ink pen on a paper, for example, the alphabet The method description Step 2 The image is digitized by the scanner 10
The method description Binary image Polygonal figure Step 3 Construction of piecewise-linear boundary as a polygon of minimal perimeter 11
The method description Polygonal figure Continuous skeleton Step 4 Construction of continuous skeleton as a set of medial axes of polygonal figure 12
The method description Step 5 Construction of a base skeleton Continuous skeletonBase skeleton 13
The method description Step 6 Decomposition branches of base skeleton Base skeleton Base skeleton with circles 14
The method description Step 7 Approximation of base skeleton by a circular figure Circular figure Base skeleton with circles 15
Fat Curve Outline Smoothing Recalculation radius value for each control circle: 16
Fat Curve Axis Smoothing Recalculation center coordinates for each control circle: 17
Fat Curve Sewing 18
Kerning task What is better ? 19
Alignment of letter spacing Kerning - is a visual alignment of letter spacing in process of text on raster devices. How is near ? 20
Method of Automatic Kerning 1. Rasterization of kerning pair of characters on a common base line of raster 21
Method of Automatic Kerning 2. Scanning by a horizontal line "from top to bottom" with step of 1 pixel 22
Method of Automatic Kerning 3. At each position of a scanning line 23
4. Defining position of a scanning line at which distance between the points is minimum Method of Automatic Kerning Minimal distance 24
5. Defining minimal kerning distance Method of Automatic Kerning Minimal kerning distance Is negative kerning 25
5. Defining minimal kerning distance Method of Automatic Kerning Minimal kerning distance Is positive kerning 26
Some examples KERNING[я][б] = 15 KERNING[в][а] = -72 Method of Automatic Kerning Minimal kerning distance is 20 27
Kerning table абвг.. эюя а б в г э ю я Method of Automatic Kerning 28
Method of Automatic Kerning KERNING[в][ю] = -88What does it mean ? Length of this segment is 88 It means how many pixels to the left it is necessary to move the right character 29
Some examples Method of Automatic Kerning It’s A.S. Pushkin No kerning 30
Some examples Method of Automatic Kerning It’s A.S. Pushkin Kerning is 20 pixels 31
Some examples Method of Automatic Kerning It’s A.S. Pushkin Kerning is 40 pixels 32
Thickness Pen Modeling 33
3D Modeling 34 Modeling of 3D effect by layer painting
“Alive” Handwriting Modeling - is noise Adding of small noise into values of radiuses 35
Adding of small noise into values of radiuses “Alive” Handwriting Modeling 36
Converting fat curve representation to outline description Export to famous description 37 Fat curves descriptionPostScript description
Summary The method of fat curves is efficient tool for modeling of hand-written characters; There is possibility of letterspacings controlling (zoom in/out letterspacing); There is easy way to modeling “alive” handwriting; Our approach can be used as embedded module (plug-in) in font editors. 38