summaryrefslogtreecommitdiffstats
path: root/sub/font_load.h
diff options
context:
space:
mode:
authorwm4 <wm4@mplayer2.org>2012-07-28 22:00:31 +0200
committerwm4 <wm4@mplayer2.org>2012-07-28 23:36:08 +0200
commit85a3a0d5bc1294f88dea42a515bb3dce16c9d951 (patch)
tree628ad08270d2552795bc6c708d5ce53fc97fb069 /sub/font_load.h
parent74e7a1e937c10d9f4d8ce9b0ba4edee52044a757 (diff)
downloadmpv-85a3a0d5bc1294f88dea42a515bb3dce16c9d951.tar.bz2
mpv-85a3a0d5bc1294f88dea42a515bb3dce16c9d951.tar.xz
osd: remove freetype font rendering code
The previous commit made libass the default OSD renderer. This commit removes the disabled freetype renderer completely. The commits were done separately to make rolling back easier, because using libass for OSD rendering is a risky choice. Also remove freetype/fontconfig/fribidi code. This is all done by libass now. If mplayer is compiled without libass, no OSD is displayed.
Diffstat (limited to 'sub/font_load.h')
-rw-r--r--sub/font_load.h108
1 files changed, 0 insertions, 108 deletions
diff --git a/sub/font_load.h b/sub/font_load.h
deleted file mode 100644
index 933f84804f..0000000000
--- a/sub/font_load.h
+++ /dev/null
@@ -1,108 +0,0 @@
-/*
- * This file is part of MPlayer.
- *
- * MPlayer is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * MPlayer is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with MPlayer; if not, write to the Free Software Foundation, Inc.,
- * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
- */
-
-#ifndef MPLAYER_FONT_LOAD_H
-#define MPLAYER_FONT_LOAD_H
-
-#include "config.h"
-
-#ifdef CONFIG_FREETYPE
-#include <ft2build.h>
-#include FT_FREETYPE_H
-#endif
-
-typedef struct {
- unsigned char *bmp;
- unsigned char *pal;
- int w,h,c;
-#ifdef CONFIG_FREETYPE
- int charwidth,charheight,pen,baseline,padding;
- int current_count, current_alloc;
-#endif
-} raw_file;
-
-typedef struct font_desc {
-#ifdef CONFIG_FREETYPE
- int dynamic;
-#endif
- char *name;
- char *fpath;
- int spacewidth;
- int charspace;
- int height;
-// char *fname_a;
-// char *fname_b;
- raw_file* pic_a[16];
- raw_file* pic_b[16];
- short font[65536];
- int start[65536]; // short is not enough for unicode fonts
- short width[65536];
- int freetype;
-
-#ifdef CONFIG_FREETYPE
- int face_cnt;
-
- FT_Face faces[16];
- FT_UInt glyph_index[65536];
-
- int max_width, max_height;
-
- struct
- {
- int g_r;
- int o_r;
- int g_w;
- int o_w;
- int o_size;
- unsigned volume;
-
- unsigned *g;
- unsigned *gt2;
- unsigned *om;
- unsigned char *omt;
- unsigned short *tmp;
- } tables;
-#endif
-
-} font_desc_t;
-
-extern font_desc_t* vo_font;
-
-extern int vo_image_width;
-extern int vo_image_height;
-
-extern int force_load_font;
-
-int init_freetype(void);
-int done_freetype(void);
-
-font_desc_t* read_font_desc_ft(const char* fname,int face_index,int movie_width, int movie_height, float font_scale_factor);
-void free_font_desc(font_desc_t *desc);
-
-void render_one_glyph(font_desc_t *desc, int c);
-int kerning(font_desc_t *desc, int prevc, int c);
-
-void load_font_ft(int width, int height, font_desc_t **desc, const char *name, float font_scale_factor);
-
-void blur(unsigned char *buffer, unsigned short *tmp2, int width, int height,
- int stride, int *m2, int r, int mwidth);
-
-raw_file* load_raw(char *name,int verbose);
-font_desc_t* read_font_desc(const char* fname,float factor,int verbose);
-
-#endif /* MPLAYER_FONT_LOAD_H */