avfilter: use the getters for xGA font data arrays

Signed-off-by: James Almer <jamrial@gmail.com>
This commit is contained in:
James Almer
2025-07-21 21:39:16 -03:00
parent cb9742af76
commit da18c2a373
11 changed files with 26 additions and 22 deletions

View File

@@ -252,6 +252,7 @@ static int audio_frame(AVFilterLink *outlink)
static void draw_text(FFDrawContext *draw, AVFrame *out, FFDrawColor *color,
int x0, int y0, const uint8_t *text)
{
const uint8_t *cga_font = avpriv_cga_font_get();
int x = x0;
for (; *text; text++) {
@@ -262,7 +263,7 @@ static void draw_text(FFDrawContext *draw, AVFrame *out, FFDrawColor *color,
}
ff_blend_mask(draw, color, out->data, out->linesize,
out->width, out->height,
avpriv_cga_font + *text * 8, 1, 8, 8, 0, 0, x, y0);
&cga_font[*text * 8], 1, 8, 8, 0, 0, x, y0);
x += 8;
}
}