summaryrefslogtreecommitdiff
path: root/tests/make_png/README
blob: 0c661ce7f2c2f1eff25c0516e804effad3c94416 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
NOTE: First make freetype library (in the ../../ directory)
  make devel
  make
 
TODO:   Generate HTML page for detailed comparison

/*******************************************************************/

To generate sprite sheets in the /images folder and to generate the
"index.html" (List-View) of the glyphs.

By clicking on the Headers of the respective columns,they can be
arranged (in increasing/decreasing order) based on
->  Glyph-Index
->  Name
->  Difference Metric (right now it is the number of pixels that are
    different between the base and the test glyph)

It displays the whole sprite sheet right now (will be used later)
Hashes will be diplayed (To be implemented)

First compile and install two versions of the FreeType libray 
in different folders (with SUBPIXEL_RENDERING enabled in ftoption.h)


1)  make sprite
    (set resoluton in DPI by passing argument
    example: make DPI=100, if not specified,default is 72)

2)  Usage ./sprite <a> <b> <font_file> <pt_size> <render_mode>

    (<a> is the libfreetype.so from the base vesion )
    (<b> is the libfreetype.so from the test vesion )

    The path to the "shared library" in usage should be absolute.

    Sprite Sheets will be saved as sprite_$(glyph_index).png

    Render modes similar to generating PNG(s).

NOTE: If the dimensions of the two glyphs to be compared are
different, comparison is done after aligning the glyphs.
This alignment will effect the 'Difference Metric' based on the 
number of rows/columns added.

/*******************************************************************/
(DEPRECATED)
To generate hashes and store it in the ./hashes folder,

1)  make hash
		(set resoluton in DPI by passing argument
		example: make DPI=100, if not specified,default is 72)

2) 	Usage   ./hash <font_file> <pt_size> <render_mode>
	
    Hashes will be saved in a file named 
    $(font)_$(pt_size)_$(render_mode).hash 

    By default, hashes of 256-level gray bitmaps will be generated

    Values for render_mode    0 - monochrome
                              1 - anti-aliased
                              2 - lcd horizontal
                              3 - lcd vertical

/*******************************************************************/
(DEPRECATED)
To generate 32-bit RGBA PNG(s) of all glyphs in a font\n
  
1)  make png
		(set resoluton in DPI by passing argument
  	example: make DPI=100, if not specified,default is 72)

2) 	Usage   ./<exe> <font_file> <pt_size> <render_mode>

	  Images will be saved in a file named 
	  $(font)_$(pt_size)_$(render_mode)_$(glyph_index).png

	  By default, hashes of 256-level gray bitmaps will be generated

	  Values for render_mode    0 - monochrome
	                            1 - anti-aliased
	                            2 - lcd horizontal-RGB
	                            3 - lcd horizontal-BGR
	                            4 - lcd vertical-RGB
                              5 - lcd vertical-BGR