mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-06-05 06:58:56 +00:00
audiofilter: copy metadata that only has the "audio" tag.
https://bugzilla.gnome.org/show_bug.cgi?id=750406
This commit is contained in:
parent
88484399c5
commit
579967278a
1 changed files with 20 additions and 0 deletions
|
@ -63,6 +63,25 @@ static gboolean gst_audio_filter_get_unit_size (GstBaseTransform * btrans,
|
|||
G_DEFINE_ABSTRACT_TYPE_WITH_CODE (GstAudioFilter, gst_audio_filter,
|
||||
GST_TYPE_BASE_TRANSFORM, do_init);
|
||||
|
||||
static gboolean
|
||||
gst_audio_filter_transform_meta (GstBaseTransform * trans, GstBuffer * inbuf,
|
||||
GstMeta * meta, GstBuffer * outbuf)
|
||||
{
|
||||
const GstMetaInfo *info = meta->info;
|
||||
const gchar *const *tags;
|
||||
|
||||
tags = gst_meta_api_type_get_tags (info->api);
|
||||
|
||||
if (tags && g_strv_length ((gchar **) tags) == 1
|
||||
&& gst_meta_api_type_has_tag (info->api,
|
||||
g_quark_from_string (GST_META_TAG_AUDIO_STR)))
|
||||
return TRUE;
|
||||
|
||||
return
|
||||
GST_BASE_TRANSFORM_CLASS (gst_audio_filter_parent_class)->transform_meta
|
||||
(trans, inbuf, meta, outbuf);
|
||||
}
|
||||
|
||||
static void
|
||||
gst_audio_filter_class_init (GstAudioFilterClass * klass)
|
||||
{
|
||||
|
@ -74,6 +93,7 @@ gst_audio_filter_class_init (GstAudioFilterClass * klass)
|
|||
basetrans_class->set_caps = GST_DEBUG_FUNCPTR (gst_audio_filter_set_caps);
|
||||
basetrans_class->get_unit_size =
|
||||
GST_DEBUG_FUNCPTR (gst_audio_filter_get_unit_size);
|
||||
basetrans_class->transform_meta = gst_audio_filter_transform_meta;
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
Loading…
Reference in a new issue