comparison libvo/vo_vdpau.c @ 28805:b382d065ba53

As for vo_gl, do not rely on draw_osd to render EOSD.
author reimar
date Fri, 06 Mar 2009 10:39:58 +0000
parents 5ccdec6c14f0
children 338065cac802
comparison
equal deleted inserted replaced
28804:5ccdec6c14f0 28805:b382d065ba53
203 * X11 specific 203 * X11 specific
204 */ 204 */
205 static int visible_buf; 205 static int visible_buf;
206 static int int_pause; 206 static int int_pause;
207 207
208 static void draw_eosd(void);
209
208 static void video_to_output_surface(void) 210 static void video_to_output_surface(void)
209 { 211 {
210 VdpTime dummy; 212 VdpTime dummy;
211 VdpStatus vdp_st; 213 VdpStatus vdp_st;
212 int i; 214 int i;
217 // deinterlacing, which is not really possible currently. 219 // deinterlacing, which is not really possible currently.
218 for (i = 0; i <= !!(deint > 1); i++) { 220 for (i = 0; i <= !!(deint > 1); i++) {
219 int field = VDP_VIDEO_MIXER_PICTURE_STRUCTURE_FRAME; 221 int field = VDP_VIDEO_MIXER_PICTURE_STRUCTURE_FRAME;
220 VdpOutputSurface output_surface; 222 VdpOutputSurface output_surface;
221 if (i) { 223 if (i) {
224 draw_eosd();
222 draw_osd(); 225 draw_osd();
223 flip_page(); 226 flip_page();
224 } 227 }
225 if (deint) 228 if (deint)
226 field = top_field_first == i ? 229 field = top_field_first == i ?
655 ass_image_t *img = imgs->imgs; 658 ass_image_t *img = imgs->imgs;
656 ass_image_t *i; 659 ass_image_t *i;
657 660
658 // Nothing changed, no need to redraw 661 // Nothing changed, no need to redraw
659 if (imgs->changed == 0) 662 if (imgs->changed == 0)
660 return; 663 goto eosd_draw_only;
661 eosd_render_count = 0; 664 eosd_render_count = 0;
662 // There's nothing to render! 665 // There's nothing to render!
663 if (!img) 666 if (!img)
664 return; 667 return;
665 668
734 eosd_targets[eosd_render_count].source.y0 = 0; 737 eosd_targets[eosd_render_count].source.y0 = 0;
735 eosd_targets[eosd_render_count].source.x1 = i->w; 738 eosd_targets[eosd_render_count].source.x1 = i->w;
736 eosd_targets[eosd_render_count].source.y1 = i->h; 739 eosd_targets[eosd_render_count].source.y1 = i->h;
737 eosd_render_count++; 740 eosd_render_count++;
738 } 741 }
742 eosd_draw_only:
743 draw_eosd();
739 } 744 }
740 745
741 static void draw_osd(void) 746 static void draw_osd(void)
742 { 747 {
743 mp_msg(MSGT_VO, MSGL_DBG2, "DRAW_OSD\n"); 748 mp_msg(MSGT_VO, MSGL_DBG2, "DRAW_OSD\n");