summaryrefslogtreecommitdiffstats
path: root/core/cfg-mplayer.h
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2013-02-21 22:10:21 +0100
committerwm4 <wm4@nowhere>2013-02-23 00:07:11 +0100
commit9b7fb867f77bf0819bdfe1a4ceb55aade7db6f1b (patch)
tree99b1f9f42a5902ee56629306317f5fae431ab05c /core/cfg-mplayer.h
parente540e5d4da607420cc10f4c2b412aa0ff3d1fb5c (diff)
downloadmpv-9b7fb867f77bf0819bdfe1a4ceb55aade7db6f1b.tar.bz2
mpv-9b7fb867f77bf0819bdfe1a4ceb55aade7db6f1b.tar.xz
options: drop --opt:subopt option names
For all suboptions, "flat" options were available by separating the parent option and the sub option with ":", e.g. "--rawvideo:w=123". Drop this syntax and use "-" as separator. This means even suboptions are available as normal options now, e.g. "--rawvideo-w=123". The old syntax doesn't work anymore. Note that this is completely separate from actual suboptions. For example, "-rawvideo w=123:h=123" still works. (Not that this syntax is worth supporting, but it's needed anyway, for for other things like vf and vo suboptions.) As a consequence of this change, we also have to add new "no-" prefixed options for flag suboptions, so that "--no-input-default-bindings" works. ("--input-no-default-bindings" also works as a consequence of allowing "-input no-default-bindings" - they are handled by the same underlying option.) For --input, always use the full syntax in the manpage. There exist suboptions other than --input (like --tv, --rawvideo, etc.), but since they might be handled differently in the future, don't touch these yet. M_OPT_PREFIXED becomes the default, so remove it. As a minor unrelated cleanup, get rid of M_OPT_MERGE too and use the OPT_SUBSTRUCT() macro in some places. Unrelated: remove the duplicated --tv:buffersize option, fix a typo in changes.rst.
Diffstat (limited to 'core/cfg-mplayer.h')
-rw-r--r--core/cfg-mplayer.h16
1 files changed, 4 insertions, 12 deletions
diff --git a/core/cfg-mplayer.h b/core/cfg-mplayer.h
index 3a79702959..30096ff295 100644
--- a/core/cfg-mplayer.h
+++ b/core/cfg-mplayer.h
@@ -95,11 +95,8 @@ const m_option_t tvopts_conf[]={
{"saturation", &stream_tv_defaults.saturation, CONF_TYPE_INT, CONF_RANGE, -100, 100, NULL},
{"gain", &stream_tv_defaults.gain, CONF_TYPE_INT, CONF_RANGE, -1, 100, NULL},
#if defined(CONFIG_TV_V4L2)
- {"buffersize", &stream_tv_defaults.buffer_size, CONF_TYPE_INT, CONF_RANGE, 16, 1024, NULL},
{"amode", &stream_tv_defaults.amode, CONF_TYPE_INT, CONF_RANGE, 0, 3, NULL},
{"volume", &stream_tv_defaults.volume, CONF_TYPE_INT, CONF_RANGE, 0, 65535, NULL},
-#endif
-#if defined(CONFIG_TV_V4L2)
{"bass", &stream_tv_defaults.bass, CONF_TYPE_INT, CONF_RANGE, 0, 65535, NULL},
{"treble", &stream_tv_defaults.treble, CONF_TYPE_INT, CONF_RANGE, 0, 65535, NULL},
{"balance", &stream_tv_defaults.balance, CONF_TYPE_INT, CONF_RANGE, 0, 65535, NULL},
@@ -502,12 +499,8 @@ const m_option_t common_opts[] = {
OPT_FLAG("osd-bar", osd_bar_visible, 0),
OPT_FLOATRANGE("osd-bar-align-x", osd_bar_align_x, 0, -1.0, +1.0),
OPT_FLOATRANGE("osd-bar-align-y", osd_bar_align_y, 0, -1.0, +1.0),
- OPT_GENERAL("osd", osd_style, M_OPT_PREFIXED,
- .type = &m_option_type_subconfig_struct,
- .priv = (void*)&osd_style_conf),
- OPT_GENERAL("sub-text", sub_text_style, M_OPT_PREFIXED,
- .type = &m_option_type_subconfig_struct,
- .priv = (void*)&osd_style_conf),
+ OPT_SUBSTRUCT("osd", osd_style, osd_style_conf, 0),
+ OPT_SUBSTRUCT("sub-text", sub_text_style, osd_style_conf, 0),
{NULL, NULL, 0, 0, 0, 0, NULL}
};
@@ -523,7 +516,7 @@ const m_option_t tvscan_conf[]={
extern const struct m_sub_options image_writer_conf;
const m_option_t screenshot_conf[] = {
- OPT_SUBSTRUCT(screenshot_image_opts, image_writer_conf, M_OPT_MERGE),
+ OPT_SUBSTRUCT("", screenshot_image_opts, image_writer_conf, 0),
OPT_STRING("template", screenshot_template, 0),
{0},
};
@@ -694,8 +687,7 @@ const m_option_t mplayer_opts[]={
{"tvscan", (void *) tvscan_conf, CONF_TYPE_SUBCONFIG, 0, 0, 0, NULL},
#endif /* CONFIG_TV */
- {"screenshot", (void *) screenshot_conf, CONF_TYPE_SUBCONFIG,
- M_OPT_PREFIXED, 0, 0, NULL},
+ {"screenshot", (void *) screenshot_conf, CONF_TYPE_SUBCONFIG},
OPT_FLAG("list-properties", list_properties, CONF_GLOBAL),
{"identify", &mp_msg_levels[MSGT_IDENTIFY], CONF_TYPE_FLAG, CONF_GLOBAL, 0, MSGL_V, NULL},