diff options
author | Wim Taymans <wim.taymans@collabora.co.uk> | 2012-01-26 19:28:01 +0100 |
---|---|---|
committer | Wim Taymans <wim.taymans@collabora.co.uk> | 2012-01-26 19:28:46 +0100 |
commit | 2a8c98fe238df9c72ef72dcd9f2d88c19b37e78f (patch) | |
tree | 469285ca94febd829b01c1074686fb12b79027ce /gst/gstpad.h | |
parent | e122bae3ad83d384f4fc1806b2bf7ee6e91780c3 (diff) |
pad: add user data to chain functions
Diffstat (limited to 'gst/gstpad.h')
-rw-r--r-- | gst/gstpad.h | 40 |
1 files changed, 30 insertions, 10 deletions
diff --git a/gst/gstpad.h b/gst/gstpad.h index d4a66de26..26b2d3ff1 100644 --- a/gst/gstpad.h +++ b/gst/gstpad.h @@ -647,25 +647,33 @@ struct _GstPad { GstPadMode mode; GstPadActivateFunction activatefunc; + gpointer activatedata; GDestroyNotify activatenotify; GstPadActivateModeFunction activatemodefunc; + gpointer activatemodedata; GDestroyNotify activatemodenotify; /* pad link */ GstPad *peer; GstPadLinkFunction linkfunc; + gpointer linkdata; GDestroyNotify linknotify; GstPadUnlinkFunction unlinkfunc; + gpointer unlinkdata; GDestroyNotify unlinknotify; /* data transport functions */ GstPadChainFunction chainfunc; + gpointer chaindata; GDestroyNotify chainnotify; GstPadChainListFunction chainlistfunc; + gpointer chainlistdata; GDestroyNotify chainlistnotify; GstPadGetRangeFunction getrangefunc; + gpointer getrangedata; GDestroyNotify getrangenotify; GstPadEventFunction eventfunc; + gpointer eventdata; GDestroyNotify eventnotify; /* pad offset */ @@ -673,10 +681,12 @@ struct _GstPad { /* generic query method */ GstPadQueryFunction queryfunc; + gpointer querydata; GDestroyNotify querynotify; /* internal links */ GstPadIterIntLinkFunction iterintlinkfunc; + gpointer iterintlinkdata; GDestroyNotify iterintlinknotify; /* counts number of probes attached. */ @@ -843,41 +853,49 @@ void gst_pad_sticky_events_foreach (GstPad *pad, Gs /* data passing setup functions */ void gst_pad_set_activate_function_full (GstPad *pad, GstPadActivateFunction activate, + gpointer user_data, GDestroyNotify notify); void gst_pad_set_activatemode_function_full (GstPad *pad, GstPadActivateModeFunction activatemode, + gpointer user_data, GDestroyNotify notify); /* data passing functions */ void gst_pad_set_chain_function_full (GstPad *pad, GstPadChainFunction chain, + gpointer user_data, GDestroyNotify notify); void gst_pad_set_chain_list_function_full (GstPad *pad, GstPadChainListFunction chainlist, + gpointer user_data, GDestroyNotify notify); void gst_pad_set_getrange_function_full (GstPad *pad, GstPadGetRangeFunction get, + gpointer user_data, GDestroyNotify notify); void gst_pad_set_event_function_full (GstPad *pad, GstPadEventFunction event, + gpointer user_data, GDestroyNotify notify); -#define gst_pad_set_activate_function(p,f) gst_pad_set_activate_function_full((p),(f),NULL) -#define gst_pad_set_activatemode_function(p,f) gst_pad_set_activatemode_function_full((p),(f),NULL) -#define gst_pad_set_chain_function(p,f) gst_pad_set_chain_function_full((p),(f),NULL) -#define gst_pad_set_chain_list_function(p,f) gst_pad_set_chain_list_function_full((p),(f),NULL) -#define gst_pad_set_getrange_function(p,f) gst_pad_set_getrange_function_full((p),(f),NULL) -#define gst_pad_set_event_function(p,f) gst_pad_set_event_function_full((p),(f),NULL) +#define gst_pad_set_activate_function(p,f) gst_pad_set_activate_function_full((p),(f),NULL,NULL) +#define gst_pad_set_activatemode_function(p,f) gst_pad_set_activatemode_function_full((p),(f),NULL,NULL) +#define gst_pad_set_chain_function(p,f) gst_pad_set_chain_function_full((p),(f),NULL,NULL) +#define gst_pad_set_chain_list_function(p,f) gst_pad_set_chain_list_function_full((p),(f),NULL,NULL) +#define gst_pad_set_getrange_function(p,f) gst_pad_set_getrange_function_full((p),(f),NULL,NULL) +#define gst_pad_set_event_function(p,f) gst_pad_set_event_function_full((p),(f),NULL,NULL) /* pad links */ void gst_pad_set_link_function_full (GstPad *pad, GstPadLinkFunction link, + gpointer user_data, GDestroyNotify notify); void gst_pad_set_unlink_function_full (GstPad *pad, GstPadUnlinkFunction unlink, + gpointer user_data, GDestroyNotify notify); -#define gst_pad_set_link_function(p,f) gst_pad_set_link_function_full((p),(f),NULL) -#define gst_pad_set_unlink_function(p,f) gst_pad_set_unlink_function_full((p),(f),NULL) +#define gst_pad_set_link_function(p,f) gst_pad_set_link_function_full((p),(f),NULL,NULL) +#define gst_pad_set_unlink_function(p,f) gst_pad_set_unlink_function_full((p),(f),NULL,NULL) gboolean gst_pad_can_link (GstPad *srcpad, GstPad *sinkpad); GstPadLinkReturn gst_pad_link (GstPad *srcpad, GstPad *sinkpad); @@ -926,21 +944,23 @@ gboolean gst_pad_stop_task (GstPad *pad); /* internal links */ void gst_pad_set_iterate_internal_links_function_full (GstPad * pad, GstPadIterIntLinkFunction iterintlink, + gpointer user_data, GDestroyNotify notify); GstIterator * gst_pad_iterate_internal_links (GstPad * pad); GstIterator * gst_pad_iterate_internal_links_default (GstPad * pad, GstObject *parent); -#define gst_pad_set_iterate_internal_links_function(p,f) gst_pad_set_iterate_internal_links_function_full((p),(f),NULL) +#define gst_pad_set_iterate_internal_links_function(p,f) gst_pad_set_iterate_internal_links_function_full((p),(f),NULL,NULL) /* generic query function */ gboolean gst_pad_query (GstPad *pad, GstQuery *query); gboolean gst_pad_peer_query (GstPad *pad, GstQuery *query); void gst_pad_set_query_function_full (GstPad *pad, GstPadQueryFunction query, + gpointer user_data, GDestroyNotify notify); gboolean gst_pad_query_default (GstPad *pad, GstObject *parent, GstQuery *query); -#define gst_pad_set_query_function(p,f) gst_pad_set_query_function_full((p),(f),NULL) +#define gst_pad_set_query_function(p,f) gst_pad_set_query_function_full((p),(f),NULL,NULL) /* misc helper functions */ gboolean gst_pad_forward (GstPad *pad, GstPadForwardFunction forward, |