Opened 19 years ago
Last modified 14 years ago
#278 new defect
Fullscreen broken on Blackbox 0.70.0
Reported by: | Owned by: | reimar | |
---|---|---|---|
Priority: | normal | Component: | vo |
Version: | HEAD | Severity: | normal |
Keywords: | Cc: | ||
Blocked By: | Blocking: | ||
Reproduced by developer: | no | Analyzed by developer: | no |
Description
Blackbox 0.70.0 tries to obey aspect (size) hints when in fullscreen mode, while
also obeying the NetWM hints. This causes fullscreen to be truncated, depending
on the aspect of the video- but since MPlayer draws the black bars, this means
part of the video is cut off. My solution is this:
diff -Nru a/libvo/x11_common.c b/libvo/x11_common.c
--- a/libvo/x11_common.c 2005-04-16 10:52:03.000000000 -0500
+++ b/libvo/x11_common.c 2005-04-16 23:09:11.000000000 -0500
@@ -1440,35 +1440,43 @@
{
if (vo_dwidth != vo_screenwidth && vo_dheight != vo_screenheight)
return;
- x = vo_old_x;
- y = vo_old_y;
- w = vo_old_width;
- h = vo_old_height;
- }
+ }
+ Since the size IS hinted for EWMH, now, we need to restore the proper size.
+ x = vo_old_x;
+ y = vo_old_y;
+ w = vo_old_width;
+ h = vo_old_height;
+ vo_x11_sizehint(x, y, w, h, 0);
vo_x11_ewmh_fullscreen(_NET_WM_STATE_REMOVE); removes fullscreen
state if wm supports EWMH
vo_fs = VO_FALSE;
} else
{
win->fs
- vo_x11_ewmh_fullscreen(_NET_WM_STATE_ADD); sends fullscreen
state to be added if wm supports EWMH
-
- vo_fs = VO_TRUE;
+ There's a small problems with EWMH and keepaspect: Blackbox 0.70.0 tries
to obey both the aspect
+ and the fullscreen request, resulting in a loss of about 1/5th of the
bottom of the mplayer
+ window. This is fixed by sizehinting the window to the screen size.
if ( ! (vo_fs_type & vo_wm_FULLSCREEN) ) not needed with EWMH fs
{
if (vo_old_width &&
(vo_dwidth == vo_screenwidth && vo_dwidth != vo_old_width) &&
- (vo_dheight == vo_screenheight && vo_dheight != vo_old_height))
+ (vo_dheight == vo_screenheight && vo_dheight != vo_old_height)) {
+ vo_fs = VO_TRUE;
return;
- vo_old_x = vo_dx;
- vo_old_y = vo_dy;
- vo_old_width = vo_dwidth;
- vo_old_height = vo_dheight;
- x = 0;
- y = 0;
- w = vo_screenwidth;
- h = vo_screenheight;
+ }
}
+ vo_old_x = vo_dx;
+ vo_old_y = vo_dy;
+ vo_old_width = vo_dwidth;
+ vo_old_height = vo_dheight;
+ x = 0;
+ y = 0;
+ w = vo_screenwidth;
+ h = vo_screenheight;
+ vo_x11_sizehint( x, y, w, h, 0);
+ vo_x11_ewmh_fullscreen(_NET_WM_STATE_ADD); sends fullscreen
state to be added if wm supports EWMH
+
+ vo_fs = VO_TRUE;
}
{
long dummy;
@@ -1489,7 +1497,7 @@
if ( ! (vo_fs_type & vo_wm_FULLSCREEN) ) not needed with EWMH fs
{
vo_x11_decoration(mDisplay, vo_window, (vo_fs) ? 0 : 1);
- vo_x11_sizehint(x, y, w, h, 0);
+ vo_x11_sizehint(x, y, w, h, 0);
vo_x11_setlayer(mDisplay, vo_window, vo_fs);
Basically, we sizehint the window as the size of the screen before going
fullscreen. This seems to work alright on blackbox 0.70.0.. If other EWMH WMs
ignore size hints on fullscreen anyway, this shouldn't effect them, and since
the commands are executed for non-EWMH WMs, there should be no change there.
Attachments (1)
Change History (4)
by , 19 years ago
Attachment: | fixforblackbox070.diff added |
---|
comment:1 by , 19 years ago
comment:2 by , 18 years ago
Owner: | changed from | to
---|
comment:3 by , 14 years ago
Owner: | changed from | to
---|
Proposed fix