0
0
mirror of https://github.com/mpv-player/mpv.git synced 2024-09-20 03:52:22 +02:00
Commit Graph

851 Commits

Author SHA1 Message Date
Philip Sequeira
db30c3a3fe TOOLS/zsh.pl: complete options based on types
No more equals signs for options that don't take values.

Complete values for options with preset choices.

Complete --no-whatever where applicable.

Fixes #997.
2015-01-06 06:57:52 +01:00
wm4
411109f484 TOOLS/lua/observe-all: add a warning
This is just natural, but it's also not that obvious.
2015-01-03 14:49:48 +01:00
wm4
44c0770247 TOOLS/lua/autoload: fix behavior with network URLs
readdir() fails if the directory is an URL, so just exit instead of
letting the Lua script fail.
2015-01-03 14:48:33 +01:00
wm4
73ea0ddc08 TOOLS/stats-conv: more improvements
Add an explicit "signal" event type, because the implicit one was
confusing.

Don't rescale the Y axis of the second graph, it was nonsense.

Make the legend for the second graph separate (and cleanup the code
creating the graphs).
2015-01-03 02:57:33 +01:00
wm4
487208b2e1 TOOLS/stas-conv: add timed value event type 2015-01-02 19:27:07 +01:00
wm4
83349a0e73 TOOLS/stats-conv: better output
Sort the legend by the used y value of binary events/signals, add a way
to filter branches (although that requires editing the script), and use
the full screen if the second subplot is not used.
2015-01-02 19:26:31 +01:00
Stefano Pigozzi
e01a6dac98 osxbundle: fix cascading config loading
mpv does 'cascading' configs by overriding options as the config become more
important (bundle -> system level -> user level).

Unfortunately mpv also loads two sets of configs files one after the other [1].
First it looks for 'config', then for 'mpv.conf'. For this reason a mpv.conf in
ANY location will override ANY config files named config (even if the mpv.conf
is in a system path and config in a user path).

[1]: Relevant code in player/configfiles.c

    load_all_cfgfiles(mpctx, section, "config");
    load_all_cfgfiles(mpctx, section, "mpv.conf");

Fixes: #1361
2014-12-26 09:18:20 +01:00
Avi Halachmi (:avih)
39e04e9294 options: deprecate 'lua' based options/dirs for 'script'
- --lua and --lua-opts change to --script and --script-opts
- 'lua' default script dirs change to 'scripts'
- DOCS updated

- 'lua-settings' dir was _not_ modified

The old lua-based names/dirs still work, but display a warning.

Signed-off-by: wm4 <wm4@nowhere>
2014-12-15 04:39:56 +01:00
Mihai Moldovan
8c927376a1 osxbundle: don't use sed but pure python
GNU sed and BSD sed don't share the same options for editing files in-place,
so a workaround is needed.

The most simple way is to use a pure python implementation of applying the
changes.
2014-12-13 11:20:29 +01:00
Stefano Pigozzi
fab64fd3cf cocoa: bundle: use idle=once 2014-12-07 16:23:08 +01:00
Stefano Pigozzi
685b8b7a00 cocoa: use --idle when running inside bundle
Previously when using the bundle we used a custom bizarro thing to wait for
events. Just use `--idle` and greatly simplify the code.
2014-12-06 14:16:13 +01:00
Stefano Pigozzi
f911ef08ab cocoa: save screenshots to desktop when using app bundle
Fixes #947
2014-12-05 23:30:23 +01:00
wm4
185e95ee3d video: remove internal QP passing
This was required by vf_pp, which was just removed.

vf_dlopen has this stuff in its API. This API is considered stable, so
the related fields are not removed from it. But the fields are always 0
now, so there's no point in keeping the example program around.

vf_pullup.c did some extremely awkward passthrough of this information,
but didn't actually use it.
2014-12-03 23:01:20 +01:00
Stefano Pigozzi
e7145ae24d cocoa: add https:// url scheme to bundle's plist 2014-12-02 20:55:19 +01:00
Nyx0uf
84866cac2d cocoa: add mk3d UTI to bundle's plist
This should allow lauching a mk3d file directly from the Finder.

Fixes #1311
2014-12-02 20:48:19 +01:00
Nyx0uf
f008bbb484 cocoa: split mkv/webm for imported UTI in plist 2014-12-01 21:34:31 +01:00
wm4
3295caca3d lua: add a function that formats Lua values as strings
Yep, Lua is so crappy that the stdlib doesn't provide anything like
this.

Repurposes the undocumented mp.format_table() function and moves it to
mp.utils.
2014-11-29 00:03:46 +01:00
wm4
9666d48aa3 TOOLS/lua: add script that pauses playback when minimizing the window
Uses functionality that was added a month ago for exactly this purpose.

Fixes #1237.
2014-11-29 00:03:46 +01:00
Rudolf Polzer
92316eb740 TOOLS/idet.sh: Adjust for changes in FFmpeg.
Compatibility to older idet is preserved.
2014-11-22 08:13:26 +01:00
Ben Boeckel
07c4d67565 umpv: update comment for the new FIFO location 2014-11-15 20:20:06 +01:00
wm4
805e952d82 demux_mkv: read CueRelativePosition/CueDuration elements
Nothing is done with them yet. This is preparation for the following
commit.

CueRelativePosition isn't even saved anywhere, because I don't intend to
use it. (Too messy for no gain.)
2014-11-05 21:52:07 +01:00
wm4
4e87ac8231 demux_mkv: implement audio skipping/trimming
This mechanism was introduced for Opus, and allows correct skipping of
"preroll" data, as well as discarding trailing audio if the file's
length isn't a multiple of the audio frame size.

Not sure how to handle seeking. I don't understand the purpose of the
SeekPreRoll element.

This was tested with correctness_trimming_nobeeps.opus, remuxed to mka
with mkvmerge v7.2.0. It seems to be correct, although the reported file
duration is incorrect (maybe a mkvmerge issue).
2014-11-03 20:20:28 +01:00
wm4
078f5f300d TOOLS/lua/autoload: fix operation outside of working dir
Fixes #1222. (This commit is based on a patch posted there.)
2014-10-26 14:34:46 +01:00
wm4
dd91c09a71 TOOLS/lua/autoload: don't shadow local variable
"dir" is already used somewhere above. This was ok, but not nice.
2014-10-26 14:34:37 +01:00
wm4
51a3f13705 TOOLS/umpv: create FIFO in user directory
Makes these security measures unnecessary.
2014-10-24 21:27:38 +02:00
Kevin Mitchell
bbf4a8aa5d TOOLS/lua: update README.md 2014-10-21 00:55:15 +02:00
Kevin Mitchell
3617399a46 TOOLS/lua: remove tabs from some lua scripts 2014-10-21 00:55:15 +02:00
Kevin Mitchell
e68cc34c99 TOOLS/lua: add autodeint.lua
This isn't quite as robust as idet.sh as the default detection
interval is only 4 seconds vs 35 for idet.sh. idet.sh can have such a
large sample time since it turns off the vo and uses --untimed, which
is currently not possible from lua.
2014-10-21 00:55:15 +02:00
shdown
040c5a9f68 TOOLS/vf_dlopen/ildetect.sh: remove duplicated assigment 2014-10-16 21:17:01 +02:00
wm4
1d45a3a163 TOOLS/umpv: drop unnecessary check
This was supposed to make sure that argv[1:] does not fail, but Python
actually allows mismatching bounds for slicing.
2014-09-24 21:29:30 +02:00
shdown
546c0f0b25 TOOLS/umpv: use python octal notation 2014-09-24 02:12:30 +02:00
shdown
c6d0e41335 TOOLS/mpv_identify.sh: remove pointless escape 2014-09-24 02:08:49 +02:00
shdown
7e5f707baf TOOLS/idet.sh: add description
Just a copy of c0cd58e3f5 commit message
(with a small fix: ildetect.sh+ildetect.so, not
ildetect.sh+ildetect.sh).
2014-09-24 02:08:47 +02:00
shdown
3eae8b7170 TOOLS/idet.sh: remove unused and duplicated assignments 2014-09-24 02:08:45 +02:00
Ben Boeckel
54d1dae687 TOOLS: idet: remove extra '$' in $(()) expansion 2014-09-21 15:06:47 +02:00
shdown
bb005a385a TOOLS/umpv: make URL detection consistent with mpv method
See mp_is_url in options/path.c.
2014-09-20 15:18:53 +02:00
shdown
dfbb4d03ee TOOLS/umpv: print error message to stderr 2014-09-20 15:18:51 +02:00
shdown
5332ecf651 TOOLS/umpv: use MPV environment variable, not UMPV_OPTIONS
Just like the rest of TOOLS/*.sh scripts.
2014-09-20 15:18:49 +02:00
Rudolf Polzer
a173d3a2fb TOOLS/idet.sh: Handle the case of multiple Parsed_idet_0: output lines.
This seems to happen frequently now. It is handled by adding their values.
2014-09-17 14:11:56 +02:00
shdown
f2c46bc1d1 TOOLS: eliminate echoes with variable substitutions
echo behaviour with backslash escapes seems to be non-portable: dash does
expand such an escapes and bash does not, so use cat/printf instead.
2014-09-17 00:00:05 +02:00
shdown
02d0b2f31c TOOLS/mpv_identify.sh: simplify line-by-line reading
Use here-document idiom to read mpv output line-by-line.
2014-09-16 23:59:56 +02:00
wm4
26e0cce969 TOOLS/mpv_identify.sh: mark as executable 2014-09-16 17:34:19 +02:00
Ben Boeckel
5fd8660f5f TOOLS: idet: use quotes for the verdict value
ShellCheck warns about "vara-varb" about not being in $(()), but we
actually want the literal string, so quote it. Also fix a typo.
2014-09-16 17:32:39 +02:00
Ben Boeckel
11c044aa48 TOOLS: shellcheck: quote variable expansions 2014-09-16 17:32:33 +02:00
Ben Boeckel
45e2345a7f TOOLS: shellcheck: remove '$' on variables in $(()) expansion 2014-09-16 17:29:46 +02:00
Ben Boeckel
ec2c6a17dc TOOLS, version.sh: shellcheck: replace cmd with $(cmd)
Signed-off-by: wm4 <wm4@nowhere>
2014-09-16 17:29:39 +02:00
Ben Boeckel
ba2a3f40ac TOOLS: idet: remove unused code 2014-09-16 17:29:11 +02:00
Philip Sequeira
7c77f0b803 TOOLS/zsh.pl: complete options that take file names 2014-09-13 02:03:09 +02:00
Bruno George de Moraes
bca4219dd0 malloc+memset(0) to calloc
Signed-off-by: wm4 <wm4@nowhere>
2014-09-05 01:59:11 +02:00
wm4
8599c959fe video: initial Matroska 3D support
This inserts an automatic conversion filter if a Matroska file is marked
as 3D (StereoMode element). The basic idea is similar to video rotation
and colorspace handling: the 3D mode is added as a property to the video
params. Depending on this property, a video filter can be inserted.

As of this commit, extending mp_image_params is actually completely
unnecessary - but the idea is that it will make it easier to integrate
with VOs supporting stereo 3D mogrification. Although vo_opengl does
support some stereo rendering, it didn't support the mode my sample file
used, so I'll leave that part for later.

Not that most mappings from Matroska mode to vf_stereo3d mode are
probably wrong, and some are missing.

Assuming that Matroska modes, and vf_stereo3d in modes, and out modes
are all the same might be an oversimplification - we'll see.

See issue #1045.
2014-08-30 23:24:46 +02:00
shdown
b8f2f0d69e TOOLS/mpv_identify.sh: simplify $MPV handling 2014-08-30 19:23:42 +02:00
shdown
4a976c469c TOOLS/mpv_identify.sh: various style improvements
Double-quote everything, eliminate unneeded evals and deprecated
`backtits` substitution syntax.
2014-08-30 19:23:42 +02:00
shdown
880d5c8a4a TOOLS/mpv_identify.sh: move script body to a function
Don't prepend each variable with __midentify__, just make them local
to the function.
2014-08-30 19:23:42 +02:00
shdown
cbe03b6255 TOOLS/youtube-dl_mpv.sh: simplify $MPV handling 2014-08-30 19:23:42 +02:00
shdown
43d4667028 TOOLS/youtube-dl_mpv.sh: disable globbing before expanding $video_url
$video_url can contain a question mark, which can be expanded to a
character in an existing file name if globbing is enabled.
2014-08-30 19:23:41 +02:00
wm4
a8299cec29 TOOLS/youtube-dl_mpv: allow playing multiple URLs
Unfortunately this also means you can't pass extra mpv options after the
URL anymore. You can prefix the script with MPV='mpv --options' though.
2014-08-29 20:20:29 +02:00
wm4
3ec6705e34 TOOLS: youtube wrapper: allow overriding mpv binary 2014-08-26 20:47:30 +02:00
wm4
3c07e86fd3 TOOLS/stats-conv.py: improvements
This is still pretty useful for debugging timing-dependent things.
2014-08-19 20:09:46 +02:00
Philip Sequeira
b36ed6d9f9 TOOLS/zsh.pl: protect global environment 2014-08-17 12:51:10 +02:00
Philip Sequeira
c7e67d008a TOOLS/zsh.pl: fix a ret that hadn't been changed to rc 2014-08-17 12:51:10 +02:00
Philip Sequeira
4b8f512217 TOOLS/zsh.pl: complete profiles
Implemented in shell, because it has to be done at runtime.
2014-08-17 12:51:10 +02:00
Alessandro Ghedini
e7cab32fae TOOLS/zsh.pl: properly set the return value
The previous commit made the completion script always return non-zero, even when
a match is found. This explicitly sets the return value to zero whenever a match
is found but defaults to non-zero in case nothing is matched.
2014-08-13 23:42:38 +02:00
c_14
fd98863b1f TOOLS/zsh.pl: properly return non-zero when no matches are found
Returning a non-zero value signals to the zsh completion system that no matches
were added by the script so that it can try the user-defined matchers (e.g.
those defined with matcher-list).

Fixes #1008.
2014-08-13 22:57:59 +02:00
wm4
f9d2ad6c17 Move status-line.lua
Looks like TOOLS/lua/ is now established as dumping ground for random
Lua scripts, so DOCS/lua_examples/ is not needed anymore.
2014-08-11 17:08:32 +02:00
wm4
82a223e4e0 TOOLS: add test script for property change notifications 2014-08-02 01:53:21 +02:00
Rudolf Polzer
35c20c3094 idet.sh: Fix a typo. 2014-07-16 16:15:12 +02:00
Tsukasa OMOTO
1c850ff559 osxbundle: fix detection of user libraries
Previous code would detect for example `libcaca.0.dylib` as a system library,
because it matched the `libc` condition.
2014-07-16 08:36:34 +02:00
Rudolf Polzer
f5449870e0 idet.sh: Fix telecine detection. 2014-07-15 11:10:24 +02:00
Nyx0uf
22c3de3f8a OS X bundle: Add more imported UTI
Not that there are widely used formats, but it will allow to play them directly from the Finder.
2014-07-04 10:05:52 +02:00
Alessandro Ghedini
29b047da6f TOOLS/zsh.pl: complete URL schemes based on --list-protocols 2014-07-03 11:03:56 +02:00
Alessandro Ghedini
17d65f9aff TOOLS/zsh.pl: sort options in reverse order by length
This stops options that are prefixes of other options from blocking
completion of values for the longer ones.
2014-07-03 11:03:56 +02:00
Philip Sequeira
e940afec15 TOOLS/zsh.pl: untabify 2014-07-03 11:03:56 +02:00
Philip Sequeira
7450a7f531 TOOLS/zsh.pl: fix _arguments line
Don't use _x_arguments, as we don't support X arguments.

Get rid of -s, because we don't support multiple single-letter options
in one argument.

Add -S, because we ignore options after "--".
2014-07-03 11:03:56 +02:00
Philip Sequeira
bbc005825a TOOLS/zsh.pl: don't consume extra arguments
Completion now uses "--opt=value" instead of "--opt value". Once the
user presses space and starts a new argument, the option just
completed is out of the picture, whether or not it was given an
argument. This handles options with no arguments or optional arguments
much better; previously, completing such an option would effectively
disable completion for the next argument.

Custom completed options such as "--ao" and friends will no longer
claim to consume an extra argument.
2014-07-03 11:03:56 +02:00
Philip Sequeira
fd09578f0f TOOLS/zsh.pl: escape all colons in option descriptions 2014-07-03 11:03:56 +02:00
Alessandro Ghedini
da27eceb85 TOOLS: add script for generating a zsh completion script
As discussed in #775
2014-06-08 20:48:39 +02:00
Rudolf Polzer
c0cd58e3f5 idet.sh: An alternative to ildetect.sh.
This script uses ffmpeg's "idet" filter for interlace detection. In the
long run this should replace ildetect.sh+ildetect.sh.
2014-05-27 18:41:40 +02:00
wm4
6f20d6b74e lua: fix compilation with lua 5.2
Commit e2e450f9 started making use of luaL_register(), but OF COURSE
this function disappeared in Lua 5.2, and was replaced with a 5.2-only
alternative, slightly different mechanism.

So just NIH our own function. This is actually slightly more correct,
since it forces the user to call "require" to actually make the module
visible for builtin C-only modules other than "mp". Fix autoload.lua
accordingly.
2014-05-26 21:59:29 +02:00
wm4
0e1ab2a8da autoload.lua: fix autoloading of files to prepend
This used the wrong index variable, and thus didn't work.
2014-05-25 20:17:03 +02:00
wm4
fea1bad856 TOOLS: add a Lua script to autoload playlist entries
This will load other files in the same directory when a single file is
played. It's an often requested feature, but we definitely don't want it
in the core.
2014-05-25 19:52:26 +02:00
Tsukasa OMOTO
0304c4f92d osxbundle: fix recursion termination
Prevents the binary from being copied over to the lib directory.
2014-05-25 07:42:40 +02:00
Kevin Mitchell
1eee4d7799 TOOLS/vf_dlopen: use new pixelformats, fix usage for newstyle args 2014-05-15 10:32:16 -07:00
wm4
6dec78e475 TOOLS/mpv_identify.sh: unbreak 2014-05-14 20:56:09 +02:00
wm4
fd56e2dbe6 TOOLS/stats-conv: don't crash on empty lines 2014-05-11 18:16:33 +02:00
wm4
cc94436c5b TOOLS/stats-conv: draw playloop and AO thread events separately
Use for all AO thread events y=0.5, while playloop events remain at y=1.
This makes the graph easier to read.
2014-05-11 17:07:26 +02:00
Stefano Pigozzi
fc4a43d39a osxbundle: split and optimize bundling script
Move the code that copies the dylib's to the bundle to a new script
(dylib-unhell.py) which is called by osxbundle.py.

dylib-unhell is about 20x faster than the previous implementation. This is
accomplished by removing superflous shell-out operations which are kept track
of using an in memory tree of all the needed dependencies. Moreover the
shell-outs have been further optimized by not requiring a complete shell for
every operation and just using subprocess.call (which is equivalent to Popen).
2014-05-09 20:48:15 +02:00
Kevin Mitchell
0467e13725 TOOLS/lua: add cycle-deinterlace-pullup script
Override the shift+d hotkey to add a pullup step to the cycle.
2014-05-06 10:02:41 -07:00
Kevin Mitchell
6e62779e98 TOOLS/lua: conform to whitespace coding-style 2014-05-06 09:59:59 -07:00
Kevin Mitchell
20b5fecdf1 TOOLS/lua: use double quotes unless there's a good reason 2014-05-04 12:59:21 -07:00
Kevin Mitchell
c91373a202 TOOLS/lua/autocrop: handle case of user hitting hotkey while cropdetection already running 2014-05-04 12:54:03 -07:00
Kevin Mitchell
74984aaff1 TOOLS/lua: no longer gsub out "lua/" prefix, now that its no longer there 2014-05-04 12:29:32 -07:00
Martin Herkt
b54c963258 options: rename video-related options/properties
Renamed options:
--aspect    → --video-aspect
--fstype    → --x11-fstype
--native-fs → --fs-missioncontrol
--name      → --x11-name

Renamed properties:
aspect → video-aspect
2014-05-04 02:46:11 +02:00
Kevin Mitchell
8e8758dbe1 TOOLS: better documentation of lua scripts 2014-04-29 08:31:44 -07:00
Kevin Mitchell
4b0a760d86 TOOLS: improve autocrop.lua
It now inserts no filters and does nothing until the hot-key is pressed.
This makes it more suitable to be put in ~/.mpv/lua.

When the hot-key is pressed, it now inserts the cropdetect filter and
waits 1 second (or a --lua-opts specified duration) before gathering
the cropdetect metadata and inserting the appropriate crop filter. A
second press of the hotkey removes the crop.
2014-04-29 08:31:44 -07:00
wm4
8562f53cf9 TOOLS/umpv: make it work with Python 3 (again)
Apparently, the 3rd (2nd) parameter to string.translate() function was
removed.

Also, make_abs() had a mistake - not sure how this passed testing.
2014-04-29 02:21:59 +02:00
wm4
2a8f7181e3 TOOLS/umpv: don't mangle URLs
This attempted to prefix the current directory to URLs, because it
didn't recognize them as already absolute paths.
2014-04-29 02:16:18 +02:00
wm4
fa1b9517bc TOOLS/umpv, mpv.desktop: use --no-terminal instead of --really-quiet
So this won't initialize terminal handling if stdout happens to be a
terminal. It also suppresses all output to stdout/stderr.
2014-04-29 02:09:59 +02:00
wm4
f2f19b3404 TOOLS/umpv: allow passing 0 files
Some might use that to just create an empty window with --force-window
--idle (for whatever reasons).
2014-04-29 02:06:40 +02:00
wm4
1800becf6a TOOLS/umpv: allow passing options
But only via a special environment variable.
2014-04-29 01:24:21 +02:00
wm4
6c87b50727 TOOLS/umpv: make it work with Python 3
Apparently they removed octal literals, and made them invalid syntax.
2014-04-29 01:21:21 +02:00
wm4
a6dafb061f TOOLS: make youtube-dl_mpv.sh executable 2014-04-28 22:23:31 +02:00
Kevin Mitchell
4e973c059a TOOLS: indent lua scripts by 4 spaces instead of 3 2014-04-27 15:34:53 +02:00
Kevin Mitchell
7ef045555d TOOLS: add lua/drc-control
allows live insertion/deletion/adjustment of drc audio filter
2014-04-27 15:34:53 +02:00
Kevin Mitchell
ae56b8d237 TOOLS: move autocrop.lua to TOOLS/lua
in anticipation of more lua scripts
2014-04-27 15:34:52 +02:00
Nyx0uf
653b7aa32d OS X bundle: add UTImportedTypeDeclarations
Allows to declare UTIs [1] for types of file that OS X doesn't know, like mkv,
mka, etc.

For example: instead of having a dynamically generated UTI for .mkv like
'dyn.somerandomstring', 'io.mpv.mkv' is registered and conforms to public.movie
and is known system wide.

Note: The list is far from being complete but it should cover the most used
type of files.

[1]: https://developer.apple.com/library/ios/documentation/FileManagement/Conceptual/understanding_utis/understand_utis_conc/understand_utis_conc.html#//apple_ref/doc/uid/TP40001319-CH202-CHDHIJDE

Fixes: #734
2014-04-25 09:18:52 +02:00
wm4
9dba2a52db player: add a --dump-stats option
This collects statistics and other things. The option dumps raw data
into a file. A script to visualize this data is included too.

Litter some of the player code with calls that generate these
statistics.

In general, this will be helpful to debug timing dependent issues, such
as A/V sync problems. Normally, one could argue that this is the task of
a real profiler, but then we'd have a hard time to include extra
information like audio/video PTS differences. We could also just
hardcode all statistics collection and processing in the player code,
but then we'd end up with something like mplayer's status line, which
was cluttered and required a centralized approach (i.e. getting the data
to the status line; so it was all in mplayer.c). Some players can
visualize such statistics on OSD, but that sounds even more complicated.
So the approach added with this commit sounds sensible.

The stats-conv.py script is rather primitive at the moment and its
output is semi-ugly. It uses matplotlib, so it could probably be
extended to do a lot, so it's not a dead-end.
2014-04-17 21:47:00 +02:00
Kevin Mitchell
f5954b2223 TOOLS: vf-metadata: lua cropdetect example script
Signed-off-by: wm4 <wm4@nowhere>
2014-04-13 18:03:01 +02:00
Nikoli
65099833f7 TOOLS: add script for using mpv with youtube-dl
Signed-off-by: wm4 <wm4@nowhere>
2014-04-09 20:41:51 +02:00
Diogo Franco (Kovensky)
4a66fce7d3 Parse::Matroska::Reader: get rid of bigrat
It seems that it was causing issues with certain perl setups (such as
the one on issue #549). It also turns out that it was not behaving correctly
(not all constants were being promoted to big nums as they should), so we
use explicit objects to derive the constants.

There were also precedence issues. I wonder if this even worked right to
begin with.

The 'double' path (8-byte floats) is untested, as I couldn't easily find
a file with such a field.

Closes #549.
2014-02-15 19:43:22 -03:00
wm4
e6861ca51f umpv: silence mpv terminal output
Now it does basically the same as mkv.desktop. Explanation is included
in the description comment.
2014-02-05 19:04:35 +01:00
wm4
a6f04a41fe umpv: improve description 2014-02-05 19:01:06 +01:00
wm4
f77efbcce9 umpv: use --force-window
This makes it show a window even when playing audio-only files.
2014-02-05 18:55:06 +01:00
Rudolf Polzer
761a013736 ildetect: add ILDETECT_FORCE_RUN (if interlacing could not be decided, assume yadif). 2013-12-18 10:56:33 +01:00
ChrisK2
218b9d3737 osxbundle: use mpv's version.sh instead of osxbundle's 2013-12-09 21:45:09 +01:00
Stefano Pigozzi
7e2edad8ef switch the build system to waf
This commit adds a new build system based on waf. configure and Makefile
are deprecated effective immediately and someday in the future they will be
removed (they are still available by running ./old-configure).

You can find how the choice for waf came to be in `DOCS/waf-buildsystem.rst`.
TL;DR: we couldn't get the same level of abstraction and customization with
other build systems we tried (CMake and autotools).

For guidance on how to build the software now, take a look at README.md
and the cross compilation guide.

CREDITS:
This is a squash of ~250 commits. Some of them are not by me, so here is the
deserved attribution:

 - @wm4 contributed some Windows fixes, renamed configure to old-configure
   and contributed to the bootstrap script. Also, GNU/Linux testing.
 - @lachs0r contributed some Windows fixes and the bootstrap script.
 - @Nikoli contributed a lot of testing and discovered many bugs.
 - @CrimsonVoid contributed changes to the bootstrap script.
2013-11-21 21:22:36 +01:00
Stefano Pigozzi
4ee51526ae osx bundle: remove embedded fonts.conf
This could cause the bundle to recache stuff because of differences with
configuration of other software using fonconfig. The defaults OS X directories
should be added to fontconfig at build time (through configure).
2013-11-14 21:23:47 +01:00
wm4
b74edd4069 demux_mkv: fix compiler warnings
Make TOOLS/matroska.pl output structs with fields sorted by name in
ebml_types.h to make the order of fields deterministic. Fix warnings in
demux_mkv.c caused by the first struct fields switching between scalar
and struct types due to non-deterministic ebml_types.h field order.
Since it's deterministic now, this shouldn't change anymore.

The warnings produced by the compilers are bogus, but we want to silence
them anyway, since this could make developers overlook legitimate
warnings.

What commits 7b52ba8, 6dd97cc, 4aae1ff were supposed to fix. An earlier
attempt sorted fields in the generated C source file, not the header
file. Hopefully this is the last commit concerning this issue...
2013-11-04 23:49:22 +01:00
ChrisK2
3b5f8ea571 tools: add --no-cache --no-config to mpv_identify.sh 2013-11-03 20:48:49 +01:00
Diogo Franco (Kovensky)
6dd97ccf5c matroska.pl: Sort the generated struct field list
Newer versions of perl randomize the hash used for hashes every time
it's run; this makes the order of the fields be non-deterministic. Tack
a sort there to make it deterministic. Needed to fix (or allow fixing) a
buggy gcc warning.
2013-11-02 01:43:49 +00:00
Stefano Pigozzi
00d8e85373 Revert "osxbundle: fonts.conf: only look for fonts in ~/.mpv/fonts"
Commit broke text subtitles without embedded fonts. Will look for a better
solution later. Revert it for now, since I'm starting to get bug reports.

This reverts commit 4a9f618d9f.
2013-09-19 21:39:16 +02:00
Stefano Pigozzi
4a9f618d9f osxbundle: fonts.conf: only look for fonts in ~/.mpv/fonts
This is to avoid the 30s hang while mpv caches fonts. In practice all the
fonts an average user is going to use are embedded in mkv files so there is
no reason to build fontconfig's cache on all of OS X system directories.

I might add something similar for terminal usage, but I am highly undecided.
2013-09-18 22:18:33 +02:00
Bilal Syed Hussain
29edc86721 macosx: add webm the filetypes handled by the bundle 2013-09-14 20:49:55 +02:00
Stefano Pigozzi
494d408583 macosx_application: handle mpv:// links
Pretty useful for people writing userscripts for web browsers. Links starting
with 'mpv://' are forwarded to the mpv OSX bundle. The leading 'mpv://' is
stripped from the recived url and the rest of the string is inserted as is in
the playlist.
2013-09-07 15:37:02 +02:00
Stefano Pigozzi
b0797e8fe9 macosx_application: handle URL events as fileopen events
This allows to open URLs directly with mpv. This is useful for streaming and
libquvi supported sites.
2013-09-07 12:10:29 +02:00
wm4
a5183a761c x11: add window icon
The png file added to etc/ are taken from the link mentioned in commit
303096b, except that they have been converted to 16 bit, sRGB (with
color profile info dropped, if there was one), and transparent pixels
reset for better compression.

The file x11_icon.bin is generated by gen-x11-icon.sh. I'm adding it to
the git repo directly, because the script requires ImageMagick, and we
don't want to make building even more complicated.

The way how this is done is basically a compromise between effort
required in x11_common.c and in gen-x11-icon.sh. Ideally, x11_icon.bin
would be directly in the format as required by _NET_WM_ICON, but trying
to write the binary width/height values from shell would probably be a
nightmare, so here we go.

The zlib code in x11_common.c is lifted from demux_mkv.c, with some
modifications (like accepting a gzip header, because I don't know how to
make gzip write raw compressed data).
2013-09-01 23:27:33 +02:00
Stefano Pigozzi
303096bcb2 change application icon
I would like to thank Chris Ward (@tenzerothree, http://tenzerothree.com/) for
working on the art for these icons and bringing some eye candy to the project.

The PSDs made by Chris are available on our Dropbox [1], along with the exports
I made to create OSX and Windows icons. The PSDs are almost completly vector
and all the resolutions look really similar, except the 16px favicon which was
handcrafted to look better and more recognizeable on the smaller pixel budget.

For Mac OS X the icons were created using iconutils on the PNGs iconsets
exported from the PSDs. These even support retina resolutions (except 512@2x).

For Windows the .ico file was created with imagemagick. The included images
are 16px, 24px, 32px, 48px 64px, 256px. These are the resolutions listed on
MSDN for supporting Windows XP [2] and Windows versions based on Aero [3].
Only 32bit PNGs were used since it is 2013.

For Linux nothing changed yet, even though @wm4 talked about using the PNGs
directly there. This will probably be dealt with in a later commit.

  [1]: https://www.dropbox.com/sh/yelfoj9tbft7o06/A8vOT6JKaG
  [2]: http://msdn.microsoft.com/en-us/library/ms997636.aspx
  [3]: http://msdn.microsoft.com/en-us/library/aa511280.aspx
2013-09-01 12:24:53 +02:00
James Ross-Gowan
103fbf043f mpv.rc: update Windows icon
Based on the OSX bundle icon.
2013-07-30 16:15:37 +02:00
wm4
fece4e3053 build: fix build with vdpau, simplify
Instead of generating vdpau_template.c with a Perl script, just include
the generated file in git. This is ok because it changes very rarely,
and the script is larger than the output it generates.

It also simplify the Makefile, and fixes the build. The problem was that
transitive dependencies do not work with generated files: there is no
dependency information yet when building it the first time. I overlooked
this because I didn't delete the .d files for testing (which contained
the correct dependencies, but only _after_ a first successful build).
2013-07-29 00:59:07 +02:00
wm4
3e59ee25ea TOOLS: add script for emulating "unique application" functionality on Linux
See github issue #43.

This comes with a load of caveats, so be sure to read the comments at
the start of the script.
2013-07-28 23:08:05 +02:00
Stefano Pigozzi
0a1c497945 osxbundle: suggest some ways to correct missing dependencies
Hopefully this can give some more clues to users about what broke if they
find themselves in this situation.
2013-06-30 09:14:25 +02:00
Rudolf Polzer
e7c372cb2f ildetect: $ILDETECT_RUN_INTERLACED_ONLY to only run the job if not progressive 2013-06-21 06:22:13 +02:00
Rudolf Polzer
1fc7dfe68f ildetect.sh: add a quiet mode; verify telecine decision
For quiet mode: ILDETECT_QUIET=1 ildetect.sh ...

Telecine decision (guess by ildetect.so) is verified by retrying the
ildetect run with the pullup filter inserted.
2013-06-20 19:21:49 +02:00
Rudolf Polzer
c430d89adb ildetect.sh: skip needlessly going through vo_lavc
We can now turn off encoding mode by command line and use vo_null
instead.
2013-06-20 12:25:55 +02:00
Rudolf Polzer
9137d86eda ildetect.sh: better interlace detection range 2013-06-20 10:13:12 +02:00
Rudolf Polzer
6b808ef8da ildetect.sh: env vars support 2013-06-20 09:14:27 +02:00
Rudolf Polzer
c6cbbd292a vf_dlopen ildetect: fix numdecidedadjacentframes counter 2013-06-16 17:22:37 +02:00
Rudolf Polzer
fb04351f76 vf_dlopen ildetect: make the wrapper shell script more robust 2013-06-16 17:18:45 +02:00
Rudolf Polzer
7ae4242820 vf_dlopen filters: add an "ildetect" filter that detects interlacing
The filter analyzes each frame for combing, and decides at the end
whether the content is likely interlaced, telecined or progressive.
2013-06-16 17:11:25 +02:00
Rudolf Polzer
5589412b3c vf_dlopen framestep: step width of 0
This is now defined to mean to never output any frame again (except for
the first).
2013-05-20 06:59:44 +02:00
Rudolf Polzer
34e542591b vf_dlopen framestep filter: add a parameter for the phase
also, default to 0-indexed frame counts (so by default, the 1st frame is
output). Old behaviour can be done by -vf dlopen=./framestep.so:42:41.
2013-05-20 06:55:29 +02:00
Rudolf Polzer
2958ae39ca vf_dlopen examples: slightly simply the framestep filter
We don't need config() ;)
2013-05-16 20:21:54 +02:00
Rudolf Polzer
cfa0515e0e vf_dlopen examples: add framestep filter
Usage: -vf dlopen=./framestep.so:5
2013-05-16 20:14:50 +02:00
wm4
e6e5a7b221 Merge branch 'audio_changes'
Conflicts:
	audio/out/ao_lavc.c
2013-05-12 21:47:55 +02:00
wm4
30dd18eac1 uncrustify: add some instructions 2013-05-12 21:24:55 +02:00
Stefano Pigozzi
22d53fb97c change reverse DNS strings to io.mpv.*
fixes #60
2013-04-16 23:34:58 +02:00
Stefano Pigozzi
ae9e7b5a4a make: add osxbundle-skip-deps
This adds a way to generate a Mac OS X application bundle without the bundled
dependencies.

fixes #57
2013-04-08 21:44:46 +02:00
Rudolf Polzer
a95a5bcf2f vf_dlopen examples: add copyright headers (LGPL 2.1+) 2013-04-08 09:43:29 +02:00
wm4
d48c855669 mpv_identify: add --quiet to mpv command line
Prevents the status line from being printed. Otherwise, the status line
is always printed due to --frames=1, and it's visible on the terminal
because it's printed to stderr.
2013-03-26 01:29:53 +01:00
wm4
90118a3810 mpv_identify: allow specifying mpv binary via MPV
Useful for testing.
2013-03-26 01:29:53 +01:00
wm4
790df511c4 core: output --playing-msg message only after at least one frame is shown
This way it's possible to retrieve correct information about video, like
actual width/height, which in general are available only after at least
one frame has been sent to the video output, such as dwidth/dheight.

mpv_identify.sh becomes a bit slower, because we let it decode enough
audio and video to fill the audio buffers and to send one frame to the
video output. Also, --playing-msg isn't shown anymore with --frames=0
(could be fixed by special-casing it, should this break any use cases).

Note that in some corner cases, like when the demuxer for some reason
returns lots of audio packets but no video packets at the start, but
video actually starts later, the --playing-msg will still be output
before video starts.
2013-03-26 01:29:53 +01:00