Push source scheduling and the create function

Tim Müller tim at centricular.com
Sun May 8 14:38:35 UTC 2016


On Fri, 2016-05-06 at 12:19 -0700, Martin Kelly wrote:

> Looks like setting async=false fixes my issue; thanks! I think the
> issue  is that each my bins generates data at drastically varying
> rate, from  many buffers per second to very rare buffers every few
> minutes.

Yes, rare buffers every few minutes sounds like a problem (without
async=false preroll could be delayed until such a rare buffer is
produced)

> Although adding the "async" property fixes the problem, is there a
> cleaner way I should be handling this?

It sounds like a reasonable/clean solution. You could make the encoding
bin send a gap event instead to make it preroll, but it's not clear to
me that that'd be cleaner.

> Another followup: I see both "sync" and "async" properties on
> fakesink. 
> Could you clarify the distinction between them and when each should
> be used?

"async" is about state changes (preroll mechanism)

"sync" determines whether the sink should pay attention to timestamps
on the buffers and schedule them according to the clock and such. If
you disable it buffers will be rendered as soon as possible without
paying any attention to timestamps. 

Cheers
-Tim

-- 
Tim Müller, Centricular Ltd - http://www.centricular.com




More information about the gstreamer-devel mailing list