1
mirror of https://github.com/mpv-player/mpv synced 2024-09-12 23:45:53 +02:00
Commit Graph

46698 Commits

Author SHA1 Message Date
Akemi
6bf0edc59c cocoa-cb: fix crash when no screen is available
instead of force unwrapping and chaining the optional vars in our
containsMouseLocation function, safely unwrap and guard the resulting
var.

Fixes #6062
2018-08-11 12:59:44 +02:00
Tom Yan
f2311ff514 audio/format: decouple af_fmt_is_planar from af_fmt_to_planar
so that af_fmt_to_planar (and hence af_fmt_from_planar) can just
return the input when it is not an interleaved (planar) format.
2018-08-11 11:56:27 +02:00
jaseg
cfecbac863 manpage: Correct show-text duration default value
duration is parsed as an integer, and the default value is used if ```-1``` is passed. Passing ```-``` as described here causes a parameter value error.
2018-08-05 23:02:01 +02:00
pavelxdd
759a6a259e manpage: fix --vf exclamation mark description
An exclamation mark disables the filter by default instead of
enabling it.
2018-08-05 23:01:45 +02:00
Tom Yan
93a57d4c8b ao_opensles: update interface-changes 2018-08-05 17:52:01 +02:00
Tom Yan
e1bd5288b7 ao_opensles: rework the heuristic of buffer/enqueue size setting
ao->device_buffer will only affect the enqueue size if the latter
is not specified. In other word, its intended purpose will solely
be setting/guarding the soft buffer size.

This guarantees that the soft buffer size will be consistent no
matter a specific enqueue size is set or not. (In the past it
would drop to the default of the generic audio-buffer option.)

opensles-frames-per-buffer has been renamed to opensles-frames-per
-enqueue, as it was never purposed to set the soft buffer size. It
will only make sure the size is never smaller than itself, just as
before.

opensles-buffer-size-in-ms is introduced to allow easy tuning of
the relative (i.e. in time) soft buffer size (and enqueue size,
unless the aforementioned option is set). As "device buffer" never
really made sense in this AO, this option OVERRIDES audio-buffer
whenever its value (including the default) is larger than 0.

Setting opensl-buffer-size-in-ms to 1 allows you to equate the soft
buffer size to the absolute enqueue size set with opensl-frames-per
-enqueue conveniently (unless it is less than 1ms).

When both are set to 0, audio-buffer will be the ultimate fallback.
If audio-buffer is also 0, the AO errors out.
2018-08-05 17:52:01 +02:00
Tom Yan
8baad91e7b ao_opensles: allow s32 and float output
OpenSLES (and its AudioTrack backend) in Android can take 32-bit
fixed and floating point input since Android L (API 21).
2018-08-05 17:51:45 +02:00
Tom Yan
4e91cb72ef audio/format: minor fix for af_fmt_from_planar
See af_fmt_to_planar.
2018-08-05 17:51:45 +02:00
Yclept Nemo
5532a3da1e stream_smb/stream_file: fix write_buffer
Functions `write` and `smbc_write` are given a diminishing buffer of
incorrect constant size. After partial writes, the code would do another
write of the full original length, failing to subtract the amount
already written.
2018-07-29 12:54:56 +03:00
Yclept Nemo
112b3fa922 stream_smb: locking to bypass libsmbclient issues
Thread-unsafe libsmbclient is likely to crash when used simultaneously
across threads. For example, by:

    mpv "smb://...mkv" --sub-file "smb://...srt"

Work around this by locking all calls to this library under a single
global mutex. This is a temporary solution. When the libsmbclient bug
[1] is fixed, switch to the code from branch [2] which uses a new api to
create per-thread smb contexts. Fixes [3].

[1] https://bugzilla.samba.org/show_bug.cgi?id=11413
[2] https://github.com/orbisvicis/mpv/tree/smbclient_threaded_api
[3] https://github.com/mpv-player/mpv/issues/5936
2018-07-29 12:54:56 +03:00
Jan Ekström
2d785f3ea3 ci: do bootstrap outside the docker container
This way the docker container in itself does no networking.

It seems like travis disabled network access from the actual docker
containers.
2018-07-29 12:07:43 +03:00
Daniel M. Capella
45beb7073a manpage: fixup mistaken show playlist/track-list shortcuts
This was mistaken in 496b13227b and
not noticed in review.
2018-07-23 01:31:41 +03:00
Martin Herkt
e2a616bab2
Update VERSION 2018-07-22 18:47:16 +02:00
Martin Herkt
ca73b609f6
Release 0.29.0 2018-07-22 18:46:25 +02:00
Stephen Hutchinson
08a6827b3d wscript_build: apply project-wide CFLAGS/LDFLAGS to mpv.com
mpv.com fails to build when cross-compiling with a multilib version
of GCC, because the -m32 flags aren't getting passed to the build
process for osdep/win32-console-wrapper.c or the link phase for
mpv.com itself.
2018-07-19 02:38:51 +03:00
Jan Ekström
2f7dc16995 build: if libdir is not set, set it to EXEC_PREFIX/lib
This way the behavior of default libdir stays consistent before and
after switching to gnu_dirs from waf itself.
2018-07-19 02:12:30 +03:00
Akemi
15a6d0028e build: bump waf to 2.0.9
Among other things, fixes compatibility with python 3.7.x.
2018-07-12 01:48:10 +03:00
Akemi
5e608fc4c8 build: utilize built-in gnu_dirs module for installation directories
This started breaking with newer (2.0.x) waf versions, and it was
noticed that a built-in waf module was providing very similar
functionality.

APPNAME definition was required to have `gnu_dirs`' PACKAGE
variable to be defined in order to have f.ex. documentation
installed to the correct directory.

Currently unused options added by `gnu_dirs` were removed to clean
up the output of the help command.

Effective changes to behavior:
- `gnu_dirs` will attempt to figure out if it needs to use lib64
  instead of lib within your installation prefix. If you would
  like it to not do that, set `--libdir` during configuration.
  The way it tries to figure lib/lib64 out is if there's a
  `/usr/lib64` and no `/usr/lib32`.
- `--incdir` is now `--includedir` as per standard `gnu_dirs`
  behavior.
2018-07-12 01:48:10 +03:00
Akemi
546f038ded build: explicitly delay adding of object files to linking
Before, `do_the_symbol_stuff` would implicitly come before
`handle_add_object`, which adds object files to the linking task.

With newer (2.0.x) versions of waf, the ordering seems to get more
optimized, and thus we have to declare that the function that creates
the linking task should come before the task that adds object files
to the task.
2018-07-12 01:46:20 +03:00
Anton Kindestam
351c083487 hwdec_vaegl: Fix VAAPI EGL interop used with gpu-context=drm
Add another parameter to mpv_opengl_drm_params to hold the FD to the
render node, so that the fd can be passed to hwdec_vaegl.

The render node is opened in context_drm_egl and inferred from the
primary device fd using drmGetRenderDeviceNameFromFd.
2018-07-09 02:33:35 +03:00
Anton Kindestam
7beee68f8d context_drm_egl: Fix CRTC setup and release code when using atomic
The previous code did not save enough information about the old state,
and could end up changing what plane the fbcon:s FB got attached to,
or in worse case causing a blank screen (observed in some multi-screen
setups on Sandy Bridge).

In addition refactor the handling of drmModeModeInfo property blobs to
not leak, as well as enable reuse of already created blobs.
2018-07-09 02:17:47 +03:00
Anton Kindestam
1298b9d201 context_drm_egl: Fix some memory leaks on error exit
Fix some memory leaks on error exit in crtc_setup_atomic and
crtc_release_atomic.
2018-07-09 02:17:47 +03:00
Jan Ekström
1a893e8257 gpu: prefer 16bit floating point FBO formats to 16bit integer ones
According to earlier discussions, this can improve visual quality.
This only changes the preferred order of the formats, not the
formats themselves.
2018-07-08 16:49:23 +03:00
Akemi
93ec08cc7f build: fix linking libmpv when swift features are build
this was caused by commit 2e7a4f7. the LAST_LINKFLAGS were not added to
the linking of libmpv and that caused a linking error. manually add the
link flags the same way it's done when linking mpv.

Fixes #5968
2018-07-08 14:39:04 +03:00
Jan Ekström
4bf9a78b36 wscript_build: fixup swift include parameter to point to source root
Fixes compilation of the swift components with
`--variant="random_string"`, in which case "." is not the source
directory.
2018-07-08 03:22:09 +03:00
Martin Herkt
c75f98e3ab
ci: add mingw64 targets 2018-07-05 21:33:03 +02:00
Martin Herkt
034b33d695
ci: switch to cirno.systems docker registry
Much faster build cycles and more consistent download bandwidth.
2018-07-05 21:32:12 +02:00
Martin Herkt
dee7cdfae7
ci: enable libsmbclient 2018-07-05 16:03:32 +02:00
Martin Herkt
861c10268d
ci: switch Travis env language to generic
This way it doesn’t override CC.
2018-06-25 23:30:22 +02:00
Martin Herkt
802f594a85
ci: add more build targets
Travis now builds with Clang and containers with git snapshots
of some dependencies.
2018-06-25 23:24:30 +02:00
Martin Herkt
7428272f93
ci: Use custom container for Travis builds
Temporary solution. For now, this builds using a container image
based on openSUSE Tumbleweed with the current FFmpeg release.
More containers will be added (at least with git snapshots of FFmpeg
and libass), and Travis will eventually be replaced with something
we have more control over.
2018-06-25 19:16:42 +02:00
Andreas Wennerberg
4a0fcdfbd8 TOOLS/autoload: Fixed broken "disabled" option
`--script-opts=autoload-disabled=yes` now
properly stops the script from running.
2018-06-23 13:23:07 +01:00
Nicolas F
4d1269d9db demux_mkv: add A_MLP to mkv_audio_tags
Fixes #5923
2018-06-22 21:17:26 +03:00
Martin Herkt
afe713c71c
build: add static libraries to libmpv.pc 2018-06-20 10:42:39 +02:00
Akemi
cd893626cb cocoa-cb: fix building with Swift 4.2
init is a reserved keyword and Swift 4.2 got a bit stricter about using
it. this could be fixed by adding apostrophes around init but makes the
code uglier. hence i just renamed init to initialized and for
consistency uninit to uninitialized.

Fixes #5899
2018-06-12 01:57:34 +03:00
Akemi
2e7a4f717c build: manually add standard library search paths for linking
this reverts commit a174566 since the actually reason for failing has
been found. the isysroot flag overwrites the framework and library
search paths. though we only need to overwrite the former and there is
no way to just overwrite that one. we manually add the standard library
search paths to the very end of the linking command, so it won't
interfere with the search paths extracted by waf.

Fixes #5791
2018-06-12 01:54:45 +03:00
Akemi
5865086aa8 cocoa-cb: remove pre-allocation of window, view and layer
the pre-allocation was needed because the layer allocated a opengl
context async itself and we couldn't influence that. so we had to start
the core after the context was actually allocated. furthermore a window,
view and layer hierarchy had to be created so the layer would create
a context.
now, instead of relying on the layer to create a context we do this
manually and re-use that context later when the layer wants to create
one async itself.
2018-06-12 01:51:01 +03:00
Akemi
20dffe0621 vo_libmpv: pass vo struct to the control callback 2018-06-12 01:51:01 +03:00
Stephen Hutchinson
f66ee85fdf options.c: display additional metadata tags during video playback
The currently-displayed tags make sense for music files, but similar
information for video is more commonly - or at least should be - put
under other tags, while the audio-related tags are often used for
other information on video files (particularly with youtube-dl's
output).
2018-06-11 20:33:12 +03:00
Julian
4d2b865088 stats: remove superfluous line breaks
Those accidentally slipped in with 9975835bde
due to bad copy & paste.
2018-06-09 01:02:34 +03:00
Anton Kindestam
157b242289 hwdec_drmprime_drm: Do not show error message during probing
Change the log-level of an error message that would sometimes show up
during hwdec probing, and could be misleading.
2018-06-08 22:13:39 +03:00
gall0ws
bca59516cc stream_file: enable cache for FUSE filesystems on OpenBSD and FreeBSD 2018-06-05 01:28:35 +03:00
fatalis
8479449d14 osc: fix accidentally skipping files when seeking with slider
When seeking near the end of the file and the next file loads, seeking
continues on the next file at the same position and then immediately
the file after that. This patch stops slider seeking when a new file is
loaded, which is the standard behavior of many other players.
2018-06-04 00:14:59 +03:00
Jan Ekström
36cc33ff5a ao_alsa: simplify get_space() 2018-06-04 00:03:11 +03:00
Muhammad Faiz
945303a92e ao_alsa: replace snd_pcm_status() with snd_pcm_avail() in get_space()
Fixes a bug with alsa dmix on Fedora 29. After several minutes,
audio suddenly becomes bad and muted.

Actually, I don't know what causes this. Probably this is a bug in alsa.
In any case, as snd_pcm_status() returns not only 'avail', but also other
fields such as tstamp, htstamp, etc, this could be considered a good
simplification, as only avail is required for this function.
2018-06-04 00:00:57 +03:00
sfan5
7f625ea29b vo_sdl: add support for screensaver VOCTRL's
Previously vo_sdl would unconditonally disable the screensaver,
ignoring the `stop-screensaver` option.
2018-06-02 23:34:38 +03:00
Niklas Haas
5056777b86 vo_gpu: desaturate after peak detection
This sacrifices some dynamic range for well-behaved sources, but
prevents catastrophic desaturation on badly mastered / too bright
sources. I think that's the better trade-off. This makes the
desaturation algorithm much "safer" to deploy by default, as well. One
could even argue going up to strength 1.0, which works better for some
sources but worse for others. But I think the current strength is the
best trade-off even after this change.
2018-05-31 03:13:50 +03:00
wm4
cb52cfae1a player: fix coding style
I'm also not sure whether this condition doesn't subtly break a lot of
things.
2018-05-31 01:24:51 +03:00
wm4
31bce1cbe7 demux_lavf: drop obscure genpts option
This code shouldn't even exist in libavformat. If you still need it, you
can enable it via --demuxer-lavf-o.
2018-05-31 01:24:51 +03:00
wm4
ca97239cb6 options: add --http-proxy
Often requested, trivial.
2018-05-31 01:24:51 +03:00