Hinting of TTF XPSDrv in Research and Implementation
- Author
- LiLinLin
- Advisor
- XuChunXiang
- School
- University of Electronic Science and Technology
- Major
- Information Security
- Classification
- TP311.11 Programming method
- Degree
- Master's thesis
- Year
- 2008
- Downloads
- 33
- Citations
- 0
Abstract
With the release of Vista OS, Microsoft launched a new document format, namely XPS. GDI print path with different traditions, XPS introduced a new print path XPSDrv. GDI print path need to put the document after processing to deliver printer driver, and then sent to the printer. In the new printing framework, WPF applications can generate XPS documents XPS-to-GDI conversion, and then sent to the GDI printer driver can also be delivered directly XPSDrv processing. Win32 applications can print via GDI-to-XPS conversion, then sent XPSDrv XPS file processing. Therefore, XPSDrv research has become a hot area of ??print. Vista OS and have followed the XPS Document format TrueType technology, this technology in the SmartPhone and PDA's and other products are also being widely used, so the TrueType font rendering engine research is particularly important. Time efficiency of existing engines and font appearance, and other aspects are not fully taken care of. Moreover, the existing font rendering engines are designed for the GDI print path, there is no response XPSDrv font rendering engine. To solve these problems, this paper proposes a new solution that can effectively solve the problem XPSDrv in TrueType rendering. The program has divided file parsing, coordinate transformation, Hinting, Rasterizer four modules. File parsing the font file is parsed; coordinate transform coordinates from the Glyph EM coordinate system transformation to the pixel coordinates; Hinting respectively Font Glyph hierarchical levels and contours to be adjusted for the Glyph; Rasterizer scan and fill contours, generate bitmap. This article focuses on the design rendering engine Hinting module, which is divided into Hinting ready, fpgm Hinting, prep Hinting and Glyph Hinting four steps. Hinting ready to initialize the instruction execution need to use some of the parameters. fpgm Hinting define a series of functions and new instructions. prep Hinting According PPEM, recalculate cvt table, Storage Area, Grphic State and so on. Glyph Hinting moving point on the contour, the contour \Furthermore, the engine also introduces the character bitmap caching mechanism, without the need for repeated characters rendered rendering, thus greatly improving the overall rendering efficiency. The engine is a well-known printer manufacturers in Japan, the successful operation of the device, its speed is superior to other manufacturer's engine, and maintained a good bitmap visual effects.