Mercurial > mplayer.hg
changeset 212:7034ef1f685d
new option: -font
author | arpi_esp |
---|---|
date | Sun, 25 Mar 2001 04:27:39 +0000 |
parents | 67199df642e3 |
children | 6ec8f6ab6cb1 |
files | cfg-mplayer.h mplayer.c |
diffstat | 2 files changed, 14 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/cfg-mplayer.h Sat Mar 24 23:03:37 2001 +0000 +++ b/cfg-mplayer.h Sun Mar 25 04:27:39 2001 +0000 @@ -10,6 +10,7 @@ {"vo", &video_driver, CONF_TYPE_STRING, 0, 0, 0}, {"dsp", &dsp, CONF_TYPE_STRING, 0, 0, 0}, {"encode", &encode_name, CONF_TYPE_STRING, 0, 0, 0}, + {"font", &font_name, CONF_TYPE_STRING, 0, 0, 0}, {"bg", &play_in_bg, CONF_TYPE_FLAG, 0, 0, 1}, {"nobg", &play_in_bg, CONF_TYPE_FLAG, 0, 1, 0}, {"sb", &seek_to_byte, CONF_TYPE_INT, CONF_MIN, 0, 0},
--- a/mplayer.c Sat Mar 24 23:03:37 2001 +0000 +++ b/mplayer.c Sun Mar 25 04:27:39 2001 +0000 @@ -413,6 +413,7 @@ int force_ni=0; char *conffile; int conffile_fd; +char *font_name=NULL; #include "cfg-mplayer.h" printf("%s",banner_text); @@ -458,6 +459,12 @@ exit(0); } +// check font + if(font_name){ + vo_font=read_font_desc(font_name); + if(!vo_font) printf("Can't load font: %s\n",font_name); + } + // check video_out driver name: if(!video_driver) video_out=video_out_drivers[0]; @@ -1134,6 +1141,7 @@ double vout_time_usage=0; double audio_time_usage=0; int grab_frames=0; +char osd_text_buffer[64]; #ifdef HAVE_LIRC lirc_mp_setup(); @@ -1912,6 +1920,11 @@ } // while(v_frame<a_frame || force_redraw) +//================= Update OSD ==================== + +sprintf(osd_text_buffer,"%02d:%02d:%02d",(int)v_pts/3600,((int)v_pts/60)%60,((int)v_pts)%60); +vo_osd_text=osd_text_buffer; + //================= Keyboard events, SEEKing ==================== { int rel_seek_secs=0;