GstBase.Aggregator

g GObject.InitiallyUnowned GObject.InitiallyUnowned Gst.Object Gst.Object GObject.InitiallyUnowned->Gst.Object GObject.Object GObject.Object GObject.Object->GObject.InitiallyUnowned Gst.Element Gst.Element GstBase.Aggregator GstBase.Aggregator Gst.Element->GstBase.Aggregator Gst.Object->Gst.Element

Subclasses:None

Virtual Methods

Inherited:Gst.Element (16), Gst.Object (1), GObject.Object (7)
  do_aggregate (timeout)
  do_clip (aggregator_pad, buf)
  do_decide_allocation (query)
  do_finish_buffer (buffer)
  do_fixate_src_caps (caps)
  do_flush ()
  do_get_next_time ()
  do_negotiated_src_caps (caps)
  do_propose_allocation (pad, decide_query, query)
  do_sink_event (aggregator_pad, event)
  do_sink_query (aggregator_pad, query)
  do_src_activate (mode, active)
  do_src_event (event)
  do_src_query (query)
  do_start ()
  do_stop ()
  do_update_src_caps (caps)

Properties

Inherited:Gst.Object (2)
Name Type Flags Short Description
latency int r/w Additional latency in live mode to allow upstream to take longer to produce buffers for the current position (in nanoseconds)
min-upstream-latency int r/w When sources with a higher latency are expected to be plugged in dynamically after the aggregator has started playing, this allows overriding the minimum latency reported by the initial source(s). This is only taken into account when larger than the actually reported minimum latency. (nanoseconds)
start-time int r/w Start time to use if start-time-selection=set

Fields

Inherited:Gst.Element (3), Gst.Object (1), GObject.Object (1)
Name Type Access Description
parent Gst.Element r  
srcpad Gst.Pad r the aggregator’s source pad

Class Details

class GstBase.Aggregator(**kwargs)
Bases:Gst.Element
Abstract:Yes
Structure:GstBase.AggregatorClass

Manages a set of pads with the purpose of aggregating their buffers. Control is given to the subclass when all pads have data.

This class used to live in gst-plugins-bad and was moved to core.

finish_buffer(buffer)[source]
Parameters:buffer (Gst.Buffer) – the Gst.Buffer to push.
Return type:Gst.FlowReturn

This method will push the provided output buffer downstream. If needed, mandatory events such as stream-start, caps, and segment events will be sent before pushing the buffer.

get_allocator()[source]
Returns:
allocator:the Gst.Allocator used
params:the Gst.AllocationParams of allocator
Return type:(allocator: Gst.Allocator, params: Gst.AllocationParams)

Lets GstBase.Aggregator sub-classes get the memory allocator acquired by the base class and its params.

Unref the allocator after use it.

get_buffer_pool()[source]
Returns:the instance of the Gst.BufferPool used by trans; free it after use it
Return type:Gst.BufferPool
get_latency()[source]
Returns:The latency or Gst.CLOCK_TIME_NONE if the element does not sync
Return type:int

Retrieves the latency values reported by self in response to the latency query, or Gst.CLOCK_TIME_NONE if there is not live source connected and the element will not wait for the clock.

Typically only called by subclasses.

set_latency(min_latency, max_latency)[source]
Parameters:
  • min_latency (int) – minimum latency
  • max_latency (int) – maximum latency

Lets GstBase.Aggregator sub-classes tell the baseclass what their internal latency is. Will also post a LATENCY message on the bus so the pipeline can reconfigure its global latency.

set_src_caps(caps)[source]
Parameters:caps (Gst.Caps) – The Gst.Caps to set on the src pad.

Sets the caps to be used on the src pad.

simple_get_next_time()[source]
Returns:The running time based on the position
Return type:int

This is a simple #GstAggregator::get_next_time implementation that just looks at the Gst.Segment on the srcpad of the aggregator and bases the next time on the running time there.

This is the desired behaviour in most cases where you have a live source and you have a dead line based aggregator subclass.

New in version 1.16.

do_aggregate(timeout) virtual
Parameters:timeout (bool) –
Return type:Gst.FlowReturn
do_clip(aggregator_pad, buf) virtual
Parameters:
Return type:

Gst.Buffer

do_decide_allocation(query) virtual
Parameters:query (Gst.Query) –
Return type:bool
do_finish_buffer(buffer) virtual
Parameters:buffer (Gst.Buffer) – the Gst.Buffer to push.
Return type:Gst.FlowReturn

This method will push the provided output buffer downstream. If needed, mandatory events such as stream-start, caps, and segment events will be sent before pushing the buffer.

do_fixate_src_caps(caps) virtual
Parameters:caps (Gst.Caps) –
Return type:Gst.Caps
do_flush() virtual
Return type:Gst.FlowReturn
do_get_next_time() virtual
Return type:int
do_negotiated_src_caps(caps) virtual
Parameters:caps (Gst.Caps) –
Return type:bool
do_propose_allocation(pad, decide_query, query) virtual
Parameters:
Return type:

bool

do_sink_event(aggregator_pad, event) virtual
Parameters:
Return type:

bool

do_sink_query(aggregator_pad, query) virtual
Parameters:
Return type:

bool

do_src_activate(mode, active) virtual
Parameters:
Return type:

bool

do_src_event(event) virtual
Parameters:event (Gst.Event) –
Return type:bool
do_src_query(query) virtual
Parameters:query (Gst.Query) –
Return type:bool
do_start() virtual
Return type:bool
do_stop() virtual
Return type:bool
do_update_src_caps(caps) virtual
Parameters:caps (Gst.Caps) –
Return type:(Gst.FlowReturn, ret: Gst.Caps)

Property Details

GstBase.Aggregator.props.latency
Name:latency
Type:int
Default Value:0
Flags:READABLE, WRITABLE

Additional latency in live mode to allow upstream to take longer to produce buffers for the current position (in nanoseconds)

GstBase.Aggregator.props.min_upstream_latency
Name:min-upstream-latency
Type:int
Default Value:0
Flags:READABLE, WRITABLE

Force minimum upstream latency (in nanoseconds). When sources with a higher latency are expected to be plugged in dynamically after the aggregator has started playing, this allows overriding the minimum latency reported by the initial source(s). This is only taken into account when larger than the actually reported minimum latency.

New in version 1.16.

GstBase.Aggregator.props.start_time
Name:start-time
Type:int
Default Value:18446744073709551615
Flags:READABLE, WRITABLE

Start time to use if start-time-selection=set