mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-18 14:26:43 +00:00
audiodecoder: expose default query handling function
Subclasses can use it to select what queries they want to handle and forward the rest to the default handling function. API: gst_audio_decoder_sink_query_default https://bugzilla.gnome.org/show_bug.cgi?id=753623
This commit is contained in:
parent
862c85ce4a
commit
8a64592481
3 changed files with 17 additions and 3 deletions
|
@ -383,8 +383,6 @@ static gboolean gst_audio_decoder_negotiate_default (GstAudioDecoder * dec);
|
||||||
static gboolean gst_audio_decoder_negotiate_unlocked (GstAudioDecoder * dec);
|
static gboolean gst_audio_decoder_negotiate_unlocked (GstAudioDecoder * dec);
|
||||||
static gboolean gst_audio_decoder_handle_gap (GstAudioDecoder * dec,
|
static gboolean gst_audio_decoder_handle_gap (GstAudioDecoder * dec,
|
||||||
GstEvent * event);
|
GstEvent * event);
|
||||||
static gboolean gst_audio_decoder_sink_query_default (GstAudioDecoder * dec,
|
|
||||||
GstQuery * query);
|
|
||||||
static gboolean gst_audio_decoder_src_query_default (GstAudioDecoder * dec,
|
static gboolean gst_audio_decoder_src_query_default (GstAudioDecoder * dec,
|
||||||
GstQuery * query);
|
GstQuery * query);
|
||||||
|
|
||||||
|
@ -2634,7 +2632,19 @@ gst_audio_decoder_sink_getcaps (GstAudioDecoder * decoder, GstCaps * filter)
|
||||||
return caps;
|
return caps;
|
||||||
}
|
}
|
||||||
|
|
||||||
static gboolean
|
/**
|
||||||
|
* gst_audio_decoder_sink_query_default:
|
||||||
|
* @decoder: a #GstAudioDecoder
|
||||||
|
* @query: (transfer none): a #GstQuery
|
||||||
|
*
|
||||||
|
* Calls the default query handler for #GstAudioDecoder. It is useful
|
||||||
|
* when a subclass only want to handle a particular type of query and
|
||||||
|
* wants to use the default handler for others.
|
||||||
|
*
|
||||||
|
* Returns: a boolean, representing if the query was handled.
|
||||||
|
* Since: 1.6
|
||||||
|
*/
|
||||||
|
gboolean
|
||||||
gst_audio_decoder_sink_query_default (GstAudioDecoder * dec, GstQuery * query)
|
gst_audio_decoder_sink_query_default (GstAudioDecoder * dec, GstQuery * query)
|
||||||
{
|
{
|
||||||
GstPad *pad = GST_AUDIO_DECODER_SINK_PAD (dec);
|
GstPad *pad = GST_AUDIO_DECODER_SINK_PAD (dec);
|
||||||
|
|
|
@ -394,6 +394,9 @@ void gst_audio_decoder_get_allocator (GstAudioDecoder * dec,
|
||||||
void gst_audio_decoder_merge_tags (GstAudioDecoder * dec,
|
void gst_audio_decoder_merge_tags (GstAudioDecoder * dec,
|
||||||
const GstTagList * tags, GstTagMergeMode mode);
|
const GstTagList * tags, GstTagMergeMode mode);
|
||||||
|
|
||||||
|
gboolean gst_audio_decoder_sink_query_default (GstAudioDecoder * dec,
|
||||||
|
GstQuery * query);
|
||||||
|
|
||||||
G_END_DECLS
|
G_END_DECLS
|
||||||
|
|
||||||
#endif /* _GST_AUDIO_DECODER_H_ */
|
#endif /* _GST_AUDIO_DECODER_H_ */
|
||||||
|
|
|
@ -67,6 +67,7 @@ EXPORTS
|
||||||
gst_audio_decoder_set_plc
|
gst_audio_decoder_set_plc
|
||||||
gst_audio_decoder_set_plc_aware
|
gst_audio_decoder_set_plc_aware
|
||||||
gst_audio_decoder_set_tolerance
|
gst_audio_decoder_set_tolerance
|
||||||
|
gst_audio_decoder_sink_query_default
|
||||||
gst_audio_downmix_meta_api_get_type
|
gst_audio_downmix_meta_api_get_type
|
||||||
gst_audio_downmix_meta_get_info
|
gst_audio_downmix_meta_get_info
|
||||||
gst_audio_encoder_allocate_output_buffer
|
gst_audio_encoder_allocate_output_buffer
|
||||||
|
|
Loading…
Reference in a new issue