From f5ef880227a6e33ce3c012fa2575121e7cbd068e Mon Sep 17 00:00:00 2001 From: reimar Date: Sun, 18 Jul 2010 18:04:50 +0000 Subject: [PATCH] vo_gl2: Use identical code to -vo gl for -wid mode Fixes the same bugs (no video, video at wrong location...). git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31750 b3059339-0415-0410-9bf9-f77b7e298cf2 --- libvo/vo_gl2.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/libvo/vo_gl2.c b/libvo/vo_gl2.c index 4fb126d5c5..d299459e93 100644 --- a/libvo/vo_gl2.c +++ b/libvo/vo_gl2.c @@ -430,9 +430,10 @@ static void resize(int x,int y){ } else { //aspect(x, y, A_NOZOOM); if (WinID >= 0) { - int top = 0, left = 0, w = x, h = y; - geometry(&top, &left, &w, &h, vo_screenwidth, vo_screenheight); - glViewport(top, left, w, h); + int left = 0, top = 0, w = x, h = y; + geometry(&left, &top, &w, &h, vo_dwidth, vo_dheight); + top = y - h - top; + glViewport(left, top, w, h); } else glViewport( 0, 0, x, y ); } -- 2.11.4.GIT