| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
| |
Equivalent code.
|
|
|
|
|
|
|
| |
"#" starts a comment, so the # key needs to be handled specially.
MPlayer has the same issue, but its input.conf is wrong. Or at least I
think it's wrong; looking at the MPlayer code it's doubtful they somehow
special-case and handle this.
|
|
|
|
|
|
|
|
| |
Remove the unnecessary indirection through ao fields.
Also fix the inverted result of AOCONTROL_HAS_TEMP_VOLUME. Hopefully the
change is equivalent. But actually, it looks like the old code did it
wrong.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is a deadlock caused by a lock order issue: sub/osd.c locks the OSD
first, then the subtitle decoder lock. player/sub.c does the reverse.
Fix this by discussing away the requirement for locking (see below),
which allows us to drop the broken sub lock. sub_get_text() still
acquires and releases the sub decoder lock, but it's not held at the
same time as the OSD lock anymore, so it should be fine.
Originally, the sub lock was acquired because sub_get_text() returns a
pointer to a mutable string. We simply declare that it's ok to call it
unlocked, as long as only 1 thread accesses it, which works out fine in
this case.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
With --gapless-audio=no, changing from one file to the next apparently
made it hang, until the player was woken up by unrelated events like
input. The reason was that the AO doesn't notify the player of EOF
properly. the played was querying ao_eof_reached(), and then just went
to sleep, without anything waking it up.
Make it event-based: the AO wakes up the playloop if the EOF state
changes.
We could have fixed this in a simpler way by synchronously draining the
AO in these cases. But I think proper event handling is preferable.
Fixes: #1069
CC: @mpv-player/stable (perhaps)
|
| |
|
|
|
|
|
|
|
|
| |
It seems hrtf works in 48khz only - and if that wasn't the input, the
filter just exited with an error. Make it request the 48khz instead. The
player will insert a resampling filter.
Not sure why it wasn't done like this in the first place.
|
| |
|
|
|
|
|
|
|
| |
Just like the previous commit, this takes care of fallout from commit
7ab228, which fixed a bug, but introduced some new ones.
CC: @mpv-player/stable
|
|
|
|
|
|
| |
Signed-off-by: wm4 <wm4@nowhere>
CC: @mpv-player/stable
|
|
|
|
|
|
|
|
|
|
|
| |
The Windows version of tmpfile is actually pretty broken. It tries to
create the file in the root directory of the current drive, which means
on Vista and up, it normally fails due to insufficient permissions.
Replace it with a version that uses GetTempPath.
Also remove the Windows-specific note about automatic deletion of the
cache file. FILE_FLAG_DELETE_ON_CLOSE is available in NT, and it should
be pretty reliable.
|
|
|
|
| |
I added this non-sense earlier this day. Oops.
|
|
|
|
|
| |
It is in fact selected. The manpage wasn't updated when this was
changed.
|
|
|
|
| |
Signed-off-by: wm4 <wm4@nowhere>
|
|
|
|
| |
Really only for testing.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Somehow, there was a larger misunderstanding in the code: ao_buffer
does not need to be preserved over audio reinit for proper support of
gapless audio. The actual AO internal buffer takes care of this.
In fact, preserving ao_buffer just breaks audio resync. In the ordered
chapter case, end_pts is used, which means not all audio data in the
buffer is played, thus some data is left over when audio decoding
resumes on the next segment. This triggers some code that aborts resync
if there's "audio decoded" (ao_buffer contains something), but no PTS
is known (nothing was actually decoded yet).
Simplify, and always bind the output buffer to the decoder.
CC: @mpv-player/stable (maybe)
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The oldest supported FFmpeg release doesn't provide
av_vdpau_alloc_context(). With these versions, the application has no
other choice than to hard code the size of AVVDPAUContext. (On the other
hand, there's av_alloc_vdpaucontext(), which does the same thing, but is
FFmpeg specific - not sure if it was available early enough, so I'm not
touching it.)
Newer FFmpeg and Libav releases require you to call this function, for
ABI compatibility reasons. It's the typcal lakc of foresight that make
FFmpeg APIs terrible. mpv successfully pretended that this crap didn't
exist (ABI compat. is near impossible to reach anyway) - but it appears
newer developments in Libav change the function from initializing the
struct with all-zeros to something else, and mpv vdpau decoding would
stop working as soon as this new work is relewased.
So, add a configure test (sigh).
CC: @mpv-player/stable
|
|
|
|
| |
Make it clear that this accesses the un-fullscreened window size.
|
|
|
|
| |
Seems like a good idea.
|
|
|
|
|
|
|
|
| |
What the flying fuck?
Unfortunately, these are already in the wild.
CC: @mpv-player/stable
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This wraps waf's find_program in our own check boilerplate code so that it
can be used in the declarative dependencies section of the wscript.
Can be used like this:
}, {
'name': 'sed',
'desc': 'sed program',
'func': check_program('sed', 'SED'),
}, {
First argument is the program name, and the second is the waf variable name
where the program path will be stored. In this example we will be able to
refer to sed with ${{SED}} when creating waf Tasks in wscript_build.
/cc @giselher: I think you need this for wayland-scanner.
|
|
|
|
|
| |
Prints output informations, useful for finding out if we detect the right mode
and for debugging.
|
|
|
|
| |
Other ones are not needed.
|
|
|
|
| |
Signed-off-by: wm4 <wm4@nowhere>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Don't worry, your ~/.config/... paths are safe. This merely removes
handling of $XDG_CONFIG_DIRS for global paths.
Maybe there is a better solution for this, like still including the
"traditional" config dir. But I will leave the fine reading of this
(crappy) spec and fixing the code accordingly to someone else. So, if
anyone has interest in getting this behavior back, you will have to
write a patch. This patch should _also_ not break expected behavior.
Fixes #1060.
|
|
|
|
|
|
|
|
|
|
|
| |
The last demuxed file position (demuxer->filepos) is used to estimate
the total playback percentage in files with possible timestamp resets
(like MPEG-PS). Until know, reading from any stream set this position
freely. This makes the position jump around.
Fix this by allowing icnreasing file position only. Reset it on seeking.
With crazy formats, this still could go wrong, but there's only so much
you can do.
|
|
|
|
| |
Requested by ChrisK2.
|
|
|
|
|
|
|
| |
If a playlist is loaded from the internal playlist (like
"mpv playlist.m3u"), then attempt to resume from it.
CC: @mpv-player/stable
|
| |
|
|
|
|
|
|
| |
HLS streams as demuxed by libavformat have no track title metadata. So
show the HLS bitrate if no title is set. Could be useless or annoying,
so it's a bit controversial, I guess.
|
|
|
|
|
|
| |
--hls-bitrate=min/max lets you select the min or max bitrate. That's it.
Something more sophisticated might be possible, but is probably not even
worth the effort.
|
|
|
|
| |
Never really worked, and libquvi is probably a lost cause anyway.
|
|
|
|
|
| |
demux_info_get() used to be central, but was turned into a wrapper, and
now there was only one caller left. Get rid of it.
|
|
|
|
|
|
|
|
|
|
| |
This catches a few cases which basically call:
m_property_strdup_ro(..., ..., NULL)
which would return NULL strings. This should generally be avoided
(although it's allowed due to reasons), and it seems most callers
actually intend this to mean M_PROPERTY_UNAVAILABLE.
|
|
|
|
|
| |
In particular, don't allow to add any external subtitle tracks in idle
mode. This make no sense and would just lead to leaks or worse.
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
Because that might be a bad idea.
Note that remote playlists still can use any protocol marked with
is_safe and is_network, because the case of http-hosted playlists
containing URLs using other streaming protocols is not unusual.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Loading a playlist with --playlist from a sub-directory added the
playlist's base path twice: one time in the playlist demuxer, and then
again in playlist_parse_file(). The latter function is used only for
--playlist, so it worked when loading the playlist directly.
(This is probably a mess-up when the MPlayer playlist parsers were
replaced with newer code.)
CC: @mpv-player/stable
|
|
|
|
|
|
|
|
| |
The event was copied early, and wasn't released if it was rejected
instead of being added to the event queue. Fix by copying the event at a
point when it's certainly added to the event queue.
The dup_event_data() function is merely moved.
|
|
|
|
|
|
|
|
|
| |
Until now, you had to use --load-unsafe-playlists or --playlist to get
playlists loaded. Change this and always load playlists by default.
This still attempts to reject unsafe URLs. For example, trying to invoke
libavdevice pseudo-demuxer is explicitly prevented. Local paths and any
http links (and some more) are always allowed.
|
|
|
|
|
|
| |
Probably no observable effect, but it's more correct. Setting audio to
EOF could have bad effects otherwise (anywhere the player logic for
example decides whether EOF was reached, and such).
|
|
|
|
|
|
|
| |
There is no proper and exact spec (Matroska tradition), so we probably
have to rely on guessing for this.
Also see issue #1045.
|
|
|
|
|
|
|
|
|
| |
The audio/video sync code in player/audio.c calls ao_reset() each time
audio decoding is entered, but the player is paused, and there would be
more than 1 sample to skip to make audio start match with video start.
This caused a wakeup feedback loop with push.c.
CC: @mpv-player/stable
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When embedding a X window, it's hard to control whether it receives
mouse/keyboard input or not. It seems the X protocol itself makes this
hard (basically due to the outdated design mismatching with modern
toolkits), and we have to take care of these things explicitly.
Simply do this by manually querying and using the parent window event
flags.
This restores some MPlayer behavior (it doesn't add back exactly the
same code, but it's very similar).
This probably has some potential to interfere with libmpv embedding, so
bump the client API minor.
CC: @mpv-player/stable (if applied, client-api-changes.rst has to be
adjusted to include the 0.5.2 release)
|
| |
|
|
|
|
|
|
| |
In particular, use the note markup. The issue about rounded timestamps
is mostly with respect to Matroska (which usually rounds them to
milliseconds), which somewhat adds to the reliability issue.
|
|
|
|
|
| |
Make it clear that the value is linked to the StereoMode element. You
can't change this without adjusting demux_mkv.c.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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.
|
|
|
|
|
|
|
| |
Since we have to be portable, our options for creating temporary files
are somewhat limited. tmpfile() happens to be available everywhere, so
use that. This function doesn't allow having a "visible" filename or
location, so we use the magic string "TMP" for this.
|
|
|
|
|
|
|
| |
A (hopefully) temporary hack to make stream switching delays tolerable.
It's not clear how this should be handled (either executing a precise
seek on track switching, or always enabling all streams), so get this
issue out of the way for now by picking a rather low value.
|
| |
|
|
|
|
|
| |
Double-quote everything, eliminate unneeded evals and deprecated
`backtits` substitution syntax.
|
|
|
|
|
| |
Don't prepend each variable with __midentify__, just make them local
to the function.
|
| |
|
|
|
|
|
| |
$video_url can contain a question mark, which can be expanded to a
character in an existing file name if globbing is enabled.
|
| |
|
|
|
|
|
| |
This makes the ordered chapter code not think that a stream from the
local filesystem is not a local file (it checks uncached_type).
|
|
|
|
| |
Because why not.
|
|
|
|
| |
Check if mpi is NULL before accessing mpi->fields.
|
|
|
|
|
| |
ar_rate is set to -1 when autorepeat is disabled; there is no reason
for ar_delay to stay unsigned.
|
|
|
|
| |
Don't dereference fd and increment ictx->num_fds on fail.
|
|
|
|
|
|
| |
In the else branch pict_type is always 3, so pict_type != 3 is always
false. (Note that I have no idea of what it was supposed to do and it is
just an equivalent of the old behaviour.)
|
|
|
|
|
| |
pkt can't be NULL since it's initialized from ds->head, which is checked
at the beginning.
|
|
|
|
|
| |
Break the cycle on fail. Old code was checking if sh is NULL after
accessing it's fields.
|
|
|
|
|
| |
Only execute most of the opengl termination procedure if we actually have an
egl context.
|
| |
|