Opened 10 years ago

Last modified 8 years ago

#2195 new defect

mplayer hangs with white screen

Reported by: jchauvel@… Owned by:
Priority: high Component: vo
Version: HEAD Severity: normal
Keywords: osx corevideo Cc: acho@…, jeremyhu@…, dscho
Blocked By: Blocking:
Reproduced by developer: no Analyzed by developer: no

Description

Summary of the bug:

When a video is played it shows a white screen and plays the first fraction of a second of the video's audio and then hangs.

I've installed mplayer on OS X (Mavericks) via macport's mplayer-devel package. The package is installed with the following variants:

mplayer-devel @36449_4+a52+aa+caca+dirac+dts+esd+fribidi+live+mencoder_extras+mng+noappleremote+nodvd+osd+sdl+smb+speex+x11

How to reproduce:

% mplayer -vo corevideo movie.mkv
MPlayer UNKNOWN-4.2.1 (C) 2000-2013 MPlayer Team
205 audio & 430 video codecs

Playing movie.mkv.
libavformat version 55.17.100 (internal)
libavformat file format detected.
[lavf] stream 0: video (h264), -vid 0
[lavf] stream 1: audio (ac3), -aid 0
VIDEO:  [H264]  1280x720  0bpp  23.976 fps    0.0 kbps ( 0.0 kbyte/s)
Clip info:
 creation_time: 2014-04-14 02:18:21
Load subtitles in ./
SUB: Added subtitle file (1): ./movie.srt
==========================================================================
Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
libavcodec version 55.31.101 (internal)
Selected video codec: [ffh264] vfm: ffmpeg (FFmpeg H.264)
==========================================================================
==========================================================================
Opening audio decoder: [ffmpeg] FFmpeg/libavcodec audio decoders
AUDIO: 48000 Hz, 2 ch, floatle, 384.0 kbit/12.50% (ratio: 48000->384000)
Selected audio codec: [ffac3] afm: ffmpeg (FFmpeg AC-3)
==========================================================================
AO: [coreaudio] 48000Hz 2ch floatle (4 bytes per sample)
Starting playback...
Could not find matching colorspace - retrying with -vf scale...
Opening video filter: [scale]
Movie-Aspect is undefined - no prescaling applied.
[swscaler @ 0x10db274b0]BICUBIC scaler, from yuv420p to yuyv422 using MMXEXT
VO: [corevideo] 1280x720 => 1280x720 Packed YUY2
[ASPECT] Warning: No suitable new res found!

Change History (3)

comment:1 by jchauvel@…, 10 years ago

it works now.

comment:2 by dscho, 10 years ago

I experienced the same. When debugging in gdb, I found that fontconfig was caching the font metrics. Once this is done, mplayer starts instantaneously (and you can trigger the font metrics caching beforehand with fc-cache I guess).

Would be nice if mplayer spat out a message when it has to cache font metrics. If I find enough time, I might give it a try and contribute a patch.

comment:3 by beastd, 8 years ago

Cc: dscho added
Severity: blockernormal

Sorry for looking into this only after such a long time. Is it still common to run into this problem? Or was it e.g. fixed through fontconfig macports package?

If this problem is because of fontconfig building its cache, it will be rather hard to fix or e.g. display a warning for.

As far as I understand it the caching in the fontconfig library is rather hidden as a detail of the internals of the library.

In a way it is not a problem that affects only MPlayer but all apps that use fontconfig. So not sure what we should do in MPlayer to deal with this. Though at least a hint for the user would be nice, OTOH if that means outputting another log message on almost all mplayer runs, I am not sure it is really better.

One could also consider forcing the fontconfig cache read/update at an earlier point in
time, so it does look less like a playback problem (video/audio is already starting to play and suddenly things hang for a long time).

Note: See TracTickets for help on using tickets.