1 /***************************************************************************/
5 /* FreeType Multiple Master font interface (specification). */
7 /* Copyright 1996-2001 by */
8 /* David Turner, Robert Wilhelm, and Werner Lemberg. */
10 /* This file is part of the FreeType project, and may only be used, */
11 /* modified, and distributed under the terms of the FreeType project */
12 /* license, LICENSE.TXT. By continuing to use, modify, or distribute */
13 /* this file you indicate that you have read the license and */
14 /* understand and accept it fully. */
16 /***************************************************************************/
24 #include FT_TYPE1_TABLES_H
30 /*************************************************************************/
33 /* multiple_masters */
36 /* Multiple Masters */
39 /* How to manage Multiple Masters fonts. */
42 /* The following types and functions are used to manage Multiple */
43 /* Master fonts, i.e. the selection of specific design instances by */
44 /* setting design axis coordinates. */
46 /*************************************************************************/
49 /*************************************************************************/
55 /* A simple structure used to model a given axis in design space for */
56 /* Multiple Masters fonts. */
59 /* name :: The axis's name. */
61 /* minimum :: The axis's minimum design coordinate. */
63 /* maximum :: The axis's maximum design coordinate. */
65 typedef struct FT_MM_Axis_
74 /*************************************************************************/
80 /* A structure used to model the axes and space of a Multiple Masters */
84 /* num_axis :: Number of axes. Cannot exceed 4. */
86 /* num_designs :: Number of designs; should ne normally 2^num_axis */
87 /* even though the Type 1 specification strangely */
88 /* allows for intermediate designs to be present. This */
89 /* number cannot exceed 16. */
91 /* axis :: A table of axis descriptors. */
93 typedef struct FT_Multi_Master_
97 FT_MM_Axis axis
[T1_MAX_MM_AXIS
];
104 (*FT_Get_MM_Func
)( FT_Face face
,
105 FT_Multi_Master
* master
);
108 (*FT_Set_MM_Design_Func
)( FT_Face face
,
113 (*FT_Set_MM_Blend_Func
)( FT_Face face
,
118 /*************************************************************************/
121 /* FT_Get_Multi_Master */
124 /* Retrieves the Multiple Master descriptor of a given font. */
127 /* face :: A handle to the source face. */
130 /* amaster :: The Multiple Masters descriptor. */
133 /* FreeType error code. 0 means success. */
135 FT_EXPORT( FT_Error
)
136 FT_Get_Multi_Master( FT_Face face
,
137 FT_Multi_Master
*amaster
);
140 /*************************************************************************/
143 /* FT_Set_MM_Design_Coordinates */
146 /* For Multiple Masters fonts, choose an interpolated font design */
147 /* through design coordinates. */
150 /* face :: A handle to the source face. */
153 /* num_coords :: The number of design coordinates (must be equal to */
154 /* the number of axes in the font). */
156 /* coords :: An array of design coordinates. */
159 /* FreeType error code. 0 means success. */
161 FT_EXPORT( FT_Error
)
162 FT_Set_MM_Design_Coordinates( FT_Face face
,
167 /*************************************************************************/
170 /* FT_Set_MM_Blend_Coordinates */
173 /* For Multiple Masters fonts, choose an interpolated font design */
174 /* through normalized blend coordinates. */
177 /* face :: A handle to the source face. */
180 /* num_coords :: The number of design coordinates (must be equal to */
181 /* the number of axes in the font). */
183 /* coords :: The design coordinates array (each element must be */
184 /* between 0 and 1.0). */
187 /* FreeType error code. 0 means success. */
189 FT_EXPORT( FT_Error
)
190 FT_Set_MM_Blend_Coordinates( FT_Face face
,
200 #endif /* __FTMM_H__ */