mirror of https://github.com/mpv-player/mpv
vo_gl: Fix -geometry with -wid behaviour (y position was flipped)
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31600 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
d1455cac3c
commit
30d7c19b69
|
@ -197,9 +197,10 @@ static void redraw(void);
|
||||||
static void resize(int x,int y){
|
static void resize(int x,int y){
|
||||||
mp_msg(MSGT_VO, MSGL_V, "[gl] Resize: %dx%d\n",x,y);
|
mp_msg(MSGT_VO, MSGL_V, "[gl] Resize: %dx%d\n",x,y);
|
||||||
if (WinID >= 0) {
|
if (WinID >= 0) {
|
||||||
int top = 0, left = 0, w = x, h = y;
|
int left = 0, top = 0, w = x, h = y;
|
||||||
geometry(&top, &left, &w, &h, vo_dwidth, vo_dheight);
|
geometry(&left, &top, &w, &h, vo_dwidth, vo_dheight);
|
||||||
mpglViewport(top, left, w, h);
|
top = y - h - top;
|
||||||
|
mpglViewport(left, top, w, h);
|
||||||
} else
|
} else
|
||||||
mpglViewport( 0, 0, x, y );
|
mpglViewport( 0, 0, x, y );
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue