Commit Graph

3844 Commits

Author SHA1 Message Date
wm4 0440460d0c vo_vdpau: implement screenshots 2011-11-25 23:56:28 +02:00
wm4 3041ee8d6c core: add screenshot mode for actual VO window contents
The screenshot command normally converts the currently displayed video
frame to an image. Add support for an alternative screenshot mode
that is supposed to capture the real window contents. Such a
screenshot contains a possibly scaled version of the frame, the OSD,
and subtitles.

Add a default key binding Alt+s for taking screenshots in this mode.

This needs special VO support, and might not work with all VOs (this
commit does not yet contain an implementation for any VO, only the
infrastructure).
2011-11-25 23:56:28 +02:00
wm4 01cf896a2f core: add infrastructure to get screenshots from VOs
Add a VO command (VOCTRL_SCREENSHOT) which requests a screenshot
directly from the VO. If VO support is available, screenshots will be
taken instantly (no more 1 or 2 frames delay). Taking screenshots when
hardware decoding is in use will also work (vdpau). Additionally, the
screenshots will now use the same colorspace as the video display.
Change the central MPContext to be allocated with talloc so that it
can be used as a talloc parent context.

This commit does not yet implement the functionality for any VO (added
in subsequent commits).

The old screenshot video filter is not needed anymore if VO support is
present, and in that case will not be used even if it is present in
the filter chain. If VO support is not available then the filter is
used like before. Note that the filter still has some of the old
problems, such as delaying the screenshot by at least 1 frame.
2011-11-25 23:56:28 +02:00
wm4 b200583403 vo_gl: fix crash with backends lacking control() features
Some functionality provided by the windowing backend (such as x11,
win32) is optional. The function pointers in MPGLContext are NULL if
the functionality is not implemented. Check them before calling them,
instead of crashing. This happened at least on Windows with the
"vo_ontop" command.
2011-10-24 08:36:17 +03:00
wm4 2123bff6fa vo_gl: remove support for nvidia register combiners (yuv=1)
The register combiner color conversion is broken and seems to use a
slightly incorrect color matrix (the image looks gray-ish). Completely
remove all code related to nVidia register combiners.

Unless you have an ancient nVidia GPU, there's no reason to prefer register
combiners over fragment shaders. Users with ancient GPUs without fragment
shader support can just use -vo xv.

Passing yuv=1 (register combiners) as sub option will print a warning and
use yuv=2 (fragment shaders) instead.
2011-10-24 08:36:17 +03:00
wm4 23fa8e9964 vo_gl: fix crash with ati-hack after 20256a8a64
Using the ati-hack and force-pbo suboptions (both can be enabled
automatically when particular ATI drivers are detected) could lead to
segfaults due to incorrect length calculation.

The problem is that width*((bpp+7)/8) == width*(bpp+7)/8 doesn't hold
true in general. The old code used bpp/8, because bpp was always
guaranteed to be divisible by 8. When commit 20256a8a64 fixed bugs
around 10 bit pixel formats, this assumption was broken, and resulted
in out of bounds memory accesses.

Additionally, the color values that were used to clear image borders
were incorrect and showed up as pink borders on the right/bottom sides
of the video when playing 10 bit content. Make the clear value
approximately correct; the borders are still filled with a single byte
value even though formats with 9-16 bits should be cleared with 2-byte
values with the low byte 0.

This commit also contains some other minor cleanups with no functional
changes.
2011-10-24 08:36:13 +03:00
wm4 64f44ad316 vo_gl: remove mesa-buffer suboption
This option enabled using Mesa specific functions, which have never been
widely supported, and were removed from Mesa in 2010.

http://cgit.freedesktop.org/mesa/mesa/commit/?id=cb2a66fd0c095fe03be5aaf88c8d48f5867425d3
2011-10-24 07:31:09 +03:00
wm4 c66dd9e1ca vo: sdl: handle key modifiers
Now modifiers such as shift, control, and alt are handled.

Unfortunately this requires a hack to deal with a SDL quirks when combining
CTRL and a letter key.

Also add some missing key syms.
2011-10-24 07:21:32 +03:00
wm4 3eeca4838d vo_gl: move window creation functions from vo_gl.c into gl_common.c
Now all windowing specific code is in gl_common.c.

init_mpglcontext() used to set dummy callbacks for non-optional windowing
callbacks. Remove these, as they only lead to confusion.
2011-10-24 07:19:29 +03:00
wm4 f045abb4c0 vo_gl/sdl: use desktop resolution for fullscreen mode
Before the SDL code would change screen resolution when switching to
fullscreen. Try to keep existing desktop resolution instead.
2011-10-24 06:18:29 +03:00
wm4 bb8781a00a vo_gl: add new vo name "gl_sdl" to make SDL+GL mode available
The actual work is done by the existing SDL code. This commit merely
makes it possible to explicitly select the SDL backend ("gl" alone
uses SDL only if the X11 and win32 backends are not available, while
the new "gl_sdl" always forces use of SDL).

Also disable YUV conversion method autodetection when SDL is used.
This gets rid of a temporary window that appears for a moment and is
immediately closed again. SDL can't deal with the VOFLAG_HIDDEN flag,
which is needed to create an invisible GL context (when the
autodetection is run, the video size isn't yet known to the VO, and
creating a window then resizing would cause problems with window
placement). Instead always pick the fragment program method by default
(yuv=2). This change affects the normal "gl" VO too if it chooses the
SDL backend.
2011-10-24 06:14:19 +03:00
wm4 98b89d4aa7 vo_gl: remove "noaspect" suboption
Apparently this is fully redundant given the global "noaspect" option.
Refuse this suboption, and output an error message suggesting the
correct option.
2011-10-24 06:14:19 +03:00
wm4 c852246cdf vo_gl: convert to new API, clean up code
Reformat vo_gl.c, gl_common.c, gl_common.h.
Remove all global variables and move them into a context struct (the
Windows and SDL backends still refer to global_vo though).
Change vo_gl.c to use the "new" VO API.
2011-10-24 06:13:17 +03:00
wm4 821a313ba1 vo_gl2, vo_matrixview: remove these VOs
Delete the vo_gl2 and vo_matrixview implementations.

vo_gl2 was barely useful anymore. It was a hack based on an old
vo_gl.c version, and all it did differently was rendering the video in
tiles instead of using a single texture. That made it work with some
crappy OpenGL implementations. These days all GPUs support textures of
at least 2048x2048 pixels, which is enough for HD playback. On the
other hand, gl2 suffered from various bugs and deficiencies, all of
which are fixed in gl. Its existence also confused users; many thought
that gl2 is the next version of gl and attempted to use it, even
though it's much worse than gl and they should have used that instead.

Should it turn out that tiling is actually useful, it should be
implemented in vo_gl, instead of keeping vo_gl2 alive.

vo_matrixview was a toy that couldn't even properly display a video.
All it did was display a screensaver-like animation that showed "a
Matrix-like running-text effect". (mplayer is not a screensaver.)
2011-10-24 03:08:48 +03:00
wm4 75eab4f72a video, options: implement better YUV->RGB conversion control
Rewrite control of the colorspace and input/output level parameters
used in YUV-RGB conversions, replacing VO-specific suboptions with new
common options and adding configuration support to more cases.

Add new option --colormatrix which selects the colorspace the original
video is assumed to have in YUV->RGB conversions. The default
behavior changes from assuming BT.601 to colorspace autoselection
between BT.601 and BT.709 using a simple heuristic based on video
size. Add new options --colormatrix-input-range and
--colormatrix-output-range which select input YUV and output RGB range.
Disable the previously existing VO-specific colorspace and level
conversion suboptions in vo_gl and vo_vdpau. Remove the
"yuv_colorspace" property and replace it with one named "colormatrix"
and semantics matching the new option. Add new properties matching the
options for level conversion.

Colorspace selection is currently supported by vo_gl, vo_vdpau, vo_xv
and vf_scale, and all can change it at runtime (previously only
vo_vdpau and vo_xv could). vo_vdpau now uses the same conversion
matrix generation as vo_gl instead of libvdpau functionality; the main
functional difference is that the "contrast" equalizer control behaves
somewhat differently (it scales the Y component around 1/2 instead of
around 0, so that contrast 0 makes the image gray rather than black).
vo_xv does not support level conversion. vf_scale supports range
setting for input, but always outputs full-range RGB.

The value of the slave properties is the policy setting used for
conversions. This means they can be set to any value regardless of
whether the current VO supports that value or whether there currently
even is any video. Possibly separate properties could be added to
query the conversion actually used at the moment, if any.

Because the colorspace and level settings are now set with a single
VF/VO control call, the return value of that is no longer used to
signal whether all the settings are actually supported. Instead code
should set all the details it can support, and ignore the rest. The
core will use GET_YUV_COLORSPACE to check which colorspace details
have been set and which not. In other words, the return value for
SET_YUV_COLORSPACE only signals whether any kind of YUV colorspace
conversion handling exists at all, and VOs have to take care to return
the actual state with GET_YUV_COLORSPACE instead.

To be changed in later commits: add missing option documentation.
2011-10-16 21:11:11 +03:00
wm4 20256a8a64 vo_gl: fix image corruption with PBOs when playing 10 bit video
vo_gl.c hardcoded the assumption that YUV formats always use 1 byte per
component. This corrupted the output when playing 10 bit h264 video.

Only the PBO code path was affected. PBOs are normally unused, unless ATI
is detected, or the force-pbo option is used.
2011-10-06 17:03:23 +03:00
Uoti Urpala b6628f4e1e csputils/vo_gl: rewrite YUV->RGB matrix generation
Rewrite the csputils.c code generating a conversion matrix for
YUV->RGB conversions (currently used by vo_gl only). Functional
differences:
- The separate "mplayer default" colorspace is removed, and BT.601 is
  used instead (the default colorspace was in fact BT.601; see below).
- The old code was missing chroma scaling. As a result the "mplayer
  default" colorspace actually mapped to BT.601, and everything else
  was buggy (I guess the other colorspaces were added with particular
  coefficient semantics, without understanding that the original
  "default colorspace" was actually BT.601 and why its coefficients
  differed from the added version).
- The old code had a bug in the equalizer hue equations.
- The old code assumed that for specifying whether input and output
  were limited-range or full-range YUV or RGB it would make sense to
  specify "no conversion" meaning full-range YUV to full-range RGB or
  limited-range YUV to limited-range RGB. This isn't true; limited-
  range YUV has different ranges for luma and chroma (16-235
  vs 16-240) which means you have to scale chroma for limited->limited
  conversions. The new code assumes limited->limited conversions for
  the levelconv parameter 2. It'd probably make sense to change the
  API later to specify the ranges of input and output separately.
- The undocumented EBU and XYZ colorspaces are removed. I doubt any
  videos use these. Also the EBU colorspace looks like it'd expect
  a different input range - at least no input would map to full RGB
  red as it was.
2011-08-29 06:34:36 +03:00
Uoti Urpala 1478f658f3 cosmetics: csputils.[ch]: reindent 2011-08-28 05:52:46 +03:00
harklu 8cc5ba5ab8 video_out.h: change VOCTRL_* defines to enum
Convert the list of VOCTLR_* defines to an enum, dropping some unused
values. This resolves a collision between VOCTRL_XOVERLAY_SET_COLORKEY
and VOCTRL_REDRAW_OSD, which had the same value (the XOVERLAY one was
only used by vo_xvr100 and vo_tdfx, so this didn't matter much in
practice).
2011-08-25 02:19:25 +03:00
Uoti Urpala e30416c997 vo_vpdau: fix preemption recovery broken in decec7f2a3
Commit decec7f2a3 ("vo_vdpau: skip resize code if not fully
initialized") broke preemption recovery because the resize code stayed
incorrectly disabled when it would have been used to reinitialize
things during recovery. Revert that commit and add different checks
to avoid running various code when not in a fully functional state.
2011-08-11 21:46:27 +03:00
Uoti Urpala 85f0577cd9 vo: X key input: remove ambiguous KeySym remapping
Code mapping X keyboard events to internal player key names remapped
the incoming KeySym values in a way that only kept information about
the lowest byte of the value and whether or not the value was below
256. This caused collisions between values. Remove this obviously
broken mapping and use the raw KeySym values instead. I'm not familiar
enough with X key handling to tell whether there was any valid
motivation whatsoever for the mapping, but the implementation was
certainly broken; if something else breaks it'll have to be fixed
later.
2011-07-29 08:46:50 +03:00
Uoti Urpala a4f4130819 cleanup: do libav* initialization on startup
Do the global initialization of libavcodec and libavformat
(avcodec_register_all(), av_register_all()) immediately on program
startup and remove the initialization calls from various individual
modules that use libavcodec/libavformat functionality.
2011-07-18 00:57:05 +03:00
Uoti Urpala decec7f2a3 vo_vdpau: skip resize code if not fully initialized
Window events or user commands could trigger a call to resize() before
config() had been called. This caused at least error messages. Add a
check to make resize() exit without doing anything in this case. It
will be called again later when the output is configured.
2011-07-17 17:05:42 +03:00
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
Uoti Urpala 8a37558c5f vo_directx: include <libavutil/common.h> for FFMIN
070491f102 added an use of FFMIN to
vo_directx.c but failed to include a header for the macro. Fix.
2011-07-07 22:58:34 +03:00
Uoti Urpala 2670ceeb81 Merge branch 'mplayer1_changes' 2011-07-06 13:07:37 +03:00
reimar 06d830687d cleanup: silence some clang warnings
Cosmetics: vo_mpegpes.c: Fix strange space placement

Avoids clang warning that =- might have been intended as -=.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33797 b3059339-0415-0410-9bf9-f77b7e298cf2

vo_jpeg: Use "const char *" type for paths.
Fixes a clang warning due to sign mismatch when calling open().

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33799 b3059339-0415-0410-9bf9-f77b7e298cf2

mga_template.c: Remove pointless and in addition incorrect cast.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33800 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-07-06 13:01:08 +03:00
reimar 950003b0c3 vo_gl: fix YUY2/YVYU colorspace mixup
Second GL_YCBCR_MESA format is YVYU, not YUY2.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33694 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-07-06 13:01:07 +03:00
reimar 9d8913dbf4 cleanup: vo_directx: remove redundant code
Simplify code for printing display adapter list.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33672 b3059339-0415-0410-9bf9-f77b7e298cf2

Remove left-over code from icon/cursor handling that is
now done by w32_common.c

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33673 b3059339-0415-0410-9bf9-f77b7e298cf2

Remove more code and variables that have no purpose anymore.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33674 b3059339-0415-0410-9bf9-f77b7e298cf2

Remove some #includes that are no longer needed.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33675 b3059339-0415-0410-9bf9-f77b7e298cf2

Remove more unnecessary code/defines.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33677 b3059339-0415-0410-9bf9-f77b7e298cf2

Move check_events function to avoid forward declaration.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33678 b3059339-0415-0410-9bf9-f77b7e298cf2

Remove more unused variables.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33679 b3059339-0415-0410-9bf9-f77b7e298cf2

Add const to avoid compiler warning.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33680 b3059339-0415-0410-9bf9-f77b7e298cf2

Use the proper type for the palette, fixes compiler warning.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33681 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-07-06 13:01:07 +03:00
reimar 070491f102 vo_directx: Change vo_directx to use w32_common.c
While I tested it quite thoroughly, with and without
-wid, -vm, -fs, ... it is _very_ likely to break
something, please report any regressions!
In the worst case it can still be reverted, however
since it has very little relevance nowadays it will
rot all the faster if not at least some code is shared.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33657 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-07-06 13:01:07 +03:00
reimar 1b6ae1ff58 VO: w32_common: also generate VO_EVENT_MOVE
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33650 b3059339-0415-0410-9bf9-f77b7e298cf2

Generate VO_EVENT_MOVE also with -wid.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33656 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-07-06 13:01:07 +03:00
diego d6e34fe91a VO: support Pause/Break key in X11 input
Allow Pause/Break key to be bound as MPlayer input key under X11.
patch by Steaphan Greene, sgreene cs.binghamton edu

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33609 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-07-06 13:01:07 +03:00
iive ab1544b74d cleanup: x11_common: remove pointless GC operations
Remove useless XSetBackground() call right before freeing the graphic
context.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33524 b3059339-0415-0410-9bf9-f77b7e298cf2

Create empty vo_gc graphic context instead of one with
undefined foreground color.

The code that uses vo_gc already employs XSetForeground()/XSetBackground()
to change the context accordingly.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33525 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-07-06 09:10:56 +03:00
iive 15513a77fb vo_xv: avoid setting background color due to resize flicker
Set background color only when using ck-method=background. In the
other cases clearing of the non-video image area should be done
manually. Not drawing on the video image area prevents flickering
(visible when resizing).

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33522 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-07-06 09:03:12 +03:00
Uoti Urpala 47ccb48ac9 vo: avoid losing initial expose event
The x11_common.c window creation code could lose the initial expose
event due to input mask changes. This meant that the window might
not be cleared at start (there's a vo_x11_clearwindow() call but it
may do nothing if it runs before the window is mapped). Modify the
code to avoid losing the expose event. Handling that event should
ensure the window is cleared and otherwise set up properly.
2011-07-06 08:42:57 +03:00
Uoti Urpala aeafa7a2b4 vo_xv: avoid clearing too much on resize
vo_xv set the "use_fs" parameter to vo_x11_clearwindow_part(). This
meant it always used the whole screen size to calculate the area to
clear. I can't see why overriding the vo->dwidth/dheight values would
ever be the right thing to do (if in fullscreen they should be set to
match that), so remove the use_fs parameter and always use the
dwidth/dheight values in the function. Also delete code drawing back
borders in vo_xv_draw colorkey. That should already happen in
vo_x11_clearwindow_part(); if it doesn't then things need to be fixed
anyway because colorkey code only ran in fullscreen mode (but borders
must work in window mode too).
2011-07-06 08:36:46 +03:00
reimar 48fdd3d926 vo_gl: Support 9- and 10-bit YUV input for OpenGL VOs
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33502 b3059339-0415-0410-9bf9-f77b7e298cf2

Fix clear/border color of chroma texture for 9- and 10-bit formats.
Avoids pink borders for those formats.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33504 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-07-06 07:31:54 +03:00
diego 94d3e6a710 cleanup: vo_direct3d: Mark a function static
This fixes the warning:
libvo/vo_direct3d.c:984:6: warning: no previous prototype for 'vo_draw_alpha_l8a8'

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33499 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-07-06 07:24:52 +03:00
Uoti Urpala befed529bc debug output: reduce verbosity of some frequent messages
Drop from frequent (per-frame) messages from DBG2 to DBG3. Drop VDPAU
clock adjustment messages from V to DBG2.
2011-07-05 00:50:41 +03:00
Uoti Urpala c8e78a0383 VO: silence "[ASPECT] Warning: No suitable new res found!"
The warning "[ASPECT] Warning: No suitable new res found!" was printed
from aspect() if the video ended up being downscaled from the original
size AND the horizontal direction was the more limiting one for
aspect-aware scaling. Also, because aspect() can run multiple times
when starting playback this warning could be output multiple times.
Change the code so that downscaling alone no longer triggers this
message.
2011-07-05 00:38:34 +03:00
Uoti Urpala 677e78f278 VO: clean up aspect.c, remove aspecttest tool
Clean up aspect.c code and simplify it somewhat (without changing the
overall logic). Replace debug output printf calls under #ifdef with
mp_msg() debug output (somewhat modified).

Remove the file aspecttest.c which created a binary to test aspect.c
functionality. It did not compile and would not be particularly useful
anyway. Remove some support lines from aspect.c and Makefile.
2011-07-05 00:30:13 +03:00
Uoti Urpala 48891debe2 cleanup: mark some vo_directfb2.c and vo_s3fb.c functions static 2011-06-29 11:43:19 +03:00
reimar 2c7488fe91 vo_gl: Request GL_LUMINANCE16 for 16-bit YUV input
Request GL_LUMINANCE16 as internal format for > 8 bit YUV formats.
Have yet to find a system that actually provides that though.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33453 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-06-29 10:49:52 +03:00
reimar 57f48fc1bf vo_gl: don't accept 9/10-bit formats as input
Make mp_get_chroma_shift() simpler/more generic and add an argument
to get the per-component bit depth.
Use this to check more properly for supported formats in
gl and gl2 vos (only 8 and 16 bit are supported, 9 and 10 are not).

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33452 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-06-29 10:49:41 +03:00
reimar 00ffdc0da6 cleanup: some warning fixes and minor cleanups
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33399 b3059339-0415-0410-9bf9-f77b7e298cf2

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33400 b3059339-0415-0410-9bf9-f77b7e298cf2

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33421 b3059339-0415-0410-9bf9-f77b7e298cf2

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33425 b3059339-0415-0410-9bf9-f77b7e298cf2

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33426 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-06-29 09:17:19 +03:00
Rudolf Polzer 84d86719fc Windows: vo/input: handle WM_XBUTTONDOWN message
WM_XBUTTONDOWN is used for extra mouse buttons (mapped to button 5 and
button 6 in mplayer2). Previously only vo_directx handled this
message.  Add support to w32_common.c event handling too (used by
vo_direct3d and vo_gl/vo_gl2 on Windows).
2011-06-19 04:05:36 +03:00
Uoti Urpala cbdb7e6305 vo_xvmc: drop XvMC support
Due to libavcodec changes vo_xvmc would have needed some modifications
to keep working. However, I think there's little real demand for XvMC,
so I'll just drop XvMC support. XvMC only supported MPEG-2, making it
of very limited usefulness nowadays, plus the vo_xvmc implementation
was not high quality and never worked particularly well or reliably
anyway.
2011-05-09 20:27:16 +03:00
Clément Bœsch b68f9fef32 cleanup: shut up more warnings 2011-05-06 18:33:16 +03:00
Clément Bœsch e699250908 vo_svga: fix build after previous commit 6506d4ad
vo_svga.c used its static query_format() function before defining it,
but had no prototype before the use. Thus is depended on the otherwise
useless static declaration in a shared header, and broke after that
was removed. Fix by adding an advance declaration inside the file.
2011-05-03 12:21:59 +03:00
Clément Bœsch 6506d4ad84 cleanup: remove more warnings 2011-05-02 00:46:48 +03:00
Uoti Urpala 7e65428712 Merge branch 'mplayer1_changes' 2011-05-02 00:46:03 +03:00
Uoti Urpala 23cb829072 input: move all key code lists to input/keycodes.h
Move the definitions of all special key codes (those not passed by
ASCII value) to input/keycodes.h. Before they were spread between
osdep/keycodes.h, input/joystick.h, input/mouse.h and input/ar.h, plus
some special values in input.h. This was especially inconvenient as
the codes had to be coordinated to not conflict between the files.

The change requires a bit of ugliness as appleir.c includes
<linux/input.h> which contains various conflicting KEY_* definitions.
Work around this by adding a special preprocessor variable which can
be used to avoid defining these in keycodes.h.
2011-05-02 00:43:31 +03:00
reimar 95d40b3f8d cleanup: vo_fbdev: simplify some code
Simplify by using FFMAX3.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33300 b3059339-0415-0410-9bf9-f77b7e298cf2

Simplify colormap generation code, avoid some mallocs and add frees
for one error case.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33302 b3059339-0415-0410-9bf9-f77b7e298cf2

Use memcpy_pic instead of reimplementing it.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33303 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-05-02 00:36:20 +03:00
reimar 8c831a2e86 vo_fbdev: clip x/y offsets to avoid bad video placement
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33299 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-05-02 00:36:20 +03:00
reimar 8924d2c27d vo_fbdev: Add -geometry support reusing common code
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33298 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-05-02 00:36:20 +03:00
reimar 57f700d19c vo_fbdev: add RGB framebuffer support
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33289 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-05-02 00:36:20 +03:00
Clément Bœsch 699bf9dcd3 vo_dga: replace xf86dga.h with Xxf86dga.h
xf86dga.h is deprecated and may be removed in the future.
2011-04-20 04:22:53 +03:00
Clément Bœsch 52743acba3 cleanup: avoid various GCC warnings 2011-04-20 04:22:53 +03:00
reimar c246c09b03 vo_gl: fix "gamma" equalizer setting
The "gamma" setting only changed red gamma. Fix it to change all of
red, green and blue gamma.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32895 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-04-12 18:41:26 +03:00
Uoti Urpala ca5399d04f VO: don't wait for map event in X VO initialization
After creating a video window the common X code waited for a MapNotify
event before proceeding. This meant that if the window was opened on
another workspace the player would be stuck until the user switched to
that workspace and the window could become actually visible. Remove
this waiting code. I don't know why it was there or if it was actually
beneficial/needed for some setup (at least common uses seem to work
fine without it); it comes from the earliest MPlayer versions visible
in VCS history.
2011-04-08 02:30:13 +03:00
Uoti Urpala 16e29bebf0 vo_mga, build: change include from "libavcore" to "libavutil"
Libavcore was merged back to libavutil. Change the mga_template.c
include of libavcore/imgutils.h to match. This means that split
libavcore/libavutil versions won't work any more; but since this only
affects people who enable vo_mga and there was no released version
using the split libs I won't bother with any conditionals for the
include.
2011-03-28 04:13:40 +03:00
Stefano Pigozzi b10b2b5b2c vo_corevideo: add key_modifier_alt only when pressing left option key 2011-03-18 21:59:38 +02:00
Stefano Pigozzi e94a9076dc vo_corevideo: fix menubar showing 2 apples on snow leopard 2011-03-11 20:32:57 +02:00
Stefano Pigozzi cf664986ae vo_corevideo: support modifier keys in keyboard input 2011-03-03 13:27:30 +02:00
Uoti Urpala afef26425d core: hr-seek: fix soft hang with hrseek past EOF
When doing a precise seek video_out->frame_loaded was left to true
while frames were being skipped. However vo_get_buffered_frame()
always returns success if a frame is already loaded; due to this the
EOF detection in update_video() never triggered, and a hr-seek past
EOF could cause a soft hang (commands were still processed and it was
possible to seek again to exit the loop). This could also happen with
Matroska files using ordered chapters if an underlying file was
actually shorter than the chapter that was supposed to come from it.
Then seeking to a timestamp after the end of the file but before the
end of the chapter would trigger the bug.

Fix the problem by setting frame_loaded to false when we decide to
skip the frame in question.
2011-03-03 12:54:36 +02:00
Uoti Urpala 106c5f9989 x11_common: fix for reconfig with pos/xineramascreen set
vo_x11_create_vo_window() only called vo_x11_update_geometry() if no
window position had been specified by -geometry or -xineramascreen, to
avoid overwriting the specified position with values from the existing
window. However window size should be initialized to the existing
window here, and setting new window title for -use-filename-title is
also done in vo_x11_update_geometry() (for whatever reason, it doesn't
match what else that function does). Change the code in
vo_x11_create_vo_window() to always call vo_x11_update_geometry() for
size variable and window title updates, but add a flag that tells it
not to update position variables.
2011-02-03 21:49:12 +02:00
Uoti Urpala 626d5ed628 vo_zr2: drop Zoran support
There were multiple files specific to Zoran support, and they also
depended on internal FFmpeg headers (so it would probably have been
hard to get them to compile now even if you tried). It's obsolete now,
so just drop the whole mess.
2011-01-31 16:03:11 +02:00
Uoti Urpala b138ca43ca vo_dxr2, ao_dxr2: drop dxr2 support
dxr2 support had been broken quite a while and nobody noticed. There
were finally commits to fix it in the svn repo, but rather than apply
those I'll just drop dxr2 support.
2011-01-31 16:03:10 +02:00
Uoti Urpala 6d534cd3cb vidix: drop VIDIX support
By now VIDIX is too obscure to justify the amount of code and
complexity it requires in the sources. Although there is no pressing
need to drop it just now from a code point of view, I'll rather remove
it before release than release with VIDIX support and then drop it
later.

Some of the manpage mentions of VIDIX were in "this option supported
for these VOs" lists that looked outdated and failed to mention vdpau
for example. Replace such incorrect lists with a generic "not
supported for all VOs" mention.
2011-01-31 16:03:10 +02:00
cboesch 303865cb81 cleanup: vo_md5sum: Remove unused define/undef
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32786 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-01-31 16:03:10 +02:00
reimar 7c8cb100af vo_gl: mark llvmpipe as a software renderer
llvmpipe, while only slow instead of insanely slow, is a software
renderer. Recognize it as such and disable -vo gl_nosw on it.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32719 b3059339-0415-0410-9bf9-f77b7e298cf2
2011-01-29 02:48:58 +02:00
Uoti Urpala c9026cb321 sub/OSD: move some related files to sub/ 2011-01-26 20:39:05 +02:00
Uoti Urpala 966340b31a subs: use correct font aspect ratio for libass + converted subs
Rendering of ASS subtitles tries to be bug compatible with VSFilter
and stretches fonts when the video is anamorphic (some scripts try to
compensate for this VSFilter behavior, so trying to render them
"correctly" would give the wrong result). However this behavior is not
appropriate for subtitles we converted to ASS format ourselves for
libass rendering, as they certainly don't have VSFilter bug
workarounds. Change the code to use different behavior for "native"
ASS tracks and converted ones. It's questionable whether the
VSFilter-compatible behavior is appropriate for external .ass files
either, as there could be anamorphic and non-anamorphic versions of
the same video and the bug-compatible behavior can only be correct for
one alternative at most. However it's probably better to keep it as a
default at least, so that extracting a muxed subtitle track and using
that does not give behavior different from the original muxed one.

The aspect ratio setting is per ASS_Renderer, and changing it resets
libass caches. For that reason this commit adds separate renderer
instances to use for the "correct" and "VSFilter bug compatible"
cases.
2011-01-26 20:38:53 +02:00
Uoti Urpala 8612c771fc cleanup: some random minor code simplification and cleanup 2011-01-26 13:04:17 +02:00
Uoti Urpala e9022ec470 cleanup: move MP_NOPTS_VALUE definition to mpcommon.h 2011-01-15 18:45:43 +02:00
Uoti Urpala adedee4285 subtitles: move global ass_track to struct osd_state 2011-01-15 18:45:43 +02:00
Uoti Urpala a1692437d0 core: move global "subdata" and "vo_sub_last" to mpctx 2011-01-11 17:55:05 +02:00
Uoti Urpala 30445e2fa4 vo_vdpau: allow "deint=-N" to specify mode without enabling deint
Allow negative values of the "deint" parameter and make them select
the same deinterlacing mode as the corresponding positive value, but
without enabling deinterlace on startup. This is useful for
configuration files. Also tweak the overall manpage description of
vo_vdpau a bit to make it sound less as if the VO would be for
hardware acceleration only.
2011-01-04 23:51:31 +02:00
Uoti Urpala 0afb326035 Merge branch 'hr-seek'
* hr-seek:
  input: add default keybindings Shift+[arrow] for small exact seeks
  input: support bindings with modifier keys for X input
  core: audio: make ogg missing audio timing workaround more complex
  core: add support for precise non-keyframe-limited seeks
  core: add struct for queued seek info
  commands: add generic option -> property wrapper
  options: add "choice" option type, use for -pts-association-mode
  core: remove looping in update_video(), modify command handling a bit
  core: seek: use accurate seek mode with audio-only files
  core: avoid using sh_video->pts as "current pts"
  libvo: register X11 connection fd in input event system
  core: timing: add special handling of long frame intervals
  core: move central play loop to a separate function

Conflicts:
	DOCS/tech/slave.txt
2010-12-20 19:17:43 +02:00
Uoti Urpala 67fd58d6f0 input: support bindings with modifier keys for X input
Add support for binding commands to modifier+key combinations like
"Shift+Left" or "Ctrl+Alt+x", and support reading such combinations
from the output window of X VOs.

The recognized modifier names are Shift, Ctrl, Alt and Meta. Any
combination of those and then a non-modifier key name, separated by
'+', is accepted as a key name in input.conf. For non-special keys
that produce characters shift is ignored as a modifier. For example
"A" is handled as a key without modifiers even if you use shift to
write the capital letter; 'a' vs 'A' already distinguishes the
combinations with a normal keymap, and having separate 'a', 'Shift+A'
and 'A' (written with caps lock for example) would bring more
confusion than benefit.

Currently reading the modifier+key combinations is only supported in
the output window of those VOs that use x11_common.c event
handling. It's not possible to input the key combinations in other VOs
or in a terminal window.
2010-12-20 19:02:24 +02:00
Uoti Urpala 4a26b4c024 cosmetics: remove unused code, small formatting tweaks 2010-12-20 06:42:04 +02:00
komh 1eb15a1304 font_load_ft.c: disable -fontconfig if compiled without libfontconfig
Set the option value to disabled, not enabled, if the functionality is
not available at all. Without this, -font and -subfont do not work
when using -ass.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32636 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-12-16 04:15:13 +02:00
Uoti Urpala 4f610adfc2 libvo: register X11 connection fd in input event system
Register the X11 connection fd in the input system so that
mp_input_get_cmd() can immediately wake up and handle keyboard or
other X events. The callback calls vo_check_events() and tells the
input system to handle any input possibly recorded during that. Before
this was done for vo_xv only; this commit generalizes it to all VOs
that call vo_x11_create_vo_window() - those are hopefully ones that
will handle all X events in check_events().

The callback is only kept registered while the vo is properly
configured. At other times calling check_events() would not clear
pending input and so could lead to a busy loop.
2010-12-14 22:33:12 +02:00
Uoti Urpala 387326e54b vo_vdpau: remove wrong mp_image usage_count change (no visible effect)
The wrong variable was used as a function argument, and as a result
the code modified the usage_count field of non-refcounted mp_image
types. This error did not have any effect on visible behavior as no
code cares about the field value in the affected case.
2010-12-13 18:50:22 +02:00
cboesch fe3c4810e1 cleanup: remove NULL checks before free() all over the code
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32624 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-14 13:11:20 +02:00
reimar 111757c3f4 vo_gl: create stereo-capable window when using Quadbuffer 3D
Select a stereo pixel format for window when Quadbuffer OpenGL was
selected as 3D mode.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32620 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-14 12:32:00 +02:00
reimar 94f543d114 libvo/w32_common.c: Move setting of pixel format from init to config
This allows it to depend on flags etc.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32619 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-14 12:31:10 +02:00
reimar 00b2a5d7b2 libvo/w32_common.c: minor cleanup
Some indentation fixes.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32611 b3059339-0415-0410-9bf9-f77b7e298cf2

Simplify: Use early return instead of large if block.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32612 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-14 12:23:56 +02:00
diego 12d3e0df99 cleanup: don't check for NULL before free()
patch by Clément Bœsch, ubitux gmail com

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32598 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-08 18:05:12 +02:00
komh ffbc561f96 vo_kva: Restore all the attributes after changing aspect ratio
kvaSetup() resets all the attributes, so there is need to restore them.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32570 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-07 21:49:51 +02:00
komh 163ae34e96 vo_kva: Prevent a parent window from painting over ours in slave mode
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32569 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-07 21:49:10 +02:00
reimar 0142db087b vo_directx: Fix possible out-of-bounds access
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32568 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-07 21:48:37 +02:00
Clément Bœsch 952f9b85a7 options: move -name and -title to option struct 2010-11-04 05:54:12 +02:00
cigaes ce9fcc0730 vo_gl: Move the read_pnm function into a separate file
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32513 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:18:37 +02:00
reimar 2865993869 vo_gl: Extract code to read a pnm file into a separate function
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32479 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:18:09 +02:00
reimar 4590600a42 vo_dxr3: Fix validity checks before closing a file descriptor
-1 is invalid (and the initial value), 0 is not.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32467 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:18:09 +02:00
reimar 26108aa19a vo_dxr3: Fix indentation
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32466 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:18:09 +02:00
reimar 8fe2291c53 vo_mga: minor code cleanup
Spelling fix.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32459 b3059339-0415-0410-9bf9-f77b7e298cf2

Use FFALIGN macro.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32460 b3059339-0415-0410-9bf9-f77b7e298cf2

Spelling fix.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32461 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:18:09 +02:00
reimar 57300e6ec7 vo_xmga: Remove an unmotivated and pointless panscan_calc call
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32458 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:18:09 +02:00
reimar 41657da91e vo_xvidix: reconfigure also on window move
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32457 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:18:09 +02:00
reimar 79f6a2c868 vo_xmga: fix event handling
Fix xmga event handling: Reconfigure hardware on move and resize,
redraw colorkey on resize and expose.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32456 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:18:09 +02:00
reimar 69d173dfbb vo_xmga: Remove a useless MGA_VID_CONFIG ioctl
set_window already does this.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32455 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:18:09 +02:00
reimar fef7b17c34 x11_common: add VO_EVENT_MOVE
Add VO_EVENT_MOVE which is required for VOs that interact directly
with hardware like MGA and VIDIX.

Patch by Dirk Porezag [porezag yahoo com]

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32454 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:18:09 +02:00
reimar 107845e9db vo_mga: switch to newer screen dimension handling API
Switch (x)mga vo to new libvo API to reduce code duplication and improve
consistency between vos.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32453 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:18:09 +02:00
reimar deba9f3d2b aspect.c: use fallback if screen dimensions are not known
Add fallback values to aspect_save_screenres to avoid division by 0
if screen dimensions are not known.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32452 b3059339-0415-0410-9bf9-f77b7e298cf2

Fix handling of invalid values in aspect_save_screenres to not overwrite
valid values.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32481 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:18:09 +02:00
reimar db90a65d11 Remove remaining %lf printf conversions
Most cases are just code in comments.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32438 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:18:08 +02:00
diego 690bcb7b2c libvo: remove UNUSED() macros
Remove UNUSED macros used to shut up unused function parameter warnings.
The macros are duplicated all over libvo and serve no useful purpose
nowadays.  A better way to shut up the warnings is -Wno-unused-parameter.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32422 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:18:08 +02:00
diego efd24e30dd vesa_lvo.c: make functions static
Mark functs not used outside of the file as static, remove from header; fixes:
libvo/vesa_lvo.c:187: warning: no previous prototype for 'vlvo_draw_slice'
libvo/vesa_lvo.c:205: warning: no previous prototype for 'vlvo_draw_frame'
libvo/vesa_lvo.c:214: warning: no previous prototype for 'vlvo_flip_page'
libvo/vesa_lvo.c:275: warning: no previous prototype for 'vlvo_draw_osd'
libvo/vesa_lvo.c:312: warning: no previous prototype for 'vlvo_query_info'

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32288 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:16:56 +02:00
diego 14c22f8236 vesa_lvo.c: Move vlvo_preinit() below the functions that it uses
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32287 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:16:55 +02:00
diego 03e539f38c vo_vesa: Mark vlvo_draw_slice_420() as static
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32286 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:16:55 +02:00
diego c310e7cedc vo_vesa: mark a function static
Mark fillMultiBuffer() as static, it is not used outside of the file; fixes:
libvo/vo_vesa.c:532: warning: no previous prototype for 'fillMultiBuffer'

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32284 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:16:55 +02:00
diego 21ea779e7a vo_vesa, vo_directfb2: Replace local min/max macros by FFMIN/FFMAX
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32282 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:16:55 +02:00
ramiro 32013b621c vo_mga: use libswscale interface for g200 (untested)
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32280 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:16:55 +02:00
diego 7452eb2948 vo_caca: Update URL to patch for new API support
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32260 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:16:55 +02:00
diego 868fb5d278 build: update DirectFB requirements, reduce #ifdefs
Require DirectFB version 0.9.15 instead of 0.9.13.
This simplifies the build system at the cost of requiring a library
version that was released at the end rather than the middle of 2002.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32251 b3059339-0415-0410-9bf9-f77b7e298cf2

Simplify DirectFB check.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32252 b3059339-0415-0410-9bf9-f77b7e298cf2

Require DirectFB version 0.9.22.
This allows getting rid of a lot of library version check #ifdeffery.
Release 0.9.22 is from February 2005, so the requirement is reasonable.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32253 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:16:55 +02:00
Uoti Urpala c5e462b33d build: enable/disable all FFmpeg libraries together
Enable all of libavcodec, libavformat, libswscale, and libpostproc
together (libavutil is always required).

based on svn commit by diego:

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32226 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:16:55 +02:00
diego eb67fe1a34 vo_corevideo.h: Add standard multiple inclusion guards
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32210 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:16:46 +02:00
diego e02012a4af vo_ivtv; Move ivtv_fd extern variable declaration to vo_ivtv.h
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32159 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:16:46 +02:00
diego 816da6109a vo_v4l2: Move v4l2_fd extern declaration to vo_v4l2.h
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32158 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:16:46 +02:00
diego e0f8f99a19 ao_mpegpes,vo_mpegpes: Rename vo_mpegpes_fd2 variable to ao_mpegpes_fd
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32154 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:16:46 +02:00
ramiro fdce82091e mga: disable g200 support
g200 should use the swscale interface to convert to nv12. If anyone still uses
such a card and is willing to test, just let me know.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32111 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:16:45 +02:00
diego f2899d96ee Add central init_avcodec() to avoid duplicated libavcodec init code
Patch by Vlad Seryakov, vseryakov gmail com

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32043 b3059339-0415-0410-9bf9-f77b7e298cf2

Refactor more instances of avcodec_initialized handling into init_avcodec().
This is a leftover from the previous commit.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32044 b3059339-0415-0410-9bf9-f77b7e298cf2

Add missing #include for vd_ffmpeg.h; fixes the warning:
libmpcodecs/vf_zrmjpeg.c:472: warning: implicit declaration of function 'init_avcodec'

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32176 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:15:51 +02:00
siretart 2e6ff523dd spelling fixes
Found by the Debian QA tool 'lintian'

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31913 b3059339-0415-0410-9bf9-f77b7e298cf2

reintroduce typo in genres.h that was fixed fixed r31913 to match the id3v2 spec

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31920 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:15:03 +02:00
reimar 91565a3d77 vo_gl.c: Use early return instead of large if block
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31887 b3059339-0415-0410-9bf9-f77b7e298cf2

Reindent.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31888 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:15:01 +02:00
reimar 0edb9e62d0 vo_gl: Make OSD rendering code more readable
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31886 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:15:01 +02:00
reimar cc6428a72c vo_corevideo: Move variable into the only function it's used in
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31826 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:46 +02:00
reimar 2e6847a352 vo_corevideo: move mouse hiding to check_events
Move mouse hiding code to check_events, this allows mouse hiding
to continue to work with -idle -fixed-vo, after the video has
finished but the last frame is still displayed.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31825 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:46 +02:00
reimar 902417b999 vo_corevideo: Make the Quit menu entry work
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31824 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:46 +02:00
reimar 5a1689d894 vo_corevideo: simplify check_events
Simplify check_events: avoid seemingly pointless untilDate argument.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31823 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:46 +02:00
reimar d612a71f39 vo_corevideo: change window-closing handling
Change window-closing handling so it works properly if the
KEY_CLOSE_WIN is rebound to e.g. skip to next file or not
bound at all.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31822 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:46 +02:00
reimar 59524e7a3f vo_corevideo, vo_quartz: remove useless kQuitCmd
Remove kQuitCmd, it has no purpose or effect at all.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31811 b3059339-0415-0410-9bf9-f77b7e298cf2

Remove unused kQuitCmd from vo_quartz.
While just as useless as for corevideo, the "Quit"
menu item at least works through kHICommandQuit here.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31812 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:45 +02:00
reimar 79662b6f19 vo_corevideo: indentation fixes
Cosmetics: indentation fixes.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31808 b3059339-0415-0410-9bf9-f77b7e298cf2

Fix indentation.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31810 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:45 +02:00
reimar 465839a395 vo_corevideo: Avoid some code duplication.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31809 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:45 +02:00
reimar f4f8c1f7e9 vo_corevideo: Simplify update_screen_info
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31806 b3059339-0415-0410-9bf9-f77b7e298cf2

Avoid some code duplication in update_screen_info.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31807 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:45 +02:00
reimar 0a5ff5eef3 vo_corevideo: avoid dangerous casts
Declare variables with proper types to avoid dangerous pointer casts.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31805 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:45 +02:00
reimar 5f5a12a939 vo_corevideo.m: remote useless parentheses and casts
Remove useless ().

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31802 b3059339-0415-0410-9bf9-f77b7e298cf2

Remove yet more useless ()

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31803 b3059339-0415-0410-9bf9-f77b7e298cf2

Remove pointless casts.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31804 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:45 +02:00
reimar 2fa911a6f5 vo_corevideo: Send KEY_CLOSE_WIN instead of KEY_ESC for quit
Send KEY_CLOSE_WIN instead of KEY_ESC when the user requested
corevideo to quit, KEY_ESC might have been rebound to something else.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31801 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:45 +02:00
reimar f5ef880227 vo_gl2: Use identical code to -vo gl for -wid mode
Fixes the same bugs (no video, video at wrong location...).

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31750 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:45 +02:00
reimar ccb01cc877 vo_gl: Make it possible to select GL_NEAREST scaling
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31743 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:44 +02:00
reimar 93336619b2 vo_gl: add helper macros to build the yuv conversion type number
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31742 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:44 +02:00
reimar 7de77cdb11 gl_common.h: Add () around macro arguments.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31741 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:44 +02:00
reimar 4f15b55c9b vo_gl: Cosmetics: create luma texture first
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31740 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:44 +02:00
reimar 2c949a1c25 vo_tga: specify 15 bpp tga format endianness
15 bpp tga format is little endian.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31720 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:44 +02:00
reimar c2abfa3799 vo_tga: Use the proper imgfmt names
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31719 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:44 +02:00
reimar a7308d3546 vo_tag: fix RGB with alpha output on little-endian
Fix vo_tga RGB with alpha output on little-endian (blue and alpha were
swapped), and simplify by letting libswscale do everything, since it
nowadays supports alpha. This has the side-effect of actually
producing a useful alpha channel when one is encoded in the video.

Patch by Marton Balint [cus fazekas.hu]

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31718 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:44 +02:00
Uoti Urpala e73ff7ae70 vo_vdpau: fix indentation of some switch statements 2010-11-02 04:14:43 +02:00
Uoti Urpala 3acf2eb563 vo_vdpau: add extra check for unknown image format
Add a default case for unknown image format in create_vdp_decoder. I
think this condition shouldn't currently happen, but it's worth a
sanity check. Avoids a compiler warning about vdp_decoder_profile
being possibly used uninitialized.

Also remove an obsolete #ifdef (should always be true now).
2010-11-02 04:14:43 +02:00
Uoti Urpala 8115fedc97 vo_gl: remove unused label 2010-11-02 04:14:43 +02:00
Uoti Urpala 26bd101530 x11_common.h: remove some unused declarations 2010-11-02 04:14:43 +02:00
cehoyos b3c3a40c6e vo_gl: remove "broken" comment from quadbuffer stereo
Independent tests indicate that GLX_STEREO is working fine on
supported hardware.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31647 b3059339-0415-0410-9bf9-f77b7e298cf2

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31648 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:20 +02:00
reimar 4e151f79e9 vo_gl: Some small whitespace and {} cosmetics
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31639 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:20 +02:00
reimar 14d00a65e9 vo_gl: Try to get a quadbuffered visual for corresponding 3D mode
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31638 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:20 +02:00
reimar 42a8c42eb2 vo_gl: cleanup
Move declaration to where it is actually used.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31636 b3059339-0415-0410-9bf9-f77b7e298cf2

Use a more sensible variable name.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31637 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:20 +02:00
reimar ccb6675fbd vo_gl: Add initial stereo support
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31633 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:20 +02:00
reimar 61ed4c2945 x11_common: Get window dimensions also for -wid 0
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31623 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:20 +02:00
reimar efdce758ce x11_common.c: minor cleanup
Remove some commented-out code that has no purpose and is only confusing.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31620 b3059339-0415-0410-9bf9-f77b7e298cf2

Remove useless ()

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31621 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:14:20 +02:00
reimar 4fc7f3b296 x11_common.c: Some indentation fixes
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31602 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:13:00 +02:00
reimar 1e159f4ecc x11_common: Do not try to grab input from -wid windows
It will most likely break their input processing.
If someone needs the previous behaviour, an option could be added (and
also used in the w32_common.c code).

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31601 b3059339-0415-0410-9bf9-f77b7e298cf2

Fix resizing with -wid after previous commit.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31604 b3059339-0415-0410-9bf9-f77b7e298cf2

Always request expose events, we have to handle them, the application
that created the -wid window can't.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31605 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:13:00 +02:00
reimar 30d7c19b69 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
2010-11-02 04:13:00 +02:00
diego 776c0f93f5 vo_mga: Rename libvo/mga_common.c --> libvo/mga_template.c
This file is not compiled but just #included and all other similar files
follow the naming scheme of having a "_template.c" suffix.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31430 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:10:26 +02:00
reimar c107c484b6 vo_gl: More sensible behaviour for -geometry with -wid
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31428 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:10:24 +02:00
diego ebbf5fb7a2 cosmetics: Remove some unused lines
Remove some unused extern declarations.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31424 b3059339-0415-0410-9bf9-f77b7e298cf2

Remove an unused extern declaration.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31425 b3059339-0415-0410-9bf9-f77b7e298cf2

Remove commented-out forward declaration for removed function.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31429 b3059339-0415-0410-9bf9-f77b7e298cf2

Remove unused extern fs_layer declaration.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31435 b3059339-0415-0410-9bf9-f77b7e298cf2

Remove unused 'extern int vo_osd_changed_flag' declaration.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31438 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:10:11 +02:00
reimar 82e546da0d x11_common: Consistently use "None" instead of "NULL" for X resources
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31422 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:10:10 +02:00
diego 49036138d0 ao_ivtv: Add header for ivtv_write() instead of forward declaring it
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31419 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:09:18 +02:00
reimar ba6c59ddc5 SDL input: add missing 0-termination of keymap file
Fixes bug #1711.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31384 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:07:42 +02:00
reimar be6a58d455 vo_gl, csputils: dual-license under LGPL v2.1
Dual-license gl_common and vo_gl under the LGPL v2.1 or later as
an alternative to the GPL license.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31375 b3059339-0415-0410-9bf9-f77b7e298cf2

Allow LGPL for csputils as well, they were previously part of gl_common
and are still an important part of it.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31376 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:07:42 +02:00
diego 9034d1b0ad libvo: Reduce verbosity of suboption parsing messages
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31353 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-11-02 04:07:28 +02:00
reimar 1a1e6e5a69 vo_gl: Remove nonsense commented-out function header
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31340 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-10-27 20:31:20 +03:00
Uoti Urpala 7a669a6407 vo: improve fixed-vo behavior when video size changes in x11 VOs
Now the window is only resized when video size (or size specified by
-geometry) changes; reconfiguring the window with the same size no
longer changes back to default size from possibly user-modified one.

Also fix a bug in fullscreen handling that could cause incorrect
window size when turning fullscreen off.
2010-07-23 03:38:40 +03:00
Uoti Urpala dde8b753e4 Merge svn changes r31318 to r31328
r31328 is a somewhat questionable (changing the option at that point
isn't quite safe), but it was a failure case already...
2010-06-05 23:35:42 +03:00
Uoti Urpala 9ce39d6807 Merge svn change r31315 2010-06-05 23:23:18 +03:00
reimar 5377f6a0c3 Remove colorspace conversion code from -vo yuv4mpeg, -vf scale should
be able to handle this just as well (or better) including interlaced.
If not, this needs to be fixed there instead of duplicating code.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31320 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-06-05 06:45:01 +00:00
reimar e22ebfddb1 Add support for -geometry x syntax since the documentation claims
it is supported.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31318 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-06-05 06:28:58 +00:00
reimar f0e84a0b23 Force window placement also if -xineramascreen was set >= 0,
not only if -geometry was given.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31315 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-06-04 17:10:38 +00:00
siretart 9e2e3a1cb8 apply missing bits from cd4e8dc1fa
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31314 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-06-03 21:50:08 +00:00
siretart d6d87593a7 vo_yuv4mpeg: disable RGB support when compiling against a shared libswscale
This avoids using swscale internals when compiling against a shared libswscale.

Patch inspired by Uoti Urpala's work in his git branch:
cd4e8dc1fa


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31310 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-06-03 17:37:58 +00:00
Uoti Urpala 80be936a56 Merge svn changes up to r31303 2010-06-02 19:12:01 +03:00
Uoti Urpala 497c32cdad Merge svn changes up to r31291 2010-06-02 18:55:18 +03:00
Uoti Urpala 5aa7c02984 Merge svn changes up to r31284 2010-06-02 17:59:10 +03:00
reimar 988b04eb2d Extend geometry parsing to reject all invalid strings.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31302 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-06-01 20:12:58 +00:00
reimar e629ec20bc Factor out some common code and ensure we will not try to draw OSD
elements outside the streams and thus crash.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31297 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-05-31 21:24:00 +00:00
reimar 233c74254e Change code to let Window Manager chose window location by default.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31289 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-05-30 19:14:18 +00:00
reimar 49c904b517 Treat a NULL renderer string as indication for software renderer.
Usually it means OpenGL will not work at all.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31284 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-05-30 13:51:24 +00:00
reimar f316f63910 Prefer -vo sdl over "probably software" OpenGL.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31283 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-05-30 13:50:14 +00:00
Uoti Urpala 8ce2c41ca5 Merge svn changes up to r31226 2010-05-30 16:25:04 +03:00
Uoti Urpala 2f1a518d45 Merge svn changes up to r31211
The merged cache2.c changes are known to have problems. Will merge
further fixes to them before merging this to the master branch.
2010-05-30 16:14:55 +03:00
Uoti Urpala e74361c488 Merge svn changes up to r31189 2010-05-30 15:51:33 +03:00
Uoti Urpala 6f199ab3d9 Merge svn changes up to r31169 2010-05-30 15:27:58 +03:00
Uoti Urpala 18657beb19 Merge svn changes up to r31145 2010-05-30 15:21:18 +03:00
Uoti Urpala 1888e57af7 cosmetics: "struct vf_instance* vf" -> "struct vf_instance *vf"
Change 'struct vf_instance' pointer arguments to more standard style
as in the subject. Also some other minor formatting fixes.

Patch by Diego Biurrun.
2010-05-29 17:20:44 +03:00
diego bce7550929 misc cosmetics: K&R style nits, #include placement, indentation
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31263 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-05-29 10:13:39 +00:00
Uoti Urpala 2e8ef70d4f vo_vdpau: fix loop initializing output surfaces as invalid
The loop initializing handles in the output surface table to
VDP_INVALID_HANDLE ran over indices from 0 to vc->num_output_surfaces.
However it is first called before that variable is initialized. As a
result later code could try to destroy the handles which still had the
"non-invalid" value 0. Most likely this caused no visible effects; at
least on my machine no valid surface gets handle 0, and libvdpau just
returns an error for the resulting invalid calls. Change the code to
loop over the whole table. Also add code to print visible warnings if
libvdpau rejects a surface destroy call (some other places already had
checks but not all).
2010-05-26 09:14:12 +03:00
diego 7bb3c3b681 Add missing RGB12 version of the fast OSD table.
patch by Janusz Krzysztofik, jkrzyszt tis.icnet pl


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31221 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-05-26 00:47:22 +00:00
reimar 25cb4330c9 Change -vo md5sum to not interleave U and V lines when calculating
the MD5, thus making it match FFmpeg's -f framemd5.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31208 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-05-24 17:51:15 +00:00
reimar 3009c1eff4 Fix OpenGL autodetection to not leave values at -1.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31207 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-05-24 17:36:23 +00:00
reimar 7be96c3792 Do not return pointer to on-stack memory.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31184 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-05-19 17:58:17 +00:00
reimar d08822aaac Fix return value (it was missing completely).
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31183 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-05-19 17:55:39 +00:00
reimar f62044777b Handle -wid Window being closed for direct3d and gl vos on Windows.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31182 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-05-19 17:53:47 +00:00
reimar 5c74db3bf6 Quit MPlayer if we receive a DestroyNotify event.
This in particular avoids MPlayer continuing to play when
a frontend using -wid crashed.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31179 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-05-14 18:00:04 +00:00
Uoti Urpala 9e02b2db40 vo_vdpau: support queuing an arbitrary number of frames ahead
Make the number of output surfaces allocated by vo_vdpau configurable
and allow queuing multiple future frames with the VDPAU frame timing
functionality. There are two known issues that could be polished in
the future for particularly long queue time cases. First, toplevel
code should possibly wait for the queued changes to finish displaying
in some situations like switching files. Second, the VO can block
waiting for a surface to become available, and in the worst case this
wait can be almost as long as the maximum queuing time (potentially
causing audio underruns). However those issues are not high priority.
2010-05-14 05:55:09 +03:00
Uoti Urpala 67482de5a7 vo_vdpau: add option for studio level output
Add -vo vdpau suboption "studio" to produce output in RGB range
16-235. Man page description mostly taken from a patch by Lauri
Mylläri (but not code). Also slightly tweak the description of two
other suboptions on the man page.
2010-05-12 03:55:32 +03:00
astrange 9ac35085f5 Fix compilation with --disable-fastmemcpy on x86
The inverse of a && b isn't !a && !b.
Regression in r30728.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31154 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-05-11 09:23:31 +00:00
Uoti Urpala 0ae292fbcb vdpau: drop support for old versions
Since I dropped the hack to support older libvdpau versions (without
MPEG4 / hqscaling features) from the FFmpeg version used in the build
repo it's better to disable those libvdpau versions in MPlayer
too. Change the configure check to require a newer libvdpau version,
and drop compatibility code in vo_vdpau.c.
2010-05-11 04:07:31 +03:00
reimar a7eab84efa Default to rectangle=1 on Mesa DRI R200 drivers, much faster and less buggy.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31151 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-05-09 21:36:10 +00:00
reimar 89957c3f6a Minor code cleanup.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31150 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-05-09 21:29:21 +00:00
reimar c9123e5a2d yuv=5 supports brightness and contrast adjustment.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31149 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-05-09 21:25:38 +00:00
reimar 6f28f44c8c Handle chroma texture size becoming 0, e.g. due to bad rounding.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31143 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-05-09 00:16:46 +00:00
Uoti Urpala e1cd86076f Merge svn changes up to r31141 2010-05-07 22:13:35 +03:00
Uoti Urpala eee666c3b5 Merge svn changes up to r31133 2010-05-07 21:19:53 +03:00
Uoti Urpala 033e479bec Merge svn changes up to r31104 2010-05-07 21:02:42 +03:00
Uoti Urpala a817e69131 Merge svn changes up to r31100 2010-05-07 20:59:01 +03:00
cehoyos 02641f54ee Add support for 12-bit color mode on framebuffer devices.
Patch Janusz Krzysztofik, jkrzyszt A tis icnet pl 


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31139 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-05-06 10:18:25 +00:00
Uoti Urpala fa47d009b4 vo_vdpau.c cosmetics: add WRAP_ADD macro
The macro is meant to simplify the handling of some code dealing with
circular buffers.
2010-05-06 05:38:46 +03:00
reimar fa6239aea0 Also print OpenGL renderer string with vendor and version with -v
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31127 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-05-01 22:49:05 +00:00
reimar 9d3c096045 Avoid duplicating the GL/gl.h include.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31107 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-30 19:03:13 +00:00
reimar ce4d38385c 100l, open the customtex also in binary mode, not just the program.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31106 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-30 17:12:52 +00:00
reimar 46f3b7d263 Move variable declaration into the block where it is actually used.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31103 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-27 19:04:23 +00:00
diego f15a14c158 Add missing input.h #include, fixes the warnings:
libvo/video_out.c:461: warning: implicit declaration of function 'mp_input_queue_cmd'
libvo/video_out.c:461: warning: implicit declaration of function 'mp_input_parse_cmd'


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31101 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-27 15:17:49 +00:00
diego 04d20b550d Move "screen" variable declaration below the relevant #ifdef, fixes the warning:
libvo/x11_common.c:369: warning: unused variable 'screen'


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31100 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-27 15:16:42 +00:00
Uoti Urpala f38efd166e Merge svn changes up to r31097 2010-04-26 19:23:32 +03:00
Uoti Urpala 8df340271e Merge svn changes up to r31040 2010-04-26 18:38:11 +03:00
Uoti Urpala 7795726e0f Merge svn changes up to r31033 2010-04-26 18:25:34 +03:00
Uoti Urpala 837c48ddee Merge svn changes up to r31020 2010-04-26 18:06:00 +03:00
Uoti Urpala e913d6c5da Merge svn changes up to r31004 2010-04-26 17:55:05 +03:00
Uoti Urpala 4785c2617e Merge svn changes up to r30967 2010-04-26 17:42:20 +03:00
Uoti Urpala ff559b8e90 Merge svn changes up to r30907 2010-04-26 16:57:25 +03:00
Uoti Urpala b1372a4f56 cosmetics: mark sub.c:osd_update_ext() static 2010-04-25 22:57:49 +03:00
reimar 7da954855a Set vo_dwidth/vo_dheight for mouse movements work at least in windowed mode.
For fullscreen, vo_screenwidth/vo_screenheight have to be set correctly still.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31095 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 16:48:48 +00:00
reimar af7e76c80b Missing space after if.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31093 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 16:20:54 +00:00
reimar 3d2259d365 Support mouse movements in SDL.
Currently for some reason broken with -vo sdl.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31092 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 16:15:00 +00:00
reimar 14c018a80f Avoid duplicating mouse-movement command-generation code.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31091 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 16:13:57 +00:00
reimar 2f629d7969 Deduplicate enable_mouse_movements declaration.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31089 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 15:49:46 +00:00
reimar 07a9a495c8 Minor cosmetics.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31088 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 15:41:21 +00:00
reimar f189c8286a Add comment for endif.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31087 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 15:39:22 +00:00
reimar a9ff7793e3 Support for auto-selecting the OpenGL backend.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31086 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 10:53:01 +00:00
reimar 3a34dbc927 Add reinitialization support. Necessary for fullscreen on OSX.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31085 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 10:44:53 +00:00
reimar 4121ce1747 Handle SDL expose events with -vo gl.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31084 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 10:34:58 +00:00
reimar 63c3c67294 Missing space in error message.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31083 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 10:12:39 +00:00
reimar 2d8e13c4ea Simplify SDL key symbol mapping.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31082 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 10:09:01 +00:00
reimar b2d0096783 Use the proper define for translating the tab key.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31081 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 09:59:43 +00:00
reimar 12d11bbd3a Make uppercase characters and in general all ASCII characters work
properly with SDL.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31080 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 09:57:52 +00:00
reimar 9661a675e5 Share SDL initialization code.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31079 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 09:52:01 +00:00
reimar e0183c56b1 Remove unnecessary check.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31078 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 09:25:23 +00:00
reimar 25b9185f17 Fullscreen support for -vo gl using SDL.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31077 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 09:24:30 +00:00
reimar 8b8fd879ac Set SDL window title.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31076 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 08:40:28 +00:00
reimar a83117e972 Window resizing support for -vo gl with SDL backend.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31075 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 08:35:35 +00:00
reimar 7c2bef4bb5 Add sdl_common file and use it to share the input handling between -vo gl
with SDL backend and -vo sdl.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31074 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 08:17:23 +00:00
reimar 5cdca55005 Use SDL_GL_ProcAddress to work around conflicts between -lGL
and -framework OpenGL.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31073 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 07:32:42 +00:00
reimar 7fc3b782ea Update copyright and email address.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31072 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 06:52:13 +00:00
reimar 56af15374b Clarify that the GL_TEXT_FRAGMENT_SHADER_ATI bug workaround is for OSX,
and which versions are known good/known bad.


git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31071 b3059339-0415-0410-9bf9-f77b7e298cf2
2010-04-25 06:14:25 +00:00