Command line video player
Go to file
Uoti Urpala 82b8f89bae input: rework event reading and command queuing
Rework much of the logic related to reading from event sources and
queuing commands. The two biggest architecture changes are:
- The code buffering keycodes in mp_fifo.c is gone. Instead key input
  is now immediately fed to input.c and interpreted as commands, and
  then the commands are buffered instead.
- mp_input_get_cmd() now always tries to read every available event
  from every event source and convert them to (buffered) commands.
  Before it would only process new events until one new command became
  available.

Some relevant behavior changes:
- Before commands could be lost when stream code called
  mp_input_check_interrupt() which read commands (to see if they were
  of types that triggered aborts during slow IO tasks) and then threw
  them away. This was especially an issue if cache was enabled and slow
  to read. Fixed - now it's possible to check whether there are queued
  commands which will abort playback of the current file without
  throwing other commands away.
- mp_input_check_interrupt() now prints a message if it returns
  true. This is especially useful because the failures caused by
  aborted stream reads can trigger error messages from other code that
  was doing the read; the new message makes it more obvious what the
  cause of the subsequent error messages is.
- It's now possible to again avoid making stdin non-blocking (which
  caused some issues) without reintroducing extra latency. The change
  will be done in a subsequent commit.
- Event sources that do not support select() should now have somewhat
  lower latency in certain situations as they will be checked both
  before and after select()/sleep in input reading; before the sleep
  always happened first even if such sources already had queued
  input. Before the key fifo was also handled in this manner (first
  key triggered select, but if multiple were read then rest could be
  delayed; however in most cases this didn't add latency in practice
  as after central code started doing command handling it queried for
  further commands with a max sleep time of 0).
- Key fifo limiting is more accurate now: it now counts actual
  commands intead of keycodes, and all queued keys are read
  immediately from input devices so they can be counted correctly.
- Since keypresses are now interpreted immediately, commands which
  change keybindings will no longer affect following keypresses that
  have already been read before the command is executed. This should
  not be an issue in practice with current keybinding behavior.
2011-07-17 07:36:09 +03:00
DOCS manpage: improve vo_gl "stereo" suboption description 2011-07-06 13:01:08 +03:00
TOOLS
debian
drivers
etc codecs.conf: add yv16 raw fourcc 2011-07-06 13:01:08 +03:00
ffmpeg_files
input input: rework event reading and command queuing 2011-07-17 07:36:09 +03:00
libaf cleanup: silence most of the clang warnings 2011-07-09 04:23:24 +03:00
libao2 audio: move ready-for-ao data buffer from decoder to AO 2011-07-02 09:22:32 +03:00
libmenu commands: change property mechanism to use talloc strings 2011-07-03 20:04:21 +03:00
libmpcodecs img_format.h, vo_gl: fix IMGFMT_IS_YUVP16() definition 2011-07-14 01:19:07 +03:00
libmpdemux cleanup: silence most of the clang warnings 2011-07-09 04:23:24 +03:00
libvo input: rework event reading and command queuing 2011-07-17 07:36:09 +03:00
loader loader/module.c: Fix compilation with --disable-qtx 2011-07-06 13:01:08 +03:00
osdep
rpm
stream stream_bluray: switch to new libbluray API 2011-07-10 11:30:06 +03:00
sub cleanup: vobsub.c: simplify parsing 2011-07-06 13:01:07 +03:00
timeline
.gitignore
AUTHORS
Copyright
LICENSE
Makefile VO: clean up aspect.c, remove aspecttest tool 2011-07-05 00:30:13 +03:00
README
access_mpcontext.h
asxparser.c
asxparser.h
av_log.c
av_log.h
av_opts.c
av_opts.h
bstr.c
bstr.h
cfg-mplayer.h input: rework event reading and command queuing 2011-07-17 07:36:09 +03:00
codec-cfg.c build: Revert "codec-cfg.c: avoid including aviheader.h" 2011-07-07 07:38:24 +03:00
codec-cfg.h
command.c cleanup: remove some unnecessary input.[ch] typedefs 2011-07-16 21:32:37 +03:00
command.h
configure stream_bluray: switch to new libbluray API 2011-07-10 11:30:06 +03:00
cpudetect.c cpudetect.c: check OS SSE support only with runtime detection 2011-07-06 13:01:07 +03:00
cpudetect.h
cpuinfo.c
defaultopts.c input: rework event reading and command queuing 2011-07-17 07:36:09 +03:00
defaultopts.h
edl.c
edl.h
fmt-conversion.c video/colorspaces: add new 9/10-bit formats from libavcodec 2011-06-26 06:27:50 +03:00
fmt-conversion.h
m_config.c options: free option defaults when freeing config 2011-07-06 06:47:38 +03:00
m_config.h cleanup: reformat and clean up m_config.[ch] 2011-07-06 06:25:16 +03:00
m_option.c Merge branch 'mplayer1_changes' 2011-07-06 13:07:37 +03:00
m_option.h cleanup: silence most of the clang warnings 2011-07-09 04:23:24 +03:00
m_property.c commands: change property mechanism to use talloc strings 2011-07-03 20:04:21 +03:00
m_property.h
m_struct.c
m_struct.h
mangle.h
metadata.h
mixer.c
mixer.h
mp_core.h
mp_fifo.c input: rework event reading and command queuing 2011-07-17 07:36:09 +03:00
mp_fifo.h input: rework event reading and command queuing 2011-07-17 07:36:09 +03:00
mp_msg.c
mp_msg.h mp_msg: change mp_dbg() to inline function to check syntax 2011-06-29 09:51:49 +03:00
mp_osd.h
mpbswap.h
mpcommon.c
mpcommon.h
mplayer.c input: rework event reading and command queuing 2011-07-17 07:36:09 +03:00
mplayer.h
options.h input: rework event reading and command queuing 2011-07-17 07:36:09 +03:00
parser-cfg.c
parser-cfg.h
parser-mpcmd.c
parser-mpcmd.h
path.c cleanup: remove useless set_codec_path() function 2011-07-06 06:37:22 +03:00
path.h
playtree.c playtree: make some char * function arguments const 2011-07-06 13:01:07 +03:00
playtree.h playtree: make some char * function arguments const 2011-07-06 13:01:07 +03:00
playtreeparser.c playlist: Support "Length" option in .pls playlist files 2011-07-06 13:01:07 +03:00
playtreeparser.h
pnm_loader.c
pnm_loader.h
subopt-helper.c
subopt-helper.h
talloc.c
talloc.h build: add a hack to prevent name collision with libtalloc 2011-07-07 23:19:39 +03:00
version.sh

README

Compiling with full features requires development files for several
external libraries. Below is a list of some important requirements. For
more information see the output of './configure --help' for a list of options,
or look at the list of enabled and disabled features printed after running
'./configure'. If you think you have support for some feature installed
but configure fails to detect it, the file config.log may contain information
about the reasons for the failure.

Libraries specific to particular video output methods
(you'll want at least one of VDPAU, GL or Xv):
 - libvdpau (for VDPAU output, best choice for NVIDIA cards)
 - libGL (OpenGL output)
 - libXv (XVideo output)
general:
 - libasound   (ALSA audio output)
 - various general X development libraries
 - libfreetype
 - libfontconfig
 - libass
 - FFmpeg libraries (libavutil libavcodec libavformat libswscale libpostproc)

Most of the above libraries are available in suitable versions on normal
Linux distributions. However FFmpeg is an exception (distro versions may be
too old to work at all or work well). For that reason you may want to use
the separately available build wrapper that first compiles FFmpeg libraries
and libass, and then compiles the player statically linked against those.