summaryrefslogtreecommitdiffstats
path: root/libass/ass_render.h
diff options
context:
space:
mode:
authorGrigori Goronzy <greg@blackbox>2011-07-11 20:35:16 +0200
committerGrigori Goronzy <greg@blackbox>2011-07-11 20:35:16 +0200
commit8e87db144289d8f7418f4b0dcd2a02d2f7b1d7eb (patch)
tree60bd7f0a0e8354fb0e9e76969f626ac64f029ed6 /libass/ass_render.h
parentdb6ccb3634db5ccbce1a2fdaa383085242d52c82 (diff)
downloadlibass-8e87db144289d8f7418f4b0dcd2a02d2f7b1d7eb.tar.bz2
libass-8e87db144289d8f7418f4b0dcd2a02d2f7b1d7eb.tar.xz
Support glyph clusters of multiple glyphs
Sometimes a glyph cluster resolves to multiple glyphs, for example when diacritics are used with Arabic script. This doesn't map well to the list of glyphs expected by libass. Extend the glyph list to a list of singly-linked glyph clusters of glyphs and adapt the renderer to support this.
Diffstat (limited to 'libass/ass_render.h')
-rw-r--r--libass/ass_render.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/libass/ass_render.h b/libass/ass_render.h
index ea29c79..33e046f 100644
--- a/libass/ass_render.h
+++ b/libass/ass_render.h
@@ -96,7 +96,7 @@ typedef enum {
// describes a glyph
// GlyphInfo and TextInfo are used for text centering and word-wrapping operations
-typedef struct {
+typedef struct glyph_info {
unsigned symbol;
unsigned skip; // skip glyph when layouting text
ASS_Font *font;
@@ -137,6 +137,9 @@ typedef struct {
int shape_run_id;
BitmapHashKey hash_key;
+
+ // next glyph in this cluster
+ struct glyph_info *next;
} GlyphInfo;
typedef struct {