mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-23 08:46:40 +00:00
netaddressmeta: gst_buffer_get_net_address_meta() as function
Implement gst_buffer_get_net_address_meta() as a function instead of a macro in order to get gobject-introspection to work. https://bugzilla.gnome.org/show_bug.cgi?id=702921
This commit is contained in:
parent
5af73b30ed
commit
85b93fa347
3 changed files with 18 additions and 3 deletions
|
@ -119,3 +119,19 @@ gst_buffer_add_net_address_meta (GstBuffer * buffer, GSocketAddress * addr)
|
|||
|
||||
return meta;
|
||||
}
|
||||
|
||||
/**
|
||||
* gst_buffer_get_net_address_meta:
|
||||
* @buffer: a #GstBuffer
|
||||
*
|
||||
* Find the #GstNetAddressMeta on @buffer.
|
||||
*
|
||||
* Returns: (transfer none): the #GstNetAddressMeta or %NULL when there
|
||||
* is no such metadata on @buffer.
|
||||
*/
|
||||
GstNetAddressMeta *
|
||||
gst_buffer_get_net_address_meta (GstBuffer * buffer)
|
||||
{
|
||||
return (GstNetAddressMeta *)
|
||||
gst_buffer_get_meta (buffer, GST_NET_ADDRESS_META_API_TYPE);
|
||||
}
|
||||
|
|
|
@ -43,15 +43,13 @@ struct _GstNetAddressMeta {
|
|||
GType gst_net_address_meta_api_get_type (void);
|
||||
#define GST_NET_ADDRESS_META_API_TYPE (gst_net_address_meta_api_get_type())
|
||||
|
||||
#define gst_buffer_get_net_address_meta(b) \
|
||||
((GstNetAddressMeta*)gst_buffer_get_meta((b),GST_NET_ADDRESS_META_API_TYPE))
|
||||
|
||||
/* implementation */
|
||||
const GstMetaInfo *gst_net_address_meta_get_info (void);
|
||||
#define GST_NET_ADDRESS_META_INFO (gst_net_address_meta_get_info())
|
||||
|
||||
GstNetAddressMeta * gst_buffer_add_net_address_meta (GstBuffer *buffer,
|
||||
GSocketAddress *addr);
|
||||
GstNetAddressMeta * gst_buffer_get_net_address_meta (GstBuffer *buffer);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
EXPORTS
|
||||
gst_buffer_add_net_address_meta
|
||||
gst_buffer_add_net_control_message_meta
|
||||
gst_buffer_get_net_address_meta
|
||||
gst_net_address_meta_api_get_type
|
||||
gst_net_address_meta_get_info
|
||||
gst_net_client_clock_get_type
|
||||
|
|
Loading…
Reference in a new issue