Opened 3 years ago

Closed 4 days ago

#2213 closed defect (fixed)

Fullscreen mplayer crops menubar area and does not cover Dock area in OS X Yosemite

Reported by: machsna Owned by: beastd
Priority: normal Component: vo
Version: unspecified Severity: normal
Keywords: osx Cc:
Blocked By: Blocking:
Reproduced by developer: yes Analyzed by developer: yes

Description

Summary of the bug:

  1. When you enter fullscreen mode in Mac OS X 10.10 "Yosemite" by hitting the interactive keyboard control for Toggle fullscreen (f), the areas of the screen that are normally occupied by the menubar is cropped from the fullscreen image, while the are normally occupied by the Dock remains outside of the fullscreen image. The menubar and the Dock are not displayed. Instead, the desktop wallpaper shines through.
  1. When you start mplayer with the fullscreen playback flag (-fs), it does not open in a fullscreen window. Instead, it opens in a window with a normal title bar. The areas normally occupied by the menubar and the Dock remain outside of this window. Again, the desktop wallpaper shines throuth in these areas.

This affects the following versions of mplayer:

  • MPlayer SVN-r36986-4.2.1 (C) 2000-2014 MPlayer Team from MPlayer OSX Extended.app rev15 (1511) – not the GUI app, but instead, the proper CLI mplayer that is hidden within the app bundle:
    /Applications/MPlayer\ OSX\ Extended.app/Contents/Resources/Binaries/mpextended.mpBinaries/Contents/MacOS/mplayer
    
  • MPlayer UNKNOWN-4.2.1 (C) 2000-2014 MPlayer Team from macport's mplayer-devel @37268_0
  • MPlayer 1.1-4.2.1 (C) 2000-2012 MPlayer Team from macport's MPlayer @1.1_8 (except that in this older build, the -fs flag has the same effect as hitting the interactive keyboard control for Toggle fullscreen)

I am sorry I have failed at building mplayer from the latest SVN. However, seeing as several versions of mplayer are equally affected, it seems likely that this is really a problem in the mplayer core, and not in some particular build of macports or MPlayer OSX Extended.app.

Ultimately, this bug is probably caused by a change in the handling of fullscreen apps that must have been introduced with Yosemite. There were no such issues with mplayer in previous versions of Mac OS X. Other players such as MPlayer OSX Extended.app (in normal GUI mode) or VLC handle Yosemite fullscreen mode just fine, but of course, they lack the CLI power of proper mplayer.

Attachments (5)

toggle_fullscreen.png (668.9 KB) - added by machsna 3 years ago.
mplayer after hitting f for toggle fullscreen, menubar is cropped, the file is https://commons.wikimedia.org/wiki/File:His_Majesty,_the_Scarecrow_of_Oz_%281914%29.webm ca. 00:00:20
fs_flag.2.png (667.3 KB) - added by machsna 3 years ago.
mplayer with -fs flag, menubar and Dock areas are not covered, the file is https://commons.wikimedia.org/wiki/File:His_Majesty,_the_Scarecrow_of_Oz_%281914%29.webm ca. 00:00:20
fs_flag.png (667.3 KB) - added by machsna 3 years ago.
mplayer with -fs flag, menubar and Dock areas are not covered, the file is https://commons.wikimedia.org/wiki/File:His_Majesty,_the_Scarecrow_of_Oz_%281914%29.webm ca. 00:00:20
mplayer-verbose.txt (6.8 KB) - added by Vorb 3 years ago.
Verbose output
beastd-mplayer-vo-gl-sdl2-hack.diff (10.8 KB) - added by beastd 21 months ago.
SDL2 patch for use with vo gl

Download all attachments as: .zip

Change History (19)

Changed 3 years ago by machsna

mplayer after hitting f for toggle fullscreen, menubar is cropped, the file is https://commons.wikimedia.org/wiki/File:His_Majesty,_the_Scarecrow_of_Oz_%281914%29.webm ca. 00:00:20

Changed 3 years ago by machsna

mplayer with -fs flag, menubar and Dock areas are not covered, the file is https://commons.wikimedia.org/wiki/File:His_Majesty,_the_Scarecrow_of_Oz_%281914%29.webm ca. 00:00:20

Changed 3 years ago by machsna

mplayer with -fs flag, menubar and Dock areas are not covered, the file is https://commons.wikimedia.org/wiki/File:His_Majesty,_the_Scarecrow_of_Oz_%281914%29.webm ca. 00:00:20

comment:1 Changed 3 years ago by beastd

  • Status changed from new to open

Can you paste console output of MPlayer (mplayer -v) here?

Also it seems a bit strange no one else reported this yet.

Changed 3 years ago by Vorb

Verbose output

comment:2 follow-up: Changed 3 years ago by Vorb

I have the same issue on my Macbook Air 13 with Yosemite. Please find "mplayer-verbose.txt" attached to the ticket. Let me know if you need anything else.

Thanks

comment:3 Changed 3 years ago by reimar

Thanks for the effort in reporting the bug, however to my knowledge there are no active developers running that OSX version, so chances of getting a fix any time soon are quite low.
Especially since right now we have no idea at all what causes this.

comment:4 in reply to: ↑ 2 Changed 22 months ago by beastd

Replying to Vorb:

I have the same issue on my Macbook Air 13 with Yosemite. Please find "mplayer-verbose.txt" attached to the ticket. Let me know if you need anything else.

Sorry I do not use OSX and I could not find anything suspicious in the log you provided.

But I thought I might at least ask if you can still reproduce the annoying fullscreen behaviour?

comment:5 follow-up: Changed 22 months ago by machsna

Yes, the issue persists on OS X 10.11.

There is a workaround now: When you set the system not to display the menubar, and then start mplayer, and then hit f for entering fullscreen mode, mplayer displays all over the screen. However, if you start mplayer with the -fs flag, then it displays the window title bar, and you have to hit f twice so mplayer covers the entire screen (more or less like in the original report).

The only real workaround is using VLC instead of mplayer, even though it lacks a decent CLI.

comment:6 in reply to: ↑ 5 Changed 22 months ago by beastd

Replying to machsna:

Yes, the issue persists on OS X 10.11.

Can you check if other video output modules are available

mplayer -vo help

and test with e.g. gl or sdl or whatever else is available?

comment:7 Changed 22 months ago by machsna

The only output module that actually produces video output is corevideo. The other output modules are null and various modules that produce different kinds of files (mpegpes yuv4mpeg png jpeg tga pnm md5su).

comment:8 follow-up: Changed 22 months ago by machsna

I have rebuilt mplayer with more output modules (port -c install mplayer-devel +fribidi +glx +osd +sdl +x11). This gives the following additional video output modules, but it disables corevideo:

  • glx, xv, xover, gl_tiled produce no video output;
  • gl, gl_nosw, matrixview produce an output, but fail to deliver a picture (it is just an empty window), and in fullscreen the menubar area is transparent;
  • x11 produces an output with picture, but in fullscreen the menubar area is transparent (and the picture is not scaled up);
  • sdl works fine, but when it is in fullscreen it hijacks all keyboard and mouse input (not even alt-tab works or the trackpad swipes for switching between desktops or the dedicated key for "mission control").

comment:9 in reply to: ↑ 8 Changed 22 months ago by beastd

Thanks for testing.

Replying to machsna:

  • sdl works fine, but when it is in fullscreen it hijacks all keyboard and mouse input (not even alt-tab works or the trackpad swipes for switching between desktops or the dedicated key for "mission control").

Could you also test -vo gl:backend=2 and -vo gl:backend=4?

comment:10 follow-up: Changed 22 months ago by machsna

-vo gl:backend=2 behaves like -vo sdl. BTW, when the output is not in fullscreen, keyboard and trackpat input works as expected (e.g. alt+tab will open the application switcher, the dedicated mission control key or the assigned trackpat gesture will open mission control, etc. etc.). They only stop working when the output is in fullscreen.

-vo gl:backend=4 produces no video output, just like glx, xv, xover, gl_tiled. To be exact, they produce a featureless mplayer instance that you can alt-tab to, just like mplayer normally does (with the corevideo output module). However, no window ever appears, and you cannot click on the menu bar menues – if you try to do so, you just get the spinning beachball of death cursor. I think it indicates that the application is unresponsive. The terminal and the audio output, however, are perfectly responsible: You can skip forward etc., and there are no constant error messages such as appear with the corevideo output module (see https://trac.macports.org/ticket/48823 ). Instead, the error message is:

Error opening/initializing the selected video_out (-vo) device.

comment:11 in reply to: ↑ 10 Changed 22 months ago by beastd

First of all thanks for the continued testing.

Replying to machsna:

-vo gl:backend=2 behaves like -vo sdl. BTW, when the output is not in fullscreen, keyboard and trackpat input works as expected (e.g. alt+tab will open the application switcher, the dedicated mission control key or the assigned trackpat gesture will open mission control, etc. etc.). They only stop working when the output is in fullscreen.

I think SDL and probably OpenGL via SDL could work fine on OSX.

If I understand correctly the remaining problem is that SDL uses real fullscreen which bears the problems you described. (alt+tab switching not working etc.)

SDL2 should be able to avoid that problem by "emulating" fullscreen. Thus supporting SDL2 is what I will look into next. Not sure how difficult it is and if I will be able to make it this year. If anyone else wants to look into this please tell me so we can avoid duplicate work.

[...]

Changed 21 months ago by beastd

SDL2 patch for use with vo gl

comment:12 Changed 21 months ago by beastd

Replying to beastd:
[...]

If I understand correctly the remaining problem is that SDL uses real fullscreen which bears the problems you described. (alt+tab switching not working etc.)

SDL2 should be able to avoid that problem by "emulating" fullscreen. Thus supporting SDL2 is what I will look into next. Not sure how difficult it is and if I will be able to make it this year. If anyone else wants to look into this please tell me so we can avoid duplicate work.

I was able to come up with an experimental patch. I uploaded it here.

I would be grateful if anyone could test on OSX. It should be applied from the top of mplayer source directory (e.g. patch -p1 < beastd-mplayer-vo-gl-sdl2-hack.diff).

The patch will remove vo sdl from the build and you will have to test with -vo gl:backend=2 (the title of the window should read "SDL2").

It has some known and probably some unknown shortcomings:

  • fullscreen window disappears if i click something on another monitor (at least on Windows)
  • resize does not work as expected
  • it re-creates the video window at least once
  • no -wid support

But I believe at least for single screen (full screen) it should be nicer on OSX.

comment:13 Changed 10 months ago by Vorb

It worked for me, thank you. Mplayer is complaining about performance issues (on my latest macbook pro 2016 15 inches) but so far I didn't notice any lags, possibly that happens when the window is being expanded, in OSX it takes some time and is animated.
It would be great to get it fixed with corevideo driver if it's possible though.

Thanks!

comment:14 Changed 4 days ago by beastd

  • Analyzed by developer set
  • Component changed from core to vo
  • Reproduced by developer set
  • Resolution set to fixed
  • Status changed from open to closed

Should be fixed in SVN after commit r37959 by Reimar.

Please reopen if it is not.

Note: See TracTickets for help on using tickets.