mirror of https://github.com/mpv-player/mpv
options: list correct default value for --screenshot-template
Make the default value part of the option metadata, instead of doing this in the screenshot code. Makes more sense with --list-options and the command.c option metadata properties.
This commit is contained in:
parent
96f7c96da0
commit
9b8d3acc8b
|
@ -778,6 +778,7 @@ const struct MPOpts mp_default_opts = {
|
||||||
.sub_fix_timing = 1,
|
.sub_fix_timing = 1,
|
||||||
.sub_cp = "auto",
|
.sub_cp = "auto",
|
||||||
.mkv_subtitle_preroll_secs = 1.0,
|
.mkv_subtitle_preroll_secs = 1.0,
|
||||||
|
.screenshot_template = "shot%n",
|
||||||
|
|
||||||
.hwdec_codecs = "h264,vc1,wmv3",
|
.hwdec_codecs = "h264,vc1,wmv3",
|
||||||
|
|
||||||
|
|
|
@ -129,7 +129,7 @@ static char *create_fname(struct MPContext *mpctx, char *template,
|
||||||
struct tm *local_time = localtime(&raw_time);
|
struct tm *local_time = localtime(&raw_time);
|
||||||
|
|
||||||
if (!template || *template == '\0')
|
if (!template || *template == '\0')
|
||||||
template = "shot%n";
|
return NULL;
|
||||||
|
|
||||||
for (;;) {
|
for (;;) {
|
||||||
char *next = strchr(template, '%');
|
char *next = strchr(template, '%');
|
||||||
|
|
Loading…
Reference in New Issue