Mercurial > mplayer.hg
comparison libmpcodecs/vf_vo.c @ 32391:b4c3659d16b1
Use a dynamic list for the sources of EOSD elements.
author | cigaes |
---|---|
date | Sun, 10 Oct 2010 09:27:11 +0000 |
parents | 10327ff5eb4a |
children | d80bbc5868de |
comparison
equal
deleted
inserted
replaced
32390:b33aed46ecda | 32391:b4c3659d16b1 |
---|---|
26 #include "mp_image.h" | 26 #include "mp_image.h" |
27 #include "vf.h" | 27 #include "vf.h" |
28 | 28 |
29 #include "libvo/sub.h" | 29 #include "libvo/sub.h" |
30 #include "libvo/video_out.h" | 30 #include "libvo/video_out.h" |
31 #include "eosd.h" | |
31 | 32 |
32 #include "eosd.h" | 33 #include "eosd.h" |
33 | 34 |
34 //===========================================================================// | 35 //===========================================================================// |
35 | 36 |
121 { | 122 { |
122 return CONTROL_TRUE; | 123 return CONTROL_TRUE; |
123 } | 124 } |
124 case VFCTRL_DRAW_EOSD: | 125 case VFCTRL_DRAW_EOSD: |
125 { | 126 { |
126 EOSD_ImageList images = {NULL, 2}; | 127 struct mp_eosd_image_list images; |
127 mp_eosd_res_t res = {0}; | 128 struct mp_eosd_settings res = {0}; |
128 double pts = vf->priv->pts; | 129 double pts = vf->priv->pts; |
129 if (!vo_config_count) return CONTROL_FALSE; | 130 if (!vo_config_count) return CONTROL_FALSE; |
131 res.unscaled = !!(vf->default_caps & VFCAP_EOSD_UNSCALED); | |
130 if (video_out->control(VOCTRL_GET_EOSD_RES, &res) == VO_TRUE) | 132 if (video_out->control(VOCTRL_GET_EOSD_RES, &res) == VO_TRUE) |
131 eosd_configure(&res, !!(vf->default_caps & VFCAP_EOSD_UNSCALED)); | 133 eosd_configure(&res); |
132 images.imgs = eosd_render_frame(pts, &images.changed); | 134 eosd_render_frame(pts, &images); |
133 return (video_out->control(VOCTRL_DRAW_EOSD, &images) == VO_TRUE) ? CONTROL_TRUE : CONTROL_FALSE; | 135 return (video_out->control(VOCTRL_DRAW_EOSD, &images) == VO_TRUE) ? CONTROL_TRUE : CONTROL_FALSE; |
134 } | 136 } |
135 #endif | 137 #endif |
136 case VFCTRL_GET_PTS: | 138 case VFCTRL_GET_PTS: |
137 { | 139 { |