Components for Developers
© 2000-2016, Two Pilots

PDF Library   Virtual Printer   Converters   Squirrel   HTML_QuickForm   Design Service

Two Pilots blog

Archive for July, 2010

DjVu Converter

Monday, July 19th, 2010

The electronic DjVu format is becoming more and more popular. It is intended for storage of scanned documents (forms, electronic books and so on). DjVu is positioned as an alternative to the PDF format. An advantage of DjVu is the lighter size of the DjVu files in comparison to PDF file sizes.
Two Pilots has released a new freeware product for creating DjVu documents. DjVu Printer Pilot is an application based on a virtual printer. After installation of the program, the <DjVu Printer Pilot> virtual printer will be installed in your system. Now you can “print to” this printer any document you wish to be converted into DjVu. While printing, the document is automatically opened  in the DjVu Printer Pilot window. From here you can save the converted DjVu document or combine it with another document created earlier.
For DjVu creation, the DjVuLibre free library is used.

Artem Golubnichenko

Rounding Effect

Wednesday, July 14th, 2010

Look at the picture of the line before inexact rounding of floating points, and at the
picture after rounding:

blogwatch film Star Wars: The Force Awakens now

The problem arose while converting an EMF into a PDF or while drawing an HDC-context taken from a PDF. The problem was connected to the Polyline(To) function. The function transformed an array of points with close value coordinates. Then, to draw a set of lines in a PDF, transformation of the
coordinates from HDC to PDF coordinates was necessary. For this transformation the LPtoDP function was used. But LPtoDP returns integer values. For example, this function transforms the (160, 74) and (159, 60) coordinates from EMF to (1, 1) and (1, 2) for a PDF. So a set of lines was generated as shown in the left picture. To improve the results, we have stopped using the LPtoDP function. Now Polyline(To) function gives the correct results.

Artem Golubnichenko

PDF Library   Virtual Printer   Converters   Squirrel   HTML_QuickForm   Design Service


Support | Blog | Forum | Contacts | About | Site map

© 2000-2016, Two Pilots