From 5ff421bf5d7e08a2003a333d1db49e7756f4fe2e Mon Sep 17 00:00:00 2001 From: Uoti Urpala Date: Mon, 22 Feb 2010 02:07:16 +0200 Subject: [PATCH] vo_vdpau: improve VOCTRL_GET_EOSD_RES code Remove the special case for fullscreen; the same variables should have the correct values in windowed and fullscreen modes. This fixes libass subtitle positioning in the (non-typical) case where you have black bands inside a window. Behavior in fullscreen and in the typical windowed case without borders should not be affected. --- libvo/vo_vdpau.c | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/libvo/vo_vdpau.c b/libvo/vo_vdpau.c index 1b34cba642..dfd51a4130 100644 --- a/libvo/vo_vdpau.c +++ b/libvo/vo_vdpau.c @@ -1785,16 +1785,10 @@ static int control(struct vo *vo, uint32_t request, void *data) return VO_TRUE; case VOCTRL_GET_EOSD_RES: { mp_eosd_res_t *r = data; - r->mt = r->mb = r->ml = r->mr = 0; - if (vo_fs) { - r->w = vo->opts->vo_screenwidth; - r->h = vo->opts->vo_screenheight; - r->ml = r->mr = vc->border_x; - r->mt = r->mb = vc->border_y; - } else { - r->w = vo->dwidth; - r->h = vo->dheight; - } + r->w = vo->dwidth; + r->h = vo->dheight; + r->ml = r->mr = vc->border_x; + r->mt = r->mb = vc->border_y; return VO_TRUE; } case VOCTRL_REDRAW_OSD: