mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 03:31:05 +00:00
concat: Improve debug output a bit
This commit is contained in:
parent
edc1a5be3e
commit
9d27e5d70d
1 changed files with 20 additions and 3 deletions
|
@ -430,7 +430,7 @@ gst_concat_sink_chain (GstPad * pad, GstObject * parent, GstBuffer * buffer)
|
||||||
GstConcat *self = GST_CONCAT (parent);
|
GstConcat *self = GST_CONCAT (parent);
|
||||||
GstConcatPad *spad = GST_CONCAT_PAD (pad);
|
GstConcatPad *spad = GST_CONCAT_PAD (pad);
|
||||||
|
|
||||||
GST_LOG_OBJECT (pad, "received buffer %p", buffer);
|
GST_LOG_OBJECT (pad, "received buffer %" GST_PTR_FORMAT, buffer);
|
||||||
|
|
||||||
if (!gst_concat_pad_wait (spad, self))
|
if (!gst_concat_pad_wait (spad, self))
|
||||||
return GST_FLOW_FLUSHING;
|
return GST_FLOW_FLUSHING;
|
||||||
|
@ -455,7 +455,8 @@ gst_concat_sink_chain (GstPad * pad, GstObject * parent, GstBuffer * buffer)
|
||||||
|
|
||||||
ret = gst_pad_push (self->srcpad, buffer);
|
ret = gst_pad_push (self->srcpad, buffer);
|
||||||
|
|
||||||
GST_LOG_OBJECT (pad, "handled buffer %s", gst_flow_get_name (ret));
|
GST_LOG_OBJECT (pad, "handled buffer %s, last_stop %" GST_TIME_FORMAT,
|
||||||
|
gst_flow_get_name (ret), GST_TIME_ARGS (self->last_stop));
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
@ -579,12 +580,28 @@ gst_concat_sink_event (GstPad * pad, GstObject * parent, GstEvent * event)
|
||||||
|
|
||||||
/* Update segment values to be continuous with last stream */
|
/* Update segment values to be continuous with last stream */
|
||||||
if (self->format == GST_FORMAT_TIME) {
|
if (self->format == GST_FORMAT_TIME) {
|
||||||
|
GST_DEBUG_OBJECT (self,
|
||||||
|
"Updating segment base %" GST_TIME_FORMAT " + %" GST_TIME_FORMAT
|
||||||
|
" = %" GST_TIME_FORMAT, GST_TIME_ARGS (segment.base),
|
||||||
|
GST_TIME_ARGS (self->current_start_offset),
|
||||||
|
GST_TIME_ARGS (segment.base + self->current_start_offset));
|
||||||
segment.base += self->current_start_offset;
|
segment.base += self->current_start_offset;
|
||||||
} else {
|
} else {
|
||||||
/* Shift start/stop byte position */
|
/* Shift start/stop byte position */
|
||||||
|
GST_DEBUG_OBJECT (self,
|
||||||
|
"Updating segment start %" G_GUINT64_FORMAT " + %"
|
||||||
|
G_GUINT64_FORMAT " = %" G_GUINT64_FORMAT, segment.start,
|
||||||
|
self->current_start_offset,
|
||||||
|
segment.start + self->current_start_offset);
|
||||||
segment.start += self->current_start_offset;
|
segment.start += self->current_start_offset;
|
||||||
if (segment.stop != -1)
|
if (segment.stop != -1) {
|
||||||
|
GST_DEBUG_OBJECT (self,
|
||||||
|
"Updating segment stop %" G_GUINT64_FORMAT " + %"
|
||||||
|
G_GUINT64_FORMAT " = %" G_GUINT64_FORMAT, segment.stop,
|
||||||
|
self->current_start_offset,
|
||||||
|
segment.stop + self->current_start_offset);
|
||||||
segment.stop += self->current_start_offset;
|
segment.stop += self->current_start_offset;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
topush = gst_event_new_segment (&segment);
|
topush = gst_event_new_segment (&segment);
|
||||||
|
|
Loading…
Reference in a new issue