diff options
author | wm4 <wm4@nowhere> | 2020-04-15 17:03:37 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2020-04-15 17:04:00 +0200 |
commit | 6c02555397ca599a7ec9ea781e492631ecf1c7f2 (patch) | |
tree | aaeaf1c14e7cdcbbfcbdc331e5b31d0cf040b9ff /player/misc.c | |
parent | dae0652e19c568f578642993ad96531f56c5d259 (diff) | |
download | mpv-6c02555397ca599a7ec9ea781e492631ecf1c7f2.tar.bz2 mpv-6c02555397ca599a7ec9ea781e492631ecf1c7f2.tar.xz |
player: slightly improve use of secondary track selection limits
Apparently, this was a bit of a mess, which caused the bug fixed by
commit ec7f2388af2df. Try to improve this, and only use track selection
entries that exist.
Diffstat (limited to 'player/misc.c')
-rw-r--r-- | player/misc.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/player/misc.c b/player/misc.c index 4246c1c6f9..e8cebbc2e6 100644 --- a/player/misc.c +++ b/player/misc.c @@ -45,6 +45,12 @@ #include "core.h" #include "command.h" +const int num_ptracks[STREAM_TYPE_COUNT] = { + [STREAM_VIDEO] = 1, + [STREAM_AUDIO] = 1, + [STREAM_SUB] = 2, +}; + double rel_time_to_abs(struct MPContext *mpctx, struct m_rel_time t) { double length = get_time_length(mpctx); |