mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-10 17:35:59 +00:00
gst/base/gstbasesink.c: segment_stop == -1 at startup.
Original commit message from CVS: * gst/base/gstbasesink.c: (gst_base_sink_change_state): segment_stop == -1 at startup. * gst/base/gstbasetransform.c: (gst_base_transform_event), (gst_base_transform_change_state): Init segment values at start.
This commit is contained in:
parent
87e4af77a1
commit
b0233e7b7f
5 changed files with 41 additions and 14 deletions
|
@ -1,3 +1,12 @@
|
|||
2005-11-15 Wim Taymans <wim@fluendo.com>
|
||||
|
||||
* gst/base/gstbasesink.c: (gst_base_sink_change_state):
|
||||
segment_stop == -1 at startup.
|
||||
|
||||
* gst/base/gstbasetransform.c: (gst_base_transform_event),
|
||||
(gst_base_transform_change_state):
|
||||
Init segment values at start.
|
||||
|
||||
2005-11-15 Andy Wingo <wingo@pobox.com>
|
||||
|
||||
* check/gst/gstpipeline.c (test_base_time): Punt around the
|
||||
|
|
|
@ -1587,7 +1587,7 @@ gst_base_sink_change_state (GstElement * element, GstStateChange transition)
|
|||
basesink->have_newsegment = FALSE;
|
||||
basesink->segment_rate = 1.0;
|
||||
basesink->segment_start = 0;
|
||||
basesink->segment_stop = 0;
|
||||
basesink->segment_stop = -1;
|
||||
basesink->segment_time = 0;
|
||||
basesink->segment_accum = 0;
|
||||
ret = GST_STATE_CHANGE_ASYNC;
|
||||
|
|
|
@ -1128,16 +1128,19 @@ gst_base_transform_event (GstPad * pad, GstEvent * event)
|
|||
|
||||
if (format == GST_FORMAT_TIME) {
|
||||
GST_DEBUG_OBJECT (trans, "received NEW_SEGMENT %" GST_TIME_FORMAT
|
||||
" -- %" GST_TIME_FORMAT ", time %" GST_TIME_FORMAT,
|
||||
" -- %" GST_TIME_FORMAT ", time %" GST_TIME_FORMAT
|
||||
", accum %" GST_TIME_FORMAT,
|
||||
GST_TIME_ARGS (trans->segment_start),
|
||||
GST_TIME_ARGS (trans->segment_start),
|
||||
GST_TIME_ARGS (trans->segment_base));
|
||||
GST_TIME_ARGS (trans->segment_stop),
|
||||
GST_TIME_ARGS (trans->segment_base),
|
||||
GST_TIME_ARGS (trans->segment_accum));
|
||||
} else {
|
||||
GST_DEBUG_OBJECT (trans, "received NEW_SEGMENT %" G_GINT64_FORMAT
|
||||
" -- %" G_GINT64_FORMAT ", time %" G_GINT64_FORMAT,
|
||||
trans->segment_start, trans->segment_stop, trans->segment_base);
|
||||
" -- %" G_GINT64_FORMAT ", time %" G_GINT64_FORMAT
|
||||
", accum %" G_GINT64_FORMAT,
|
||||
trans->segment_start, trans->segment_stop,
|
||||
trans->segment_base, trans->segment_accum);
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
default:
|
||||
|
@ -1427,6 +1430,12 @@ gst_base_transform_change_state (GstElement * element,
|
|||
trans->have_same_caps = trans->passthrough;
|
||||
GST_DEBUG_OBJECT (trans, "have_same_caps %d", trans->have_same_caps);
|
||||
trans->negotiated = FALSE;
|
||||
trans->have_newsegment = FALSE;
|
||||
trans->segment_rate = 1.0;
|
||||
trans->segment_start = 0;
|
||||
trans->segment_stop = -1;
|
||||
trans->segment_base = 0;
|
||||
trans->segment_accum = 0;
|
||||
GST_UNLOCK (trans);
|
||||
break;
|
||||
case GST_STATE_CHANGE_PAUSED_TO_PLAYING:
|
||||
|
|
|
@ -1587,7 +1587,7 @@ gst_base_sink_change_state (GstElement * element, GstStateChange transition)
|
|||
basesink->have_newsegment = FALSE;
|
||||
basesink->segment_rate = 1.0;
|
||||
basesink->segment_start = 0;
|
||||
basesink->segment_stop = 0;
|
||||
basesink->segment_stop = -1;
|
||||
basesink->segment_time = 0;
|
||||
basesink->segment_accum = 0;
|
||||
ret = GST_STATE_CHANGE_ASYNC;
|
||||
|
|
|
@ -1128,16 +1128,19 @@ gst_base_transform_event (GstPad * pad, GstEvent * event)
|
|||
|
||||
if (format == GST_FORMAT_TIME) {
|
||||
GST_DEBUG_OBJECT (trans, "received NEW_SEGMENT %" GST_TIME_FORMAT
|
||||
" -- %" GST_TIME_FORMAT ", time %" GST_TIME_FORMAT,
|
||||
" -- %" GST_TIME_FORMAT ", time %" GST_TIME_FORMAT
|
||||
", accum %" GST_TIME_FORMAT,
|
||||
GST_TIME_ARGS (trans->segment_start),
|
||||
GST_TIME_ARGS (trans->segment_start),
|
||||
GST_TIME_ARGS (trans->segment_base));
|
||||
GST_TIME_ARGS (trans->segment_stop),
|
||||
GST_TIME_ARGS (trans->segment_base),
|
||||
GST_TIME_ARGS (trans->segment_accum));
|
||||
} else {
|
||||
GST_DEBUG_OBJECT (trans, "received NEW_SEGMENT %" G_GINT64_FORMAT
|
||||
" -- %" G_GINT64_FORMAT ", time %" G_GINT64_FORMAT,
|
||||
trans->segment_start, trans->segment_stop, trans->segment_base);
|
||||
" -- %" G_GINT64_FORMAT ", time %" G_GINT64_FORMAT
|
||||
", accum %" G_GINT64_FORMAT,
|
||||
trans->segment_start, trans->segment_stop,
|
||||
trans->segment_base, trans->segment_accum);
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
default:
|
||||
|
@ -1427,6 +1430,12 @@ gst_base_transform_change_state (GstElement * element,
|
|||
trans->have_same_caps = trans->passthrough;
|
||||
GST_DEBUG_OBJECT (trans, "have_same_caps %d", trans->have_same_caps);
|
||||
trans->negotiated = FALSE;
|
||||
trans->have_newsegment = FALSE;
|
||||
trans->segment_rate = 1.0;
|
||||
trans->segment_start = 0;
|
||||
trans->segment_stop = -1;
|
||||
trans->segment_base = 0;
|
||||
trans->segment_accum = 0;
|
||||
GST_UNLOCK (trans);
|
||||
break;
|
||||
case GST_STATE_CHANGE_PAUSED_TO_PLAYING:
|
||||
|
|
Loading…
Reference in a new issue