X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=modules%2Fvideo_filter%2Fbluescreen.c;h=61f07a40e1f948c1d47ad69836f13d420efb4dd3;hb=b42755d7fd2a64ad8c9d4c881388685abee9c463;hp=579e30fda2d88d3ac28ff339550e3e838a5330a6;hpb=5b55ee1bb0a0212b967f8f4a33824ffc6b7c7f09;p=vlc diff --git a/modules/video_filter/bluescreen.c b/modules/video_filter/bluescreen.c index 579e30fda2..61f07a40e1 100644 --- a/modules/video_filter/bluescreen.c +++ b/modules/video_filter/bluescreen.c @@ -29,7 +29,8 @@ # include "config.h" #endif -#include +#include +#include #include #include "vlc_filter.h" @@ -37,8 +38,8 @@ #define BLUESCREEN_HELP N_( \ "This effect, also known as \"greenscreen\" or \"chroma key\" blends " \ "the \"blue parts\" of the foreground image of the mosaic on the " \ - "background (like weather forcasts). You can choose the \"key\" " \ - "color for blending (blyyue by default)." ) + "background (like weather forecasts). You can choose the \"key\" " \ + "color for blending (blue by default)." ) #define BLUESCREENU_TEXT N_("Bluescreen U value") #define BLUESCREENU_LONGTEXT N_( \ @@ -74,29 +75,29 @@ static int BluescreenCallback( vlc_object_t *, char const *, /***************************************************************************** * Module descriptor *****************************************************************************/ -vlc_module_begin(); - set_description( _("Bluescreen video filter") ); - set_shortname( _("Bluescreen" )); - set_help( BLUESCREEN_HELP ); - set_category( CAT_VIDEO ); - set_subcategory( SUBCAT_VIDEO_VFILTER ); - set_capability( "video filter2", 0 ); - add_shortcut( "bluescreen" ); - set_callbacks( Create, Destroy ); +vlc_module_begin () + set_description( N_("Bluescreen video filter") ) + set_shortname( N_("Bluescreen" )) + set_help( BLUESCREEN_HELP ) + set_category( CAT_VIDEO ) + set_subcategory( SUBCAT_VIDEO_VFILTER ) + set_capability( "video filter2", 0 ) + add_shortcut( "bluescreen" ) + set_callbacks( Create, Destroy ) add_integer_with_range( CFG_PREFIX "u", 120, 0, 255, NULL, - BLUESCREENU_TEXT, BLUESCREENU_LONGTEXT, false ); + BLUESCREENU_TEXT, BLUESCREENU_LONGTEXT, false ) add_integer_with_range( CFG_PREFIX "v", 90, 0, 255, NULL, - BLUESCREENV_TEXT, BLUESCREENV_LONGTEXT, false ); + BLUESCREENV_TEXT, BLUESCREENV_LONGTEXT, false ) add_integer_with_range( CFG_PREFIX "ut", 17, 0, 255, NULL, BLUESCREENUTOL_TEXT, BLUESCREENUTOL_LONGTEXT, - false ); + false ) add_integer_with_range( CFG_PREFIX "vt", 17, 0, 255, NULL, BLUESCREENVTOL_TEXT, BLUESCREENVTOL_LONGTEXT, - false ); -vlc_module_end(); + false ) +vlc_module_end () -static const char *ppsz_filter_options[] = { +static const char *const ppsz_filter_options[] = { "u", "v", "ut", "vt", NULL }; @@ -123,10 +124,7 @@ static int Create( vlc_object_t *p_this ) /* Allocate structure */ p_filter->p_sys = malloc( sizeof( filter_sys_t ) ); if( p_filter->p_sys == NULL ) - { - msg_Err( p_filter, "out of memory" ); return VLC_ENOMEM; - } p_sys = p_filter->p_sys; config_ChainParse( p_filter, CFG_PREFIX, ppsz_filter_options,