summaryrefslogtreecommitdiffstats
path: root/libass/ass_fontselect.h
diff options
context:
space:
mode:
authorGrigori Goronzy <greg@chown.ath.cx>2011-08-20 18:19:25 +0200
committerGrigori Goronzy <greg@chown.ath.cx>2015-07-10 10:42:40 +0200
commit4803b0a7bc9fee78e9eafb7417fa20f9a21d675f (patch)
tree19a12b4c387d5c4909f3275fe72e316e79e9416a /libass/ass_fontselect.h
parentf69ec6e0c038fe32cc5f91cc62cba52fe3934885 (diff)
downloadlibass-4803b0a7bc9fee78e9eafb7417fa20f9a21d675f.tar.bz2
libass-4803b0a7bc9fee78e9eafb7417fa20f9a21d675f.tar.xz
Export font provider interface
Add wrapper to the ASS_Renderer to create a font provider from its internal font selector and shuffle some code around to export everything that's needed for font providers to the public. Document font provider functions.
Diffstat (limited to 'libass/ass_fontselect.h')
-rw-r--r--libass/ass_fontselect.h37
1 files changed, 0 insertions, 37 deletions
diff --git a/libass/ass_fontselect.h b/libass/ass_fontselect.h
index ec4c793..59a447b 100644
--- a/libass/ass_fontselect.h
+++ b/libass/ass_fontselect.h
@@ -25,45 +25,12 @@
typedef struct ass_shaper_font_data ASS_ShaperFontData;
typedef struct font_selector ASS_FontSelector;
-typedef struct font_provider ASS_FontProvider;
typedef struct font_info ASS_FontInfo;
#include "ass_types.h"
#include "ass.h"
#include "ass_font.h"
-// get face data
-typedef void *(*GetFaceFunc)(void *, size_t *);
-
-// check for a glyph
-typedef int (*CheckGlyphFunc)(void *, uint32_t);
-
-// destroy font_info and related data
-typedef void (*DestroyFunc)(void *);
-typedef void (*DestroyProviderFunc)(void *);
-
-typedef struct font_provider_funcs {
- GetFaceFunc get_face;
- CheckGlyphFunc check_glyph;
- DestroyFunc destroy_font;
- DestroyProviderFunc destroy_provider;
-} ASS_FontProviderFuncs;
-
-#define FONT_WEIGHT_LIGHT 300
-#define FONT_WEIGHT_MEDIUM 400
-#define FONT_WEIGHT_BOLD 700
-#define FONT_SLANT_NONE 0
-#define FONT_SLANT_ITALIC 100
-#define FONT_SLANT_OBLIQUE 110
-
-typedef struct font_provider_meta_data {
- char *family;
- char **fullnames;
- int n_fullname;
- int slant;
- int weight;
-} ASS_FontProviderMetaData;
-
ASS_FontSelector *
ass_fontselect_init(ASS_Library *library,
FT_Library ftlibrary, const char *family,
@@ -76,9 +43,5 @@ void ass_fontselect_free(ASS_FontSelector *priv);
// Font provider functions
ASS_FontProvider *ass_font_provider_new(ASS_FontSelector *selector,
ASS_FontProviderFuncs *funcs, void *data);
-int ass_font_provider_add_font(ASS_FontProvider *provider,
- ASS_FontProviderMetaData *meta, const char *path, unsigned int index,
- void *data);
-void ass_font_provider_free(ASS_FontProvider *provider);
#endif /* LIBASS_FONTCONFIG_H */