summaryrefslogtreecommitdiffstats
path: root/player/core.h
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2013-12-24 17:46:14 +0100
committerwm4 <wm4@nowhere>2013-12-24 17:46:14 +0100
commit3720b3f17d4951ab839418b5cbfd1a85eb74adba (patch)
tree819b311b4c224ba2fd3dcd0efe8008a83f2cc938 /player/core.h
parent9292f537d661af16321fd35eb0016e830594863b (diff)
downloadmpv-3720b3f17d4951ab839418b5cbfd1a85eb74adba.tar.bz2
mpv-3720b3f17d4951ab839418b5cbfd1a85eb74adba.tar.xz
player: add --secondary-sid for displaying a second subtitle stream
This is relatively hacky, but it's Christmas, so it's ok. This does two things: 1. allow selecting two subtitle tracks, and 2. include a hack that renders the second subtitle always as toptitle. See manpage additions how to use this.
Diffstat (limited to 'player/core.h')
-rw-r--r--player/core.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/player/core.h b/player/core.h
index cad18a6b36..c016dcf4f7 100644
--- a/player/core.h
+++ b/player/core.h
@@ -35,6 +35,7 @@
#define INITIALIZED_ACODEC 1024
#define INITIALIZED_VCODEC 2048
#define INITIALIZED_SUB 4096
+#define INITIALIZED_SUB2 8192
#define INITIALIZED_ALL 0xFFFF
@@ -208,7 +209,7 @@ typedef struct MPContext {
struct dec_video *d_video;
struct dec_audio *d_audio;
- struct dec_sub *d_sub;
+ struct dec_sub *d_sub[2];
// Uses: accessing metadata (consider ordered chapters case, where the main
// demuxer defines metadata), or special purpose demuxers like TV.
@@ -439,9 +440,9 @@ void handle_force_window(struct MPContext *mpctx, bool reconfig);
void add_frame_pts(struct MPContext *mpctx, double pts);
// sub.c
-void reset_subtitles(struct MPContext *mpctx);
+void reset_subtitles(struct MPContext *mpctx, int order);
void uninit_subs(struct demuxer *demuxer);
-void reinit_subs(struct MPContext *mpctx);
+void reinit_subs(struct MPContext *mpctx, int order);
void update_osd_msg(struct MPContext *mpctx);
void update_subtitles(struct MPContext *mpctx);