## RBPlayerGstFilter RBPlayerGstFilter — player interface for inserting filter elements |

## Synopsis

    #include <rb-player-gst-filter.h>

                        RBPlayerGstFilter;
    struct              RBPlayerGstFilterIface;
    gboolean            rb_player_gst_filter_add_filter     (RBPlayerGstFilter *player,
                                                             GstElement *element);
    gboolean            rb_player_gst_filter_remove_filter  (RBPlayerGstFilter *player,
                                                             GstElement *element);

## Object Hierarchy

      GInterface
       +----RBPlayerGstFilter

## Signals

      "filter-inserted"                                : No Recursion
      "filter-pre-remove"                              : No Recursion

## Description

This interface allows a caller to add filter elements to the GStreamer playback pipeline.

## Details

### RBPlayerGstFilter

    typedef struct _RBPlayerGstFilter RBPlayerGstFilter;

### struct RBPlayerGstFilterIface

    struct RBPlayerGstFilterIface {
    	GTypeInterface g_iface;

    	/* virtual functions */
    	gboolean (*add_filter)		(RBPlayerGstFilter *player, GstElement *element);
    	gboolean (*remove_filter) (RBPlayerGstFilter *player, GstElement *element);

    	/* signals */
    	void		(*filter_inserted) (RBPlayerGstFilter *player, GstElement *filter);
    	void		(*filter_pre_remove) (RBPlayerGstFilter *player, GstElement *filter);
    };

### rb_player_gst_filter_add_filter ()

    gboolean            rb_player_gst_filter_add_filter     (RBPlayerGstFilter *player,
                                                             GstElement *element);

Adds a new filter to the playback pipeline. The filter may not be inserted immediately. The 'filter-inserted' signal will be emitted when this actually happens.

`player` : | RBPlayerGstFilter implementation
`element` : | new filter element (or bin) to add
Returns : | TRUE if the filter will be added

### rb_player_gst_filter_remove_filter ()

    gboolean            rb_player_gst_filter_remove_filter  (RBPlayerGstFilter *player,
                                                             GstElement *element);

Removes a filter from the playback pipeline. The filter may not be removed immediately. The 'filter-pre-remove' signal will be emitted immediately before this actually happens.

`player` : | RBPlayerGstFilter implementation
`element` : | the filter element (or bin) to remove
Returns : | TRUE if the filter was found and will be removed

## Signal Details

### The `"filter-inserted"` signal

    void                user_function                      (RBPlayerGstFilter *player,
                                                            GObject           *filter,
                                                            gpointer           user_data)      : No Recursion

The 'filter-inserted' signal is emitted when the tee element has been inserted into the pipeline and fully linked

`player` : | the RBPlayerGstFilter implementation
`filter` : | the element which has been inserted
`user_data` : | user data set when the signal handler was connected.

### The `"filter-pre-remove"` signal

    void                user_function                      (RBPlayerGstFilter *player,
                                                            GObject           *filter,
                                                            gpointer           user_data)      : No Recursion

The 'filter-pre-remove' signal is emitted immediately before the element is unlinked and removed from the pipeline

`player` : | the RBPlayerGstFilter implementation
`filter` : | the element which is about to be removed
`user_data` : | user data set when the signal handler was connected.