From a900b500ae57ff9fc6e7b5fcce1ba126f274838b Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Kempf Date: Tue, 6 Feb 2007 23:32:35 +0000 Subject: [PATCH] =?UTF-8?q?Patch=20from=20C=C3=A9dric=20Cocquebert=20for?= =?UTF-8?q?=20sharpen=20filter.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- THANKS | 2 +- modules/video_filter/sharpen.c | 14 +++++++++++++- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/THANKS b/THANKS index a7edc32ca5..84210d80ab 100644 --- a/THANKS +++ b/THANKS @@ -37,7 +37,7 @@ Brieuc Jeunhomme - bug fixes Bruno Vella - Italian localization Carlo Calabrò - Italian localization Carsten Gottbehüt - v4l hotplug fix -Cédric Cocquebert - Misc opengl effects for the OpenGL Video Output. "Panoramix" video filter for image walls with automatic attenuation +Cédric Cocquebert - Misc opengl effects for the OpenGL Video Output. "Panoramix" video filter for image walls with automatic attenuation. Fix on sharpen filter. Chris Clepper - OpenGL fix Christian Henz - libupnp service discovery plugin, CyberLink UPnP fixes Christof Baumgaertner - dbox web intf diff --git a/modules/video_filter/sharpen.c b/modules/video_filter/sharpen.c index 0ab4a85507..23bd6f8b49 100644 --- a/modules/video_filter/sharpen.c +++ b/modules/video_filter/sharpen.c @@ -51,6 +51,8 @@ static void Destroy ( vlc_object_t * ); static picture_t *Filter( filter_t *, picture_t * ); +#define FILTER_PREFIX "sharpen-" + /***************************************************************************** * Module descriptor *****************************************************************************/ @@ -66,6 +68,10 @@ vlc_module_begin(); set_callbacks( Create, Destroy ); vlc_module_end(); +static const char *ppsz_filter_options[] = { + "sigma", NULL +}; + /***************************************************************************** * filter_sys_t: Sharpen video filter descriptor ***************************************************************************** @@ -105,7 +111,13 @@ static int Create( vlc_object_t *p_this ) p_filter->pf_video_filter = Filter; - p_filter->p_sys->f_sigma = var_GetFloat(p_this, "sharpen-sigma"); + config_ChainParse( p_filter, FILTER_PREFIX, ppsz_filter_options, + p_filter->p_cfg ); + + var_Create( p_filter, FILTER_PREFIX "sigma", + VLC_VAR_FLOAT | VLC_VAR_DOINHERIT ); + + p_filter->p_sys->f_sigma = var_GetFloat(p_this, FILTER_PREFIX "sigma"); return VLC_SUCCESS; }