From 7e97a49194765432743be1d28ffbc1b9119f8ef2 Mon Sep 17 00:00:00 2001 From: Gildas Bazin Date: Fri, 23 Apr 2004 20:01:59 +0000 Subject: [PATCH] * modules/video_filter/*: implemented a forwarding vout_vaControl(). --- modules/video_filter/adjust.c | 11 ++++++++++- modules/video_filter/clone.c | 16 +++++++++++++++- modules/video_filter/crop.c | 11 ++++++++++- modules/video_filter/distort.c | 11 ++++++++++- modules/video_filter/invert.c | 11 ++++++++++- modules/video_filter/logo.c | 11 ++++++++++- modules/video_filter/motionblur.c | 11 ++++++++++- modules/video_filter/transform.c | 11 ++++++++++- modules/video_filter/wall.c | 22 +++++++++++++++++++++- 9 files changed, 106 insertions(+), 9 deletions(-) diff --git a/modules/video_filter/adjust.c b/modules/video_filter/adjust.c index e55e66296c..cc5f4e2fee 100644 --- a/modules/video_filter/adjust.c +++ b/modules/video_filter/adjust.c @@ -2,7 +2,7 @@ * adjust.c : Contrast/Hue/Saturation/Brightness video plugin for vlc ***************************************************************************** * Copyright (C) 2000, 2001, 2002, 2003 VideoLAN - * $Id: adjust.c,v 1.17 2004/01/25 20:05:28 hartman Exp $ + * $Id$ * * Authors: Simon Latapie * @@ -99,6 +99,14 @@ inline static int32_t clip( int32_t a ) return (a > 255) ? 255 : (a < 0) ? 0 : a; } +/***************************************************************************** + * Control: control facility for the vout (forwards to child vout) + *****************************************************************************/ +static int Control( vout_thread_t *p_vout, int i_query, va_list args ) +{ + return vout_vaControl( p_vout->p_sys->p_vout, i_query, args ); +} + /***************************************************************************** * Create: allocates adjust video thread output method ***************************************************************************** @@ -121,6 +129,7 @@ static int Create( vlc_object_t *p_this ) p_vout->pf_manage = NULL; p_vout->pf_render = Render; p_vout->pf_display = NULL; + p_vout->pf_control = Control; var_Create( p_vout, "contrast", VLC_VAR_FLOAT | VLC_VAR_DOINHERIT ); var_Create( p_vout, "brightness", VLC_VAR_FLOAT | VLC_VAR_DOINHERIT ); diff --git a/modules/video_filter/clone.c b/modules/video_filter/clone.c index da443e4cfc..3198591ac5 100644 --- a/modules/video_filter/clone.c +++ b/modules/video_filter/clone.c @@ -2,7 +2,7 @@ * clone.c : Clone video plugin for vlc ***************************************************************************** * Copyright (C) 2002, 2003 VideoLAN - * $Id: clone.c,v 1.12 2004/01/25 20:05:28 hartman Exp $ + * $Id$ * * Authors: Samuel Hocevar * @@ -88,6 +88,19 @@ struct vout_sys_t vout_thread_t **pp_vout; }; +/***************************************************************************** + * Control: control facility for the vout (forwards to child vout) + *****************************************************************************/ +static int Control( vout_thread_t *p_vout, int i_query, va_list args ) +{ + int i_vout; + for( i_vout = 0; i_vout < p_vout->p_sys->i_clones; i_vout++ ) + { + vout_vaControl( p_vout->p_sys->pp_vout[ i_vout ], i_query, args ); + } + return VLC_SUCCESS; +} + /***************************************************************************** * Create: allocates Clone video thread output method ***************************************************************************** @@ -111,6 +124,7 @@ static int Create( vlc_object_t *p_this ) p_vout->pf_manage = NULL; p_vout->pf_render = Render; p_vout->pf_display = NULL; + p_vout->pf_control = Control; psz_clonelist = config_GetPsz( p_vout, "clone-vout-list" ); if( psz_clonelist ) diff --git a/modules/video_filter/crop.c b/modules/video_filter/crop.c index 96fa478b9d..b5fb82188a 100644 --- a/modules/video_filter/crop.c +++ b/modules/video_filter/crop.c @@ -2,7 +2,7 @@ * crop.c : Crop video plugin for vlc ***************************************************************************** * Copyright (C) 2002, 2003 VideoLAN - * $Id: crop.c,v 1.15 2004/01/25 20:05:28 hartman Exp $ + * $Id$ * * Authors: Samuel Hocevar * @@ -88,6 +88,14 @@ struct vout_sys_t vlc_bool_t b_changed; }; +/***************************************************************************** + * Control: control facility for the vout (forwards to child vout) + *****************************************************************************/ +static int Control( vout_thread_t *p_vout, int i_query, va_list args ) +{ + return vout_vaControl( p_vout->p_sys->p_vout, i_query, args ); +} + /***************************************************************************** * Create: allocates Crop video thread output method ***************************************************************************** @@ -110,6 +118,7 @@ static int Create( vlc_object_t *p_this ) p_vout->pf_manage = Manage; p_vout->pf_render = Render; p_vout->pf_display = NULL; + p_vout->pf_control = Control; return VLC_SUCCESS; } diff --git a/modules/video_filter/distort.c b/modules/video_filter/distort.c index ab27a8280e..c26c97050e 100644 --- a/modules/video_filter/distort.c +++ b/modules/video_filter/distort.c @@ -2,7 +2,7 @@ * distort.c : Misc video effects plugin for vlc ***************************************************************************** * Copyright (C) 2000, 2001, 2002, 2003 VideoLAN - * $Id: distort.c,v 1.14 2004/01/25 20:05:28 hartman Exp $ + * $Id$ * * Authors: Samuel Hocevar * @@ -90,6 +90,14 @@ struct vout_sys_t mtime_t last_date; }; +/***************************************************************************** + * Control: control facility for the vout (forwards to child vout) + *****************************************************************************/ +static int Control( vout_thread_t *p_vout, int i_query, va_list args ) +{ + return vout_vaControl( p_vout->p_sys->p_vout, i_query, args ); +} + /***************************************************************************** * Create: allocates Distort video thread output method ***************************************************************************** @@ -113,6 +121,7 @@ static int Create( vlc_object_t *p_this ) p_vout->pf_manage = NULL; p_vout->pf_render = Render; p_vout->pf_display = NULL; + p_vout->pf_control = Control; p_vout->p_sys->i_mode = 0; diff --git a/modules/video_filter/invert.c b/modules/video_filter/invert.c index 189728daba..29fad2d658 100644 --- a/modules/video_filter/invert.c +++ b/modules/video_filter/invert.c @@ -2,7 +2,7 @@ * invert.c : Invert video plugin for vlc ***************************************************************************** * Copyright (C) 2000, 2001, 2002, 2003 VideoLAN - * $Id: invert.c,v 1.9 2004/01/25 03:28:41 hartman Exp $ + * $Id$ * * Authors: Samuel Hocevar * @@ -66,6 +66,14 @@ struct vout_sys_t vout_thread_t *p_vout; }; +/***************************************************************************** + * Control: control facility for the vout (forwards to child vout) + *****************************************************************************/ +static int Control( vout_thread_t *p_vout, int i_query, va_list args ) +{ + return vout_vaControl( p_vout->p_sys->p_vout, i_query, args ); +} + /***************************************************************************** * Create: allocates Invert video thread output method ***************************************************************************** @@ -88,6 +96,7 @@ static int Create( vlc_object_t *p_this ) p_vout->pf_manage = NULL; p_vout->pf_render = Render; p_vout->pf_display = NULL; + p_vout->pf_control = Control; return VLC_SUCCESS; } diff --git a/modules/video_filter/logo.c b/modules/video_filter/logo.c index 4144fb187f..357e0c2648 100644 --- a/modules/video_filter/logo.c +++ b/modules/video_filter/logo.c @@ -2,7 +2,7 @@ * logo.c : logo video plugin for vlc ***************************************************************************** * Copyright (C) 2003-2004 VideoLAN - * $Id: logo.c,v 1.10 2004/01/25 20:05:28 hartman Exp $ + * $Id$ * * Authors: Simon Latapie * @@ -100,6 +100,14 @@ struct vout_sys_t int trans; }; +/***************************************************************************** + * Control: control facility for the vout (forwards to child vout) + *****************************************************************************/ +static int Control( vout_thread_t *p_vout, int i_query, va_list args ) +{ + return vout_vaControl( p_vout->p_sys->p_vout, i_query, args ); +} + /***************************************************************************** * Create: allocates logo video thread output method ***************************************************************************** @@ -122,6 +130,7 @@ static int Create( vlc_object_t *p_this ) p_vout->pf_manage = NULL; p_vout->pf_render = Render; p_vout->pf_display = NULL; + p_vout->pf_control = Control; return VLC_SUCCESS; } diff --git a/modules/video_filter/motionblur.c b/modules/video_filter/motionblur.c index 94f48d5c4c..b94b3f767d 100644 --- a/modules/video_filter/motionblur.c +++ b/modules/video_filter/motionblur.c @@ -2,7 +2,7 @@ * motion_blur.c : motion blur filter for vlc ***************************************************************************** * Copyright (C) 2000, 2001, 2002, 2003 VideoLAN - * $Id: motionblur.c,v 1.15 2004/01/25 20:05:28 hartman Exp $ + * $Id$ * * Authors: Sigmund Augdal * @@ -82,6 +82,14 @@ struct vout_sys_t picture_t *p_lastpic; }; +/***************************************************************************** + * Control: control facility for the vout (forwards to child vout) + *****************************************************************************/ +static int Control( vout_thread_t *p_vout, int i_query, va_list args ) +{ + return vout_vaControl( p_vout->p_sys->p_vout, i_query, args ); +} + /***************************************************************************** * Create: allocates Deinterlace video thread output method ***************************************************************************** @@ -104,6 +112,7 @@ static int Create( vlc_object_t *p_this ) p_vout->pf_manage = NULL; p_vout->pf_render = Render; p_vout->pf_display = NULL; + p_vout->pf_control = Control; p_vout->p_sys->i_factor = config_GetInt( p_vout, "blur-factor" ); p_vout->p_sys->b_double_rate = 0; diff --git a/modules/video_filter/transform.c b/modules/video_filter/transform.c index 5c386b6436..c39028a562 100644 --- a/modules/video_filter/transform.c +++ b/modules/video_filter/transform.c @@ -2,7 +2,7 @@ * transform.c : transform image module for vlc ***************************************************************************** * Copyright (C) 2000-2004 VideoLAN - * $Id: transform.c,v 1.18 2004/01/25 20:05:28 hartman Exp $ + * $Id$ * * Authors: Samuel Hocevar * @@ -87,6 +87,14 @@ struct vout_sys_t vout_thread_t *p_vout; }; +/***************************************************************************** + * Control: control facility for the vout (forwards to child vout) + *****************************************************************************/ +static int Control( vout_thread_t *p_vout, int i_query, va_list args ) +{ + return vout_vaControl( p_vout->p_sys->p_vout, i_query, args ); +} + /***************************************************************************** * Create: allocates Transform video thread output method ***************************************************************************** @@ -110,6 +118,7 @@ static int Create( vlc_object_t *p_this ) p_vout->pf_manage = NULL; p_vout->pf_render = Render; p_vout->pf_display = NULL; + p_vout->pf_control = Control; /* Look what method was requested */ psz_method = config_GetPsz( p_vout, "transform-type" ); diff --git a/modules/video_filter/wall.c b/modules/video_filter/wall.c index e307b31e61..32845c1ecf 100644 --- a/modules/video_filter/wall.c +++ b/modules/video_filter/wall.c @@ -2,7 +2,7 @@ * wall.c : Wall video plugin for vlc ***************************************************************************** * Copyright (C) 2000, 2001, 2002, 2003 VideoLAN - * $Id: wall.c,v 1.13 2004/01/25 20:05:28 hartman Exp $ + * $Id$ * * Authors: Samuel Hocevar * @@ -94,6 +94,25 @@ struct vout_sys_t } *pp_vout; }; +/***************************************************************************** + * Control: control facility for the vout (forwards to child vout) + *****************************************************************************/ +static int Control( vout_thread_t *p_vout, int i_query, va_list args ) +{ + int i_row, i_col, i_vout = 0; + + for( i_row = 0; i_row < p_vout->p_sys->i_row; i_row++ ) + { + for( i_col = 0; i_col < p_vout->p_sys->i_col; i_col++ ) + { + vout_vaControl( p_vout->p_sys->pp_vout[ i_vout ].p_vout, + i_query, args ); + i_vout++; + } + } + return VLC_SUCCESS; +} + /***************************************************************************** * Create: allocates Wall video thread output method ***************************************************************************** @@ -118,6 +137,7 @@ static int Create( vlc_object_t *p_this ) p_vout->pf_manage = NULL; p_vout->pf_render = Render; p_vout->pf_display = NULL; + p_vout->pf_control = Control; /* Look what method was requested */ p_vout->p_sys->i_col = config_GetInt( p_vout, "wall-cols" ); -- 2.39.2