1 /* Copyright (C) 2001-2019 Artifex Software, Inc.
2    All Rights Reserved.
3 
4    This software is provided AS-IS with no warranty, either express or
5    implied.
6 
7    This software is distributed under license and may not be copied,
8    modified or distributed except as expressly authorized under the terms
9    of the license contained in the file LICENSE in this distribution.
10 
11    Refer to licensing information at http://www.artifex.com or contact
12    Artifex Software, Inc.,  1305 Grant Avenue - Suite 200, Novato,
13    CA 94945, U.S.A., +1(415)492-9861, for further information.
14 */
15 
16 
17 /* Glyph data cache definition. */
18 
19 #ifndef gxgcache_INCLUDED
20 #  define gxgcache_INCLUDED
21 
22 #include "stdpre.h"
23 #include "scommon.h"
24 
25 /* Using : */
26 
27 typedef struct gs_font_type42_s gs_font_type42;
28 
29 typedef struct gs_glyph_data_s gs_glyph_data_t;
30 
31 /* Data type definition : */
32 
33 typedef struct gs_glyph_cache_s gs_glyph_cache;
34 
35 typedef int (*get_glyph_data_from_file)(gs_font_type42 *pfont, stream *s, uint glyph_index,
36                 gs_glyph_data_t *pgd);
37 
38 /* Methods : */
39 
40 gs_glyph_cache *gs_glyph_cache__alloc(gs_font_type42 *pfont, stream *s,
41                         get_glyph_data_from_file read_data);
42 int gs_glyph_cache__release(void /* gs_glyph_cache */ *data, void*);
43 int gs_get_glyph_data_cached(gs_font_type42 *pfont, uint glyph_index, gs_glyph_data_t *pgd);
44 
45 #endif /* gxgcache_INCLUDED */
46