From: Wim Taymans Date: Wed, 29 Oct 2008 17:04:50 +0000 (+0000) Subject: gst/gstpipeline.c: Some more comments. X-Git-Tag: GIT_CONVERSION~99 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d0b44d15780439ffa7e314b3c1d0658f3fadbab9;p=platform%2Fupstream%2Fgstreamer.git gst/gstpipeline.c: Some more comments. Original commit message from CVS: * gst/gstpipeline.c: (gst_pipeline_provide_clock_func): Some more comments. --- diff --git a/ChangeLog b/ChangeLog index a4c3997..7bb3ba9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2008-10-29 Wim Taymans + + * gst/gstpipeline.c: (gst_pipeline_provide_clock_func): + Some more comments. + 2008-10-27 Wim Taymans * libs/gst/base/gstbasetransform.c: diff --git a/gst/gstpipeline.c b/gst/gstpipeline.c index 4a91650..ed8b87a 100644 --- a/gst/gstpipeline.c +++ b/gst/gstpipeline.c @@ -68,7 +68,9 @@ * performed on it, the stream time is reset to 0. When the pipeline is * set from PLAYING to PAUSED, the current clock time is sampled and used to * configure the base time for the elements when the pipeline is set - * to PLAYING again. This default behaviour can be changed with the + * to PLAYING again. The effect is that the stream time (as the difference + * between the clock time and the base time) will count how much time was spent + * in the PLAYING state. This default behaviour can be changed with the * gst_pipeline_set_new_stream_time() method. * * When sending a flushing seek event to a GstPipeline (see @@ -545,6 +547,12 @@ invalid_clock: } } +/* intercept the bus messages from our children. We watch for the ASYNC_START + * message with is posted by the elements (sinks) that require a reset of the + * running_time after a flush. ASYNC_START also brings the pipeline back into + * the PAUSED, pending PAUSED state. When the ASYNC_DONE message is received the + * pipeline will redistribute the new base_time and will bring the elements back + * to the desired state of the pipeline. */ static void gst_pipeline_handle_message (GstBin * bin, GstMessage * message) { @@ -671,8 +679,8 @@ gst_pipeline_provide_clock_func (GstElement * element) GST_OBJECT_UNLOCK (pipeline); /* let the parent bin select a clock */ clock = - GST_ELEMENT_CLASS (parent_class)-> - provide_clock (GST_ELEMENT (pipeline)); + GST_ELEMENT_CLASS (parent_class)->provide_clock (GST_ELEMENT + (pipeline)); /* no clock, use a system clock */ if (!clock) { clock = gst_system_clock_obtain ();