mirror of
https://github.com/mpv-player/mpv
synced 2025-03-30 22:09:20 +02:00
pphelp
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@8737 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
ff3b37804f
commit
f1d7c16d8d
@ -141,6 +141,7 @@
|
||||
{"oldpp", "MPlayer was compiled without opendivx library\n", CONF_TYPE_PRINT, CONF_NOCFG, 0, 0, NULL},
|
||||
#endif
|
||||
{"npp", "-npp has been removed, use -vop pp and read the fine manual\n", CONF_TYPE_PRINT, CONF_NOCFG, 0, 0, NULL},
|
||||
{"pphelp", &pp_help, CONF_TYPE_PRINT_INDIRECT, CONF_NOCFG, 0, 0, NULL},
|
||||
|
||||
{"vop", &vo_plugin_args, CONF_TYPE_STRING_LIST, 0, 0, 0, NULL},
|
||||
|
||||
|
@ -14,6 +14,7 @@ extern int use_old_pp;
|
||||
extern int sws_flags;
|
||||
extern int readPPOpt(void *, char *arg);
|
||||
extern void revertPPOpt(void *conf, char* opt);
|
||||
extern char *pp_help;
|
||||
|
||||
#ifdef HAVE_DIVX4ENCORE
|
||||
extern struct config divx4opts_conf[];
|
||||
|
@ -160,7 +160,7 @@ struct config jpeg_conf[]={
|
||||
extern int sws_flags;
|
||||
extern int readPPOpt(void *conf, char *arg);
|
||||
extern void revertPPOpt(void *conf, char* opt);
|
||||
|
||||
extern char* pp_help;
|
||||
|
||||
/*
|
||||
* CONF_TYPE_FUNC_FULL :
|
||||
|
@ -152,11 +152,6 @@ static int open(vf_instance_t *vf, char* args){
|
||||
if(!vf->priv->outfmt) return 0; // no csp match :(
|
||||
|
||||
if(args){
|
||||
if(!strcmp("help", args)){
|
||||
printf("%s", pp_help);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
hex_mode= strtol(args, &endptr, 0);
|
||||
if(*endptr){
|
||||
name= args;
|
||||
|
20
m_option.c
20
m_option.c
@ -765,7 +765,11 @@ m_option_type_t m_option_type_func = {
|
||||
/////////////////// Print
|
||||
|
||||
static int parse_print(m_option_t* opt,char *name, char *param, void* dst, int src) {
|
||||
mp_msg(MSGT_CFGPARSER, MSGL_INFO, "%s", (char *) opt->p);
|
||||
if(opt->type->flags&M_OPT_TYPE_INDIRECT)
|
||||
mp_msg(MSGT_CFGPARSER, MSGL_INFO, "%s", *(char **) opt->p);
|
||||
else
|
||||
mp_msg(MSGT_CFGPARSER, MSGL_INFO, "%s", (char *) opt->p);
|
||||
|
||||
if(opt->priv == NULL)
|
||||
exit(1); // Call something else instead ??
|
||||
return 1;
|
||||
@ -784,6 +788,20 @@ m_option_type_t m_option_type_print = {
|
||||
NULL
|
||||
};
|
||||
|
||||
m_option_type_t m_option_type_print_indirect = {
|
||||
"Print",
|
||||
"",
|
||||
0,
|
||||
M_OPT_TYPE_INDIRECT,
|
||||
parse_print,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL
|
||||
};
|
||||
|
||||
|
||||
/////////////////////// Subconfig
|
||||
#undef VAL
|
||||
#define VAL(x) (*(char***)(x))
|
||||
|
@ -17,6 +17,7 @@ extern m_option_type_t m_option_type_string_list;
|
||||
extern m_option_type_t m_option_type_position;
|
||||
|
||||
extern m_option_type_t m_option_type_print;
|
||||
extern m_option_type_t m_option_type_print_indirect;
|
||||
extern m_option_type_t m_option_type_subconfig;
|
||||
extern m_option_type_t m_option_type_imgfmt;
|
||||
|
||||
@ -59,6 +60,7 @@ extern m_option_type_t m_option_type_span;
|
||||
#define CONF_TYPE_FUNC (&m_option_type_func)
|
||||
#define CONF_TYPE_FUNC_PARAM (&m_option_type_func_param)
|
||||
#define CONF_TYPE_PRINT (&m_option_type_print)
|
||||
#define CONF_TYPE_PRINT_INDIRECT (&m_option_type_print_indirect)
|
||||
#define CONF_TYPE_FUNC_FULL (&m_option_type_func_full)
|
||||
#define CONF_TYPE_SUBCONFIG (&m_option_type_subconfig)
|
||||
#define CONF_TYPE_STRING_LIST (&m_option_type_string_list)
|
||||
|
Loading…
x
Reference in New Issue
Block a user