# HG changeset patch # User diego # Date 1230907298 0 # Node ID 56868e6fb3401675c0f7c3f9a47ada768c3ff5eb # Parent 0f4e0c39c20e6ff68181d40b9fd457ed1c5b2ac5 Conditionally define render_one_glyph and kerning dummy functions in font_load.c when FreeType is not enabled instead of conditionally defining them in font_load.h. This moves the workaround closer to where the actual problem is. diff -r 0f4e0c39c20e -r 56868e6fb340 libvo/font_load.c --- a/libvo/font_load.c Fri Jan 02 13:25:00 2009 +0000 +++ b/libvo/font_load.c Fri Jan 02 14:41:38 2009 +0000 @@ -335,3 +335,8 @@ free(desc); return NULL; } + +#ifndef CONFIG_FREETYPE +void render_one_glyph(font_desc_t *desc, int c) {} +int kerning(font_desc_t *desc, int prevc, int c) { return 0; } +#endif diff -r 0f4e0c39c20e -r 56868e6fb340 libvo/font_load.h --- a/libvo/font_load.h Fri Jan 02 13:25:00 2009 +0000 +++ b/libvo/font_load.h Fri Jan 02 14:41:38 2009 +0000 @@ -64,8 +64,6 @@ extern font_desc_t* vo_font; extern font_desc_t* sub_font; -#ifdef CONFIG_FREETYPE - extern char *subtitle_font_encoding; extern float text_font_scale_factor; extern float osd_font_scale_factor; @@ -92,13 +90,6 @@ void blur(unsigned char *buffer, unsigned short *tmp2, int width, int height, int stride, int *m2, int r, int mwidth); -#else - -static void render_one_glyph(font_desc_t *desc, int c) {} -static int kerning(font_desc_t *desc, int prevc, int c) { return 0; } - -#endif - raw_file* load_raw(char *name,int verbose); font_desc_t* read_font_desc(const char* fname,float factor,int verbose);