mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 04:01:08 +00:00
_query_peer_*() -> _peer_query_*()
This commit is contained in:
parent
026ec68f75
commit
28157e6f21
6 changed files with 11 additions and 11 deletions
|
@ -1800,7 +1800,7 @@ gst_audio_decoder_src_query (GstPad * pad, GstQuery * query)
|
||||||
if (format == GST_FORMAT_TIME && gst_audio_decoder_do_byte (dec)) {
|
if (format == GST_FORMAT_TIME && gst_audio_decoder_do_byte (dec)) {
|
||||||
gint64 value;
|
gint64 value;
|
||||||
|
|
||||||
if (gst_pad_query_peer_duration (dec->sinkpad, GST_FORMAT_BYTES,
|
if (gst_pad_peer_query_duration (dec->sinkpad, GST_FORMAT_BYTES,
|
||||||
&value)) {
|
&value)) {
|
||||||
GST_LOG_OBJECT (dec, "upstream size %" G_GINT64_FORMAT, value);
|
GST_LOG_OBJECT (dec, "upstream size %" G_GINT64_FORMAT, value);
|
||||||
if (gst_pad_query_convert (dec->sinkpad, GST_FORMAT_BYTES, value,
|
if (gst_pad_query_convert (dec->sinkpad, GST_FORMAT_BYTES, value,
|
||||||
|
|
|
@ -730,7 +730,7 @@ gst_tag_demux_get_upstream_size (GstTagDemux * tagdemux)
|
||||||
if (tagdemux->priv->upstream_size > 0)
|
if (tagdemux->priv->upstream_size > 0)
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|
||||||
if (!gst_pad_query_peer_duration (tagdemux->priv->sinkpad, GST_FORMAT_BYTES,
|
if (!gst_pad_peer_query_duration (tagdemux->priv->sinkpad, GST_FORMAT_BYTES,
|
||||||
&len) || len <= 0) {
|
&len) || len <= 0) {
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
|
@ -373,7 +373,7 @@ gst_adder_query_duration (GstAdder * adder, GstQuery * query)
|
||||||
gint64 duration;
|
gint64 duration;
|
||||||
|
|
||||||
/* ask sink peer for duration */
|
/* ask sink peer for duration */
|
||||||
res &= gst_pad_query_peer_duration (pad, format, &duration);
|
res &= gst_pad_peer_query_duration (pad, format, &duration);
|
||||||
/* take max from all valid return values */
|
/* take max from all valid return values */
|
||||||
if (res) {
|
if (res) {
|
||||||
/* valid unknown length, stop searching */
|
/* valid unknown length, stop searching */
|
||||||
|
|
|
@ -2226,7 +2226,7 @@ check_upstream_seekable (GstDecodeBin * dbin, GstPad * pad)
|
||||||
/* try harder to query upstream size if we didn't get it the first time */
|
/* try harder to query upstream size if we didn't get it the first time */
|
||||||
if (dbin->upstream_seekable && stop == -1) {
|
if (dbin->upstream_seekable && stop == -1) {
|
||||||
GST_DEBUG_OBJECT (dbin, "doing duration query to fix up unset stop");
|
GST_DEBUG_OBJECT (dbin, "doing duration query to fix up unset stop");
|
||||||
gst_pad_query_peer_duration (pad, GST_FORMAT_BYTES, &stop);
|
gst_pad_peer_query_duration (pad, GST_FORMAT_BYTES, &stop);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* if upstream doesn't know the size, it's likely that it's not seekable in
|
/* if upstream doesn't know the size, it's likely that it's not seekable in
|
||||||
|
|
|
@ -3117,7 +3117,7 @@ autoplug_continue_cb (GstElement * element, GstPad * pad, GstCaps * caps,
|
||||||
|
|
||||||
sinkcaps = gst_pad_query_caps (sinkpad, NULL);
|
sinkcaps = gst_pad_query_caps (sinkpad, NULL);
|
||||||
if (!gst_caps_is_any (sinkcaps))
|
if (!gst_caps_is_any (sinkcaps))
|
||||||
ret = !gst_pad_accept_caps (sinkpad, caps);
|
ret = !gst_pad_query_accept_caps (sinkpad, caps);
|
||||||
gst_caps_unref (sinkcaps);
|
gst_caps_unref (sinkcaps);
|
||||||
gst_object_unref (sinkpad);
|
gst_object_unref (sinkpad);
|
||||||
} else {
|
} else {
|
||||||
|
@ -3149,7 +3149,7 @@ autoplug_continue_cb (GstElement * element, GstPad * pad, GstCaps * caps,
|
||||||
|
|
||||||
sinkcaps = gst_pad_query_caps (sinkpad, NULL);
|
sinkcaps = gst_pad_query_caps (sinkpad, NULL);
|
||||||
if (!gst_caps_is_any (sinkcaps))
|
if (!gst_caps_is_any (sinkcaps))
|
||||||
ret = !gst_pad_accept_caps (sinkpad, caps);
|
ret = !gst_pad_query_accept_caps (sinkpad, caps);
|
||||||
gst_caps_unref (sinkcaps);
|
gst_caps_unref (sinkcaps);
|
||||||
gst_object_unref (sinkpad);
|
gst_object_unref (sinkpad);
|
||||||
}
|
}
|
||||||
|
@ -3170,7 +3170,7 @@ autoplug_continue_cb (GstElement * element, GstPad * pad, GstCaps * caps,
|
||||||
|
|
||||||
sinkcaps = gst_pad_query_caps (sinkpad, NULL);
|
sinkcaps = gst_pad_query_caps (sinkpad, NULL);
|
||||||
if (!gst_caps_is_any (sinkcaps))
|
if (!gst_caps_is_any (sinkcaps))
|
||||||
ret = !gst_pad_accept_caps (sinkpad, caps);
|
ret = !gst_pad_query_accept_caps (sinkpad, caps);
|
||||||
gst_caps_unref (sinkcaps);
|
gst_caps_unref (sinkcaps);
|
||||||
gst_object_unref (sinkpad);
|
gst_object_unref (sinkpad);
|
||||||
}
|
}
|
||||||
|
@ -3204,7 +3204,7 @@ sink_accepts_caps (GstElement * sink, GstCaps * caps)
|
||||||
if ((sinkpad = gst_element_get_static_pad (sink, "sink"))) {
|
if ((sinkpad = gst_element_get_static_pad (sink, "sink"))) {
|
||||||
/* Got the sink pad, now let's see if the element actually does accept the
|
/* Got the sink pad, now let's see if the element actually does accept the
|
||||||
* caps that we have */
|
* caps that we have */
|
||||||
if (!gst_pad_accept_caps (sinkpad, caps)) {
|
if (!gst_pad_query_accept_caps (sinkpad, caps)) {
|
||||||
gst_object_unref (sinkpad);
|
gst_object_unref (sinkpad);
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
|
@ -802,7 +802,7 @@ _pad_blocked_cb (GstPad * pad, GstPadProbeInfo * info, gpointer user_data)
|
||||||
GstPad *target =
|
GstPad *target =
|
||||||
gst_ghost_pad_get_target (GST_GHOST_PAD_CAST (self->subtitle_sinkpad));
|
gst_ghost_pad_get_target (GST_GHOST_PAD_CAST (self->subtitle_sinkpad));
|
||||||
|
|
||||||
if (target && gst_pad_accept_caps (target, subcaps)) {
|
if (target && gst_pad_query_accept_caps (target, subcaps)) {
|
||||||
GST_DEBUG_OBJECT (pad, "Target accepts caps");
|
GST_DEBUG_OBJECT (pad, "Target accepts caps");
|
||||||
|
|
||||||
gst_object_unref (target);
|
gst_object_unref (target);
|
||||||
|
@ -1719,7 +1719,7 @@ gst_subtitle_overlay_video_sink_setcaps (GstSubtitleOverlay * self,
|
||||||
|
|
||||||
GST_SUBTITLE_OVERLAY_LOCK (self);
|
GST_SUBTITLE_OVERLAY_LOCK (self);
|
||||||
|
|
||||||
if (!target || !gst_pad_accept_caps (target, caps)) {
|
if (!target || !gst_pad_query_accept_caps (target, caps)) {
|
||||||
GST_DEBUG_OBJECT (target, "Target did not accept caps -- reconfiguring");
|
GST_DEBUG_OBJECT (target, "Target did not accept caps -- reconfiguring");
|
||||||
|
|
||||||
block_subtitle (self);
|
block_subtitle (self);
|
||||||
|
@ -1887,7 +1887,7 @@ gst_subtitle_overlay_subtitle_sink_setcaps (GstSubtitleOverlay * self,
|
||||||
GST_SUBTITLE_OVERLAY_LOCK (self);
|
GST_SUBTITLE_OVERLAY_LOCK (self);
|
||||||
gst_caps_replace (&self->subcaps, caps);
|
gst_caps_replace (&self->subcaps, caps);
|
||||||
|
|
||||||
if (target && gst_pad_accept_caps (target, caps)) {
|
if (target && gst_pad_query_accept_caps (target, caps)) {
|
||||||
GST_DEBUG_OBJECT (self, "Target accepts caps");
|
GST_DEBUG_OBJECT (self, "Target accepts caps");
|
||||||
GST_SUBTITLE_OVERLAY_UNLOCK (self);
|
GST_SUBTITLE_OVERLAY_UNLOCK (self);
|
||||||
goto out;
|
goto out;
|
||||||
|
|
Loading…
Reference in a new issue