Remove filter_chain_GetFilter: unused and not thread-safe
authorRémi Denis-Courmont <remi@remlab.net>
Wed, 19 Aug 2009 20:44:57 +0000 (23:44 +0300)
committerRémi Denis-Courmont <remi@remlab.net>
Wed, 19 Aug 2009 21:05:21 +0000 (00:05 +0300)
include/vlc_filter.h
src/libvlccore.sym
src/misc/filter_chain.c

index 9ec2217..cd7943a 100644 (file)
@@ -299,16 +299,6 @@ VLC_EXPORT( int, filter_chain_AppendFromString, ( filter_chain_t *, const char *
  */
 VLC_EXPORT( int, filter_chain_DeleteFilter, ( filter_chain_t *, filter_t * ) );
 
-/**
- * Get filter by name of position in the filter chain.
- *
- * \param p_chain pointer to filter chain
- * \param i_position position of filter in filter chain
- * \param psz_name name of filter to get
- * \return filter object based on position or name provided
- */
-VLC_EXPORT( filter_t *, filter_chain_GetFilter, ( filter_chain_t *, int, const char * ) );
-
 /**
  * Get the number of filters in the filter chain.
  *
index 6381f5d..d98396a 100644 (file)
@@ -124,7 +124,6 @@ filter_chain_AppendFromString
 filter_chain_AudioFilter
 filter_chain_Delete
 filter_chain_DeleteFilter
-filter_chain_GetFilter
 filter_chain_GetFmtOut
 filter_chain_GetLength
 filter_chain_MouseFilter
index e470bef..255a25e 100644 (file)
@@ -201,37 +201,6 @@ int filter_chain_DeleteFilter( filter_chain_t *p_chain, filter_t *p_filter )
     return UpdateBufferFunctions( p_chain );
 }
 
-/**
- * Reading from the filter chain
- */
-filter_t *filter_chain_GetFilter( filter_chain_t *p_chain, int i_position,
-                                  const char *psz_name )
-{
-    if( psz_name )
-    {
-        if( i_position < 0 )
-            return NULL;
-
-        for( int i = 0; i < vlc_array_count( &p_chain->filters ); i++ )
-        {
-            filter_t *p_filter = vlc_array_item_at_index( &p_chain->filters, i );
-            if( !strcmp( p_filter->psz_object_name, psz_name ) )
-            {
-                if( i_position <= 0 )
-                    return p_filter;
-                i_position--;
-            }
-       }
-        return NULL;
-    }
-    else
-    {
-        if( i_position < 0 || i_position >= vlc_array_count( &p_chain->filters ) )
-            return NULL;
-        return vlc_array_item_at_index( &p_chain->filters, i_position );
-    }
-}
-
 int filter_chain_GetLength( filter_chain_t *p_chain )
 {
     return vlc_array_count( &p_chain->filters );