From 01c7934aebe7901dec518ee948890d81dc53488b Mon Sep 17 00:00:00 2001 From: kramm Date: Tue, 11 May 2004 17:08:31 +0000 Subject: [PATCH] * small changes to glyph display * swf_FontExtractDefineText is now called swf_ParseDefineText --- src/swfdump.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/swfdump.c b/src/swfdump.c index 95b06f6..bb7992c 100644 --- a/src/swfdump.c +++ b/src/swfdump.c @@ -247,10 +247,10 @@ SWF swf; int fontnum = 0; SWFFONT**fonts; -void textcallback(int*glyphs, int nr, int fontid) +void textcallback(void*self, int*glyphs, int*ypos, int nr, int fontid, int fontsize, int startx, int starty, RGBA*color) { int font=-1,t; - printf(" <%2d glyphs in font %2d> ",nr, fontid); + printf(" <%2d glyphs in font %2d, color #%02x%02x%02x%02x> ",nr, fontid, color->r, color->g, color->b, color->a); for(t=0;tid == fontid) { @@ -265,9 +265,9 @@ void textcallback(int*glyphs, int nr, int fontid) if(font>=0) { if(glyphs[t] >= fonts[font]->numchars /*glyph is in range*/ || !fonts[font]->glyph2ascii /* font has ascii<->glyph mapping */ - ) - continue; - a = fonts[font]->glyph2ascii[glyphs[t]]; + ) a = glyphs[t]; + else + a = fonts[font]->glyph2ascii[glyphs[t]]; } else { a = glyphs[t]; } @@ -282,7 +282,7 @@ void textcallback(int*glyphs, int nr, int fontid) void handleText(TAG*tag) { printf("\n"); - swf_FontExtract_DefineTextCallback(-1,0,tag,4, textcallback); + swf_ParseDefineText(tag,textcallback, 0); } void handleDefineSound(TAG*tag) -- 1.7.10.4