Commit 0aeed985 authored by Sam Hocevar's avatar Sam Hocevar

* ./plugins/filters/*: fixed inconsistencies.

parent e9577415
......@@ -2,7 +2,7 @@
* clone.c : Clone video plugin for vlc
*****************************************************************************
* Copyright (C) 2002 VideoLAN
* $Id: clone.c,v 1.3 2002/05/27 19:35:41 sam Exp $
* $Id: clone.c,v 1.4 2002/05/28 22:49:25 sam Exp $
*
* Authors: Samuel Hocevar <sam@zoy.org>
*
......@@ -45,7 +45,7 @@ static void vout_getfunctions( function_list_t * p_function_list );
*****************************************************************************/
MODULE_CONFIG_START
ADD_CATEGORY_HINT( N_("Miscellaneous"), NULL )
ADD_INTEGER ( "clone_count", 2, NULL, N_("Number of clones"),
ADD_INTEGER ( "clone-count", 2, NULL, N_("Number of clones"),
N_("Select the number of videowindows in which to clone the video") )
MODULE_CONFIG_STOP
......@@ -122,7 +122,7 @@ static int vout_Create( vout_thread_t *p_vout )
}
/* Look what method was requested */
p_vout->p_sys->i_clones = config_GetIntVariable( "clone_count" );
p_vout->p_sys->i_clones = config_GetIntVariable( "clone-count" );
p_vout->p_sys->i_clones = __MAX( 1, __MIN( 99, p_vout->p_sys->i_clones ) );
......
......@@ -2,7 +2,7 @@
* deinterlace.c : deinterlacer plugin for vlc
*****************************************************************************
* Copyright (C) 2000, 2001 VideoLAN
* $Id: deinterlace.c,v 1.11 2002/05/27 19:35:41 sam Exp $
* $Id: deinterlace.c,v 1.12 2002/05/28 22:49:25 sam Exp $
*
* Authors: Samuel Hocevar <sam@zoy.org>
*
......@@ -50,7 +50,7 @@ static void *memblend( void *, const void *, const void *, size_t );
*****************************************************************************/
MODULE_CONFIG_START
ADD_CATEGORY_HINT( N_("Miscellaneous"), NULL )
ADD_STRING ( "deinterlace_mode", "bob", NULL, N_("Deinterlace mode"),
ADD_STRING ( "deinterlace-mode", "bob", NULL, N_("Deinterlace mode"),
N_("one of 'bob' and 'blend'") )
MODULE_CONFIG_STOP
......@@ -127,26 +127,32 @@ static int vout_Create( vout_thread_t *p_vout )
}
/* Look what method was requested */
if( !(psz_method = config_GetPszVariable( "filter" )) )
{
intf_ErrMsg( "vout error: configuration variable %s empty",
"filter" );
return( 1 );
}
psz_method = config_GetPszVariable( "deinterlace-mode" );
if( !strcmp( psz_method, "bob" ) )
if( psz_method == NULL )
{
intf_ErrMsg( "vout error: configuration variable %s empty",
"deinterlace-mode" );
intf_ErrMsg( "filter error: no valid deinterlace mode provided, "
"using deinterlace:bob" );
p_vout->p_sys->i_mode = DEINTERLACE_MODE_BOB;
}
else if( !strcmp( psz_method, "blend" ) )
{
p_vout->p_sys->i_mode = DEINTERLACE_MODE_BLEND;
}
else
{
intf_ErrMsg( "filter error: no valid deinterlace mode provided, "
"using deinterlace:bob" );
p_vout->p_sys->i_mode = DEINTERLACE_MODE_BOB;
if( !strcmp( psz_method, "bob" ) )
{
p_vout->p_sys->i_mode = DEINTERLACE_MODE_BOB;
}
else if( !strcmp( psz_method, "blend" ) )
{
p_vout->p_sys->i_mode = DEINTERLACE_MODE_BLEND;
}
else
{
intf_ErrMsg( "filter error: no valid deinterlace mode provided, "
"using deinterlace:bob" );
p_vout->p_sys->i_mode = DEINTERLACE_MODE_BOB;
}
}
free( psz_method );
......
......@@ -2,7 +2,7 @@
* distort.c : Misc video effects plugin for vlc
*****************************************************************************
* Copyright (C) 2000, 2001 VideoLAN
* $Id: distort.c,v 1.12 2002/05/27 19:35:41 sam Exp $
* $Id: distort.c,v 1.13 2002/05/28 22:49:25 sam Exp $
*
* Authors: Samuel Hocevar <sam@zoy.org>
*
......@@ -50,7 +50,7 @@ static void vout_getfunctions( function_list_t * p_function_list );
*****************************************************************************/
MODULE_CONFIG_START
ADD_CATEGORY_HINT( N_("Miscellaneous"), NULL )
ADD_STRING ( "distort_mode", "wave", NULL, N_("distort mode"),
ADD_STRING ( "distort-mode", "wave", NULL, N_("distort mode"),
N_("one of \"wave\" and \"ripple\"") )
MODULE_CONFIG_STOP
......@@ -161,11 +161,11 @@ static int vout_Create( vout_thread_t *p_vout )
/* No method given in commandline. Look what method was
requested in configuration system */
if( !(psz_method = psz_method_tmp
= config_GetPszVariable( "distort_mode" )) )
= config_GetPszVariable( "distort-mode" )) )
{
intf_ErrMsg( "vout error: configuration variable %s empty "
"using wave",
"distort_mode" );
"distort-mode" );
p_vout->p_sys->i_mode = DISTORT_MODE_WAVE;
}
else {
......
......@@ -2,7 +2,7 @@
* transform.c : transform image plugin for vlc
*****************************************************************************
* Copyright (C) 2000, 2001 VideoLAN
* $Id: transform.c,v 1.11 2002/05/27 19:35:41 sam Exp $
* $Id: transform.c,v 1.12 2002/05/28 22:49:25 sam Exp $
*
* Authors: Samuel Hocevar <sam@zoy.org>
*
......@@ -51,7 +51,7 @@ static void vout_getfunctions( function_list_t * p_function_list );
*****************************************************************************/
MODULE_CONFIG_START
ADD_CATEGORY_HINT( N_("Miscellaneous"), NULL )
ADD_STRING("transform_type", "90", NULL, N_("Transform type"),
ADD_STRING("transform-type", "90", NULL, N_("Transform type"),
N_("One of '90', '180', '270', 'hflip' and 'vflip'"))
MODULE_CONFIG_STOP
......@@ -117,7 +117,7 @@ static void vout_getfunctions( function_list_t * p_function_list )
*****************************************************************************/
static int vout_Create( vout_thread_t *p_vout )
{
char *psz_method, *psz_method_tmp;
char *psz_method;
/* Allocate structure */
p_vout->p_sys = malloc( sizeof( vout_sys_t ) );
......@@ -128,11 +128,12 @@ static int vout_Create( vout_thread_t *p_vout )
}
/* Look what method was requested */
if( !(psz_method = psz_method_tmp
= config_GetPszVariable( "transform_type" )) )
psz_method = config_GetPszVariable( "transform-type" );
if( psz_method == NULL )
{
intf_ErrMsg( "vout error: configuration variable %s empty",
"transform_type" );
"transform-type" );
intf_ErrMsg( "filter error: no valid transform mode provided, "
"using '90'" );
p_vout->p_sys->i_mode = TRANSFORM_MODE_90;
......@@ -172,10 +173,10 @@ static int vout_Create( vout_thread_t *p_vout )
p_vout->p_sys->i_mode = TRANSFORM_MODE_90;
p_vout->p_sys->b_rotation = 1;
}
free( psz_method );
}
free( psz_method_tmp );
return( 0 );
}
......
......@@ -2,7 +2,7 @@
* wall.c : Wall video plugin for vlc
*****************************************************************************
* Copyright (C) 2000, 2001 VideoLAN
* $Id: wall.c,v 1.18 2002/05/27 19:35:41 sam Exp $
* $Id: wall.c,v 1.19 2002/05/28 22:49:25 sam Exp $
*
* Authors: Samuel Hocevar <sam@zoy.org>
*
......@@ -45,13 +45,13 @@ static void vout_getfunctions( function_list_t * p_function_list );
*****************************************************************************/
MODULE_CONFIG_START
ADD_CATEGORY_HINT( N_("Miscellaneous"), NULL )
ADD_INTEGER ( "wall_cols", 3, NULL, N_("Number of columns"),
ADD_INTEGER ( "wall-cols", 3, NULL, N_("Number of columns"),
N_("Select the number of horizontal videowindows in which "
"to split the video") )
ADD_INTEGER ( "wall_rows", 3, NULL, N_("Number of rows"),
ADD_INTEGER ( "wall-rows", 3, NULL, N_("Number of rows"),
N_("Select the number of vertical videowindows in which "
"to split the video") )
ADD_STRING ( "wall_active", NULL, NULL, N_("Active windows"),
ADD_STRING ( "wall-active", NULL, NULL, N_("Active windows"),
N_("comma separated list of active windows, defaults to all") )
MODULE_CONFIG_STOP
......@@ -138,8 +138,8 @@ static int vout_Create( vout_thread_t *p_vout )
}
/* Look what method was requested */
p_vout->p_sys->i_col = config_GetIntVariable( "wall_cols" );
p_vout->p_sys->i_row = config_GetIntVariable( "wall_rows" );
p_vout->p_sys->i_col = config_GetIntVariable( "wall-cols" );
p_vout->p_sys->i_row = config_GetIntVariable( "wall-rows" );
p_vout->p_sys->i_col = __MAX( 1, __MIN( 15, p_vout->p_sys->i_col ) );
p_vout->p_sys->i_row = __MAX( 1, __MIN( 15, p_vout->p_sys->i_row ) );
......@@ -158,7 +158,7 @@ static int vout_Create( vout_thread_t *p_vout )
return( 1 );
}
psz_method_tmp = psz_method = config_GetPszVariable( "wall_active" );
psz_method_tmp = psz_method = config_GetPszVariable( "wall-active" );
/* If no trailing vout are specified, take them all */
if( psz_method == NULL )
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment