diff options
author | wm4 <wm4@nowhere> | 2015-03-03 15:29:07 +0100 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2015-03-03 15:29:07 +0100 |
commit | 9746e71efc36363f0b007fb73d886d5d35b5671a (patch) | |
tree | 4b20bbd43908d24dbe60049270e5b89b46e59206 /stream | |
parent | 1ba24d25853c0bb42526344345dc1c20741af338 (diff) | |
download | mpv-9746e71efc36363f0b007fb73d886d5d35b5671a.tar.bz2 mpv-9746e71efc36363f0b007fb73d886d5d35b5671a.tar.xz |
stream_cdda: add option to enable cdtext, and disable it by default
Fixes #1615.
Diffstat (limited to 'stream')
-rw-r--r-- | stream/stream_cdda.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/stream/stream_cdda.c b/stream/stream_cdda.c index 8bb940032c..2d1c78e160 100644 --- a/stream/stream_cdda.c +++ b/stream/stream_cdda.c @@ -64,6 +64,7 @@ typedef struct cdda_params { int skip; char *device; int span[2]; + int cdtext; } cdda_priv; #define OPT_BASE_STRUCT struct cdda_params @@ -86,6 +87,7 @@ const struct m_sub_options stream_cdda_conf = { OPT_FLAG("skip", skip, 0), OPT_STRING("device", device, 0), OPT_INTPAIR("span", span, 0), + OPT_FLAG("cdtext", cdtext, 0), {0} }, .size = sizeof(struct cdda_params), @@ -117,9 +119,11 @@ static const char *const cdtext_name[] = { #endif }; -static bool print_cdtext(stream_t *s, int track) +static void print_cdtext(stream_t *s, int track) { cdda_priv* p = (cdda_priv*)s->priv; + if (!p->cdtext) + return; #ifdef OLD_API cdtext_t *text = cdio_get_cdtext(p->cd->p_cdio, track); #else @@ -141,9 +145,7 @@ static bool print_cdtext(stream_t *s, int track) MP_INFO(s, " %s: '%s'\n", name, value); } } - return true; } - return false; } static void print_track_info(stream_t *s, int track) |