Gst.Element¶
Subclasses: | Gst.Bin |
---|
Methods¶
Inherited: | Gst.Object (27), GObject.Object (37) |
---|---|
Structs: | Gst.ElementClass (10), GObject.ObjectClass (5) |
class | add_metadata (key, value) |
class | add_pad_template (templ) |
class | add_static_metadata (key, value) |
class | add_static_pad_template (static_templ) |
class | add_static_pad_template_with_gtype (static_templ, pad_type) |
class | get_metadata (key) |
class | get_pad_template (name) |
class | get_pad_template_list () |
class | make_from_uri (type, uri, elementname) |
class | register (plugin, name, rank, type) |
class | set_metadata (longname, classification, description, author) |
class | set_static_metadata (longname, classification, description, author) |
class | state_change_return_get_name (state_ret) |
class | state_get_name (state) |
abort_state () |
|
add_pad (pad) |
|
add_property_deep_notify_watch (property_name, include_value) |
|
add_property_notify_watch (property_name, include_value) |
|
call_async (func, *user_data) |
|
change_state (transition) |
|
continue_state (ret) |
|
create_all_pads () |
|
foreach_pad (func, *user_data) |
|
foreach_sink_pad (func, *user_data) |
|
foreach_src_pad (func, *user_data) |
|
get_base_time () |
|
get_bus () |
|
get_clock () |
|
get_compatible_pad (pad, caps) |
|
get_compatible_pad_template (compattempl) |
|
get_context (context_type) |
|
get_context_unlocked (context_type) |
|
get_contexts () |
|
get_current_clock_time () |
|
get_current_running_time () |
|
get_factory () |
|
get_metadata (key) |
|
get_pad_template (name) |
|
get_pad_template_list () |
|
get_request_pad (name) |
|
get_start_time () |
|
get_state (timeout) |
|
get_static_pad (name) |
|
is_locked_state () |
|
iterate_pads () |
|
iterate_sink_pads () |
|
iterate_src_pads () |
|
link (dest) |
|
link_filtered (dest, filter) |
|
link_pads (srcpadname, dest, destpadname) |
|
link_pads_filtered (srcpadname, dest, destpadname, filter) |
|
link_pads_full (srcpadname, dest, destpadname, flags) |
|
lost_state () |
|
message_full (type, domain, code, text, debug, file, function, line) |
|
message_full_with_details (type, domain, code, text, debug, file, function, line, structure) |
|
no_more_pads () |
|
post_message (message) |
|
provide_clock () |
|
query (query) |
|
query_convert (src_format, src_val, dest_format) |
|
query_duration (format) |
|
query_position (format) |
|
release_request_pad (pad) |
|
remove_pad (pad) |
|
remove_property_notify_watch (watch_id) |
|
request_pad (templ, name, caps) |
|
seek (rate, format, flags, start_type, start, stop_type, stop) |
|
seek_simple (format, seek_flags, seek_pos) |
|
send_event (event) |
|
set_base_time (time) |
|
set_bus (bus) |
|
set_clock (clock) |
|
set_context (context) |
|
set_locked_state (locked_state) |
|
set_start_time (time) |
|
set_state (state) |
|
sync_state_with_parent () |
|
unlink (dest) |
|
unlink_pads (srcpadname, dest, destpadname) |
Virtual Methods¶
Inherited: | Gst.Object (1), GObject.Object (7) |
---|
do_change_state (transition) |
|
do_get_state (timeout) |
|
do_no_more_pads () |
|
do_pad_added (pad) |
|
do_pad_removed (pad) |
|
do_post_message (message) |
|
do_provide_clock () |
|
do_query (query) |
|
do_release_pad (pad) |
|
do_request_new_pad (templ, name, caps) |
|
do_send_event (event) |
|
do_set_bus (bus) |
|
do_set_clock (clock) |
|
do_set_context (context) |
|
do_set_state (state) |
|
do_state_changed (oldstate, newstate, pending) |
Properties¶
Inherited: | Gst.Object (2) |
---|
Signals¶
Inherited: | Gst.Object (1), GObject.Object (1) |
---|
Name | Short Description |
---|---|
no-more-pads |
This signals that the element will not generate more dynamic pads. |
pad-added |
a new Gst.Pad has been added to the element. |
pad-removed |
a Gst.Pad has been removed from the element |
Fields¶
Inherited: | Gst.Object (1), GObject.Object (1) |
---|
Name | Type | Access | Description |
---|---|---|---|
base_time | int |
r | the time of the clock right before the element is set to PLAYING. Subtracting base_time from the current clock time in the PLAYING state will yield the running_time against the clock. |
bus | Gst.Bus |
r | the bus of the element. This bus is provided to the element by the parent element or the application. A Gst.Pipeline has a bus of its own. |
clock | Gst.Clock |
r | the clock of the element. This clock is usually provided to the element by the toplevel Gst.Pipeline . |
contexts | [Gst.Context ] |
r | list of contexts |
current_state | Gst.State |
r | the current state of an element |
last_return | Gst.StateChangeReturn |
r | the last return value of an element state change |
next_state | Gst.State |
r | the next state of an element, can be Gst.State.VOID_PENDING if the element is in the correct state. |
numpads | int |
r | number of pads of the element, includes both source and sink pads. |
numsinkpads | int |
r | number of sink pads of the element. |
numsrcpads | int |
r | number of source pads of the element. |
object | Gst.Object |
r | |
pads | [Gst.Pad ] |
r | list of pads |
pads_cookie | int |
r | updated whenever the a pad is added or removed |
pending_state | Gst.State |
r | the final state the element should go to, can be Gst.State.VOID_PENDING if the element is in the correct state |
sinkpads | [Gst.Pad ] |
r | list of sink pads |
srcpads | [Gst.Pad ] |
r | list of source pads |
start_time | int |
r | the running_time of the last PAUSED state |
state_cond | GLib.Cond |
r | Used to signal completion of a state change |
state_cookie | int |
r | Used to detect concurrent execution of Gst.Element.set_state () and Gst.Element.get_state () |
state_lock | GLib.RecMutex |
r | Used to serialize execution of Gst.Element.set_state () |
target_state | Gst.State |
r | the target state of an element as set by the application |
Class Details¶
-
class
Gst.
Element
(**kwargs)¶ Bases: Gst.Object
Abstract: Yes Structure: Gst.ElementClass
Gst.Element
is the abstract base class needed to construct an element that can be used in a GStreamer pipeline. Please refer to the plugin writers guide for more information on creatingGst.Element
subclasses.The name of a
Gst.Element
can be get with gst_element_get_name() and set with gst_element_set_name(). For speed, GST_ELEMENT_NAME() can be used in the core when using the appropriate locking. Do not use this in plug-ins or applications in order to retain ABI compatibility.Elements can have pads (of the type
Gst.Pad
). These pads link to pads on other elements.Gst.Buffer
flow between these linked pads. AGst.Element
has aGLib.List
ofGst.Pad
structures for all their input (or sink) and output (or source) pads. Core and plug-in writers can add and remove pads withGst.Element.add_pad
() andGst.Element.remove_pad
().An existing pad of an element can be retrieved by name with
Gst.Element.get_static_pad
(). A new dynamic pad can be created usingGst.Element.request_pad
() with aGst.PadTemplate
. An iterator of all pads can be retrieved withGst.Element.iterate_pads
().Elements can be linked through their pads. If the link is straightforward, use the
Gst.Element.link
() convenience function to link two elements, or gst_element_link_many() for more elements in a row. UseGst.Element.link_filtered
() to link two elements constrained by a specified set ofGst.Caps
. For finer control, useGst.Element.link_pads
() andGst.Element.link_pads_filtered
() to specify the pads to link on each element by name.Each element has a state (see
Gst.State
). You can get and set the state of an element withGst.Element.get_state
() andGst.Element.set_state
(). Setting a state triggers aGst.StateChange
. To get a string representation of aGst.State
, useGst.Element.state_get_name
().You can get and set a
Gst.Clock
on an element usingGst.Element.get_clock
() andGst.Element.set_clock
(). Some elements can provide a clock for the pipeline if theGst.ElementFlags.PROVIDE_CLOCK
flag is set. With theGst.Element.provide_clock
() method one can retrieve the clock provided by such an element. Not all elements require a clock to operate correctly. If theGst.ElementFlags.REQUIRE_CLOCK
() flag is set, a clock should be set on the element withGst.Element.set_clock
().Note that clock selection and distribution is normally handled by the toplevel
Gst.Pipeline
so the clock functions are only to be used in very specific situations.-
classmethod
add_metadata
(key, value)¶ Parameters: Set key with value as metadata in self.
-
classmethod
add_pad_template
(templ)¶ Parameters: templ ( Gst.PadTemplate
) – aGst.PadTemplate
to add to the element class.Adds a padtemplate to an element class. This is mainly used in the _class_init functions of classes. If a pad template with the same name as an already existing one is added the old one is replaced by the new one.
templ’s reference count will be incremented, and any floating reference will be removed (see gst_object_ref_sink())
-
classmethod
add_static_metadata
(key, value)¶ Parameters: Set key with value as metadata in self.
Same as
Gst.ElementClass.add_metadata
(), but value must be a static string or an inlined string, as it will not be copied. (GStreamer plugins will be made resident once loaded, so this function can be used even from dynamically loaded plugins.)
-
classmethod
add_static_pad_template
(static_templ)¶ Parameters: static_templ ( Gst.StaticPadTemplate
) –Gst.StaticPadTemplate
to add as pad template to the element class.Adds a pad template to an element class based on the static pad template templ. This is mainly used in the _class_init functions of element implementations. If a pad template with the same name already exists, the old one is replaced by the new one.
New in version 1.8.
-
classmethod
add_static_pad_template_with_gtype
(static_templ, pad_type)¶ Parameters: - static_templ (
Gst.StaticPadTemplate
) –Gst.StaticPadTemplate
to add as pad template to the element class. - pad_type (
GObject.GType
) – TheGObject.GType
of the pad to create
Adds a pad template to an element class based on the static pad template templ. This is mainly used in the _class_init functions of element implementations. If a pad template with the same name already exists, the old one is replaced by the new one.
New in version 1.14.
- static_templ (
-
classmethod
get_metadata
(key)[source]¶ Parameters: key ( str
) – the key to getReturns: the metadata for key. Return type: str
Get metadata with key in self.
-
classmethod
get_pad_template
(name)[source]¶ Parameters: name ( str
) – the name of theGst.PadTemplate
to get.Returns: the Gst.PadTemplate
with the given name, orNone
if none was found. No unreferencing is necessary.Return type: Gst.PadTemplate
orNone
Retrieves a padtemplate from self with the given name.
If you use this function in the
GObject.InstanceInitFunc
of an object class that has subclasses, make sure to pass the g_class parameter of theGObject.InstanceInitFunc
here.
-
classmethod
get_pad_template_list
()[source]¶ Returns: the GLib.List
of pad templates.Return type: [ Gst.PadTemplate
]Retrieves a list of the pad templates associated with self. The list must not be modified by the calling code.
If you use this function in the
GObject.InstanceInitFunc
of an object class that has subclasses, make sure to pass the g_class parameter of theGObject.InstanceInitFunc
here.
-
classmethod
make_from_uri
(type, uri, elementname)[source]¶ Parameters: - type (
Gst.URIType
) – Whether to create a source or a sink - uri (
str
) – URI to create an element for - elementname (
str
orNone
) – Name of created element, can beNone
.
Raises: Returns: a new element or
None
if none could be createdReturn type: Creates an element for handling the given URI.
- type (
-
classmethod
register
(plugin, name, rank, type)[source]¶ Parameters: - plugin (
Gst.Plugin
orNone
) –Gst.Plugin
to register the element with, orNone
for a static element. - name (
str
) – name of elements of this type - rank (
int
) – rank of element (higher rank means more importance when autoplugging) - type (
GObject.GType
) –GObject.GType
of element to register
Returns: Return type: Create a new elementfactory capable of instantiating objects of the type and add the factory to plugin.
- plugin (
-
classmethod
set_metadata
(longname, classification, description, author)¶ Parameters: - longname (
str
) – The long English name of the element. E.g. “File Sink” - classification (
str
) – String describing the type of element, as an unordered list separated with slashes (‘/’). See draft-klass.txt of the design docs for more details and common types. E.g: “Sink/File” - description (
str
) – Sentence describing the purpose of the element. E.g: “Write stream to a file” - author (
str
) – Name and contact details of the author(s). Use \n to separate multiple author metadata. E.g: “Joe Bloggs <joe.blogs at foo.com>”
Sets the detailed information for a
Gst.ElementClass
.This function is for use in _class_init functions only.
- longname (
-
classmethod
set_static_metadata
(longname, classification, description, author)¶ Parameters: - longname (
str
) – The long English name of the element. E.g. “File Sink” - classification (
str
) – String describing the type of element, as an unordered list separated with slashes (‘/’). See draft-klass.txt of the design docs for more details and common types. E.g: “Sink/File” - description (
str
) – Sentence describing the purpose of the element. E.g: “Write stream to a file” - author (
str
) – Name and contact details of the author(s). Use \n to separate multiple author metadata. E.g: “Joe Bloggs <joe.blogs at foo.com>”
Sets the detailed information for a
Gst.ElementClass
.This function is for use in _class_init functions only.
Same as
Gst.ElementClass.set_metadata
(), but longname, classification, description, and author must be static strings or inlined strings, as they will not be copied. (GStreamer plugins will be made resident once loaded, so this function can be used even from dynamically loaded plugins.)- longname (
-
classmethod
state_change_return_get_name
(state_ret)[source]¶ Parameters: state_ret ( Gst.StateChangeReturn
) – aGst.StateChangeReturn
to get the name of.Returns: a string with the name of the state result. Return type: str
Gets a string representing the given state change result.
-
classmethod
state_get_name
(state)[source]¶ Parameters: state ( Gst.State
) – aGst.State
to get the name of.Returns: a string with the name of the state. Return type: str
Gets a string representing the given state.
-
abort_state
()[source]¶ Abort the state change of the element. This function is used by elements that do asynchronous state changes and find out something is wrong.
This function should be called with the STATE_LOCK held.
MT safe.
-
add_pad
(pad)[source]¶ Parameters: pad ( Gst.Pad
) – theGst.Pad
to add to the element.Returns: True
if the pad could be added. This function can fail when a pad with the same name already existed or the pad already had another parent.MT safe.
Return type: bool
Adds a pad (link point) to self. pad’s parent will be set to self; see
Gst.Object.set_parent
() for refcounting information.Pads are automatically activated when added in the PAUSED or PLAYING state.
The pad and the element should be unlocked when calling this function.
This function will emit the
Gst.Element
::pad-added
signal on the element.
-
add_property_deep_notify_watch
(property_name, include_value)[source]¶ Parameters: Returns: a watch id, which can be used in connection with
Gst.Element.remove_property_notify_watch
() to remove the watch again.Return type: New in version 1.10.
-
add_property_notify_watch
(property_name, include_value)[source]¶ Parameters: Returns: a watch id, which can be used in connection with
Gst.Element.remove_property_notify_watch
() to remove the watch again.Return type: New in version 1.10.
-
call_async
(func, *user_data)[source]¶ Parameters: - func (
Gst.ElementCallAsyncFunc
) – Function to call asynchronously from another thread - user_data (
object
orNone
) – Data to pass to func
Calls func from another thread and passes user_data to it. This is to be used for cases when a state change has to be performed from a streaming thread, directly via
Gst.Element.set_state
() or indirectly e.g. via SEEK events.Calling those functions directly from the streaming thread will cause deadlocks in many situations, as they might involve waiting for the streaming thread to shut down from this very streaming thread.
MT safe.
New in version 1.10.
- func (
-
change_state
(transition)[source]¶ Parameters: transition ( Gst.StateChange
) – the requested transitionReturns: the Gst.StateChangeReturn
of the state transition.Return type: Gst.StateChangeReturn
Perform transition on self.
This function must be called with STATE_LOCK held and is mainly used internally.
-
continue_state
(ret)[source]¶ Parameters: ret ( Gst.StateChangeReturn
) – The previous state return valueReturns: The result of the commit state change. MT safe.
Return type: Gst.StateChangeReturn
Commit the state change of the element and proceed to the next pending state if any. This function is used by elements that do asynchronous state changes. The core will normally call this method automatically when an element returned
Gst.StateChangeReturn.SUCCESS
from the state change function.If after calling this method the element still has not reached the pending state, the next state change is performed.
This method is used internally and should normally not be called by plugins or applications.
This function must be called with STATE_LOCK held.
-
create_all_pads
()[source]¶ Creates a pad for each pad template that is always available. This function is only useful during object initialization of subclasses of
Gst.Element
.
-
foreach_pad
(func, *user_data)[source]¶ Parameters: - func (
Gst.ElementForeachPadFunc
) – function to call for each pad - user_data (
object
orNone
) – user data passed to func
Returns: False
if self had no pads or if one of the calls to func returnedFalse
.Return type: Call func with user_data for each of self’s pads. func will be called exactly once for each pad that exists at the time of this call, unless one of the calls to func returns
False
in which case we will stop iterating pads and return early. If new pads are added or pads are removed while pads are being iterated, this will not be taken into account until next time this function is used.New in version 1.14.
- func (
-
foreach_sink_pad
(func, *user_data)[source]¶ Parameters: - func (
Gst.ElementForeachPadFunc
) – function to call for each sink pad - user_data (
object
orNone
) – user data passed to func
Returns: False
if self had no sink pads or if one of the calls to func returnedFalse
.Return type: Call func with user_data for each of self’s sink pads. func will be called exactly once for each sink pad that exists at the time of this call, unless one of the calls to func returns
False
in which case we will stop iterating pads and return early. If new sink pads are added or sink pads are removed while the sink pads are being iterated, this will not be taken into account until next time this function is used.New in version 1.14.
- func (
-
foreach_src_pad
(func, *user_data)[source]¶ Parameters: - func (
Gst.ElementForeachPadFunc
) – function to call for each source pad - user_data (
object
orNone
) – user data passed to func
Returns: False
if self had no source pads or if one of the calls to func returnedFalse
.Return type: Call func with user_data for each of self’s source pads. func will be called exactly once for each source pad that exists at the time of this call, unless one of the calls to func returns
False
in which case we will stop iterating pads and return early. If new source pads are added or source pads are removed while the source pads are being iterated, this will not be taken into account until next time this function is used.New in version 1.14.
- func (
-
get_base_time
()[source]¶ Returns: the base time of the element. MT safe.
Return type: int
Returns the base time of the element. The base time is the absolute time of the clock when this element was last put to PLAYING. Subtracting the base time from the clock time gives the running time of the element.
-
get_bus
()[source]¶ Returns: the element’s Gst.Bus
. unref after usage.MT safe.
Return type: Gst.Bus
orNone
Returns the bus of the element. Note that only a
Gst.Pipeline
will provide a bus for the application.
-
get_clock
()[source]¶ Returns: the Gst.Clock
of the element. unref after usage.MT safe.
Return type: Gst.Clock
orNone
Gets the currently configured clock of the element. This is the clock as was last set with
Gst.Element.set_clock
().Elements in a pipeline will only have their clock set when the pipeline is in the PLAYING state.
-
get_compatible_pad
(pad, caps)[source]¶ Parameters: Returns: the
Gst.Pad
to which a link can be made, orNone
if one cannot be found.Gst.Object.unref
() after usage.Return type: Looks for an unlinked pad to which the given pad can link. It is not guaranteed that linking the pads will work, though it should work in most cases.
This function will first attempt to find a compatible unlinked ALWAYS pad, and if none can be found, it will request a compatible REQUEST pad by looking at the templates of self.
-
get_compatible_pad_template
(compattempl)[source]¶ Parameters: compattempl ( Gst.PadTemplate
) – theGst.PadTemplate
to find a compatible template forReturns: a compatible Gst.PadTemplate
, orNone
if none was found. No unreferencing is necessary.Return type: Gst.PadTemplate
orNone
Retrieves a pad template from self that is compatible with compattempl. Pads from compatible templates can be linked together.
-
get_context
(context_type)[source]¶ Parameters: context_type ( str
) – a name of a context to retrieveReturns: A Gst.Context
orNone
Return type: Gst.Context
orNone
Gets the context with context_type set on the element or
None
.MT safe.
New in version 1.8.
-
get_context_unlocked
(context_type)[source]¶ Parameters: context_type ( str
) – a name of a context to retrieveReturns: A Gst.Context
orNone
Return type: Gst.Context
orNone
Gets the context with context_type set on the element or
None
.New in version 1.8.
-
get_contexts
()[source]¶ Returns: List of Gst.Context
Return type: [ Gst.Context
]Gets the contexts set on the element.
MT safe.
New in version 1.8.
-
get_current_clock_time
()[source]¶ Returns: the clock time of the element, or Gst.CLOCK_TIME_NONE
if there is no clock.Return type: int
Returns the current clock time of the element, as in, the time of the element’s clock, or
Gst.CLOCK_TIME_NONE
if there is no clock.New in version 1.18.
-
get_current_running_time
()[source]¶ Returns: the running time of the element, or Gst.CLOCK_TIME_NONE
if the element has no clock or its base time has not been set.Return type: int
Returns the running time of the element. The running time is the element’s clock time minus its base time. Will return
Gst.CLOCK_TIME_NONE
if the element has no clock, or if its base time has not been set.New in version 1.18.
-
get_factory
()[source]¶ Returns: the Gst.ElementFactory
used for creating this element orNone
if element has not been registered (static element). no refcounting is needed.Return type: Gst.ElementFactory
orNone
Retrieves the factory that was used to create this element.
-
get_metadata
(key)[source] Parameters: key ( str
) – the key to getReturns: the metadata for key. Return type: str
Get metadata with key in klass.
New in version 1.14.
-
get_pad_template
(name)[source] Parameters: name ( str
) – the name of theGst.PadTemplate
to get.Returns: the Gst.PadTemplate
with the given name, orNone
if none was found. No unreferencing is necessary.Return type: Gst.PadTemplate
orNone
Retrieves a padtemplate from self with the given name.
New in version 1.14.
-
get_pad_template_list
()[source] Returns: the GLib.List
of pad templates.Return type: [ Gst.PadTemplate
]Retrieves a list of the pad templates associated with self. The list must not be modified by the calling code.
New in version 1.14.
-
get_request_pad
(name)[source]¶ Parameters: name ( str
) – the name of the requestGst.Pad
to retrieve.Returns: requested Gst.Pad
if found, otherwiseNone
. Release after usage.Return type: Gst.Pad
orNone
Retrieves a pad from the element by name (e.g. “src_\%d”). This version only retrieves request pads. The pad should be released with
Gst.Element.release_request_pad
().This method is slower than manually getting the pad template and calling
Gst.Element.request_pad
() if the pads should have a specific name (e.g. name is “src_1” instead of “src_\%u”).
-
get_start_time
()[source]¶ Returns: the start time of the element. Return type: int
Returns the start time of the element. The start time is the running time of the clock when this element was last put to PAUSED.
Usually the start_time is managed by a toplevel element such as
Gst.Pipeline
.MT safe.
-
get_state
(timeout)[source]¶ Parameters: timeout ( int
) – a #GstClockTime to specify the timeout for an async state change orGst.CLOCK_TIME_NONE
for infinite timeout.Returns: Gst.StateChangeReturn.SUCCESS
if the element has no more pending state and the last state change succeeded,Gst.StateChangeReturn.ASYNC
if the element is still performing a state change orGst.StateChangeReturn.FAILURE
if the last state change failed.MT safe.
state: a pointer to Gst.State
to hold the state. Can beNone
.pending: a pointer to Gst.State
to hold the pending state. Can beNone
.Return type: ( Gst.StateChangeReturn
, state:Gst.State
, pending:Gst.State
)Gets the state of the element.
For elements that performed an ASYNC state change, as reported by
Gst.Element.set_state
(), this function will block up to the specified timeout value for the state change to complete. If the element completes the state change or goes into an error, this function returns immediately with a return value ofGst.StateChangeReturn.SUCCESS
orGst.StateChangeReturn.FAILURE
respectively.For elements that did not return
Gst.StateChangeReturn.ASYNC
, this function returns the current and pending state immediately.This function returns
Gst.StateChangeReturn.NO_PREROLL
if the element successfully changed its state but is not able to provide data yet. This mostly happens for live sources that only produce data inGst.State.PLAYING
. While the state change return is equivalent toGst.StateChangeReturn.SUCCESS
, it is returned to the application to signal that some sink elements might not be able to complete their state change because an element is not producing data to complete the preroll. When setting the element to playing, the preroll will complete and playback will start.
-
get_static_pad
(name)[source]¶ Parameters: name ( str
) – the name of the staticGst.Pad
to retrieve.Returns: the requested Gst.Pad
if found, otherwiseNone
. unref after usage.MT safe.
Return type: Gst.Pad
orNone
Retrieves a pad from self by name. This version only retrieves already-existing (i.e. ‘static’) pads.
-
is_locked_state
()[source]¶ Returns: True
, if the element’s state is locked.Return type: bool
Checks if the state of an element is locked. If the state of an element is locked, state changes of the parent don’t affect the element. This way you can leave currently unused elements inside bins. Just lock their state before changing the state from
Gst.State.NULL
.MT safe.
-
iterate_pads
()[source]¶ Returns: the Gst.Iterator
ofGst.Pad
.MT safe.
Return type: Gst.Iterator
Retrieves an iterator of self’s pads. The iterator should be freed after usage. Also more specialized iterators exists such as
Gst.Element.iterate_src_pads
() orGst.Element.iterate_sink_pads
().The order of pads returned by the iterator will be the order in which the pads were added to the element.
-
iterate_sink_pads
()[source]¶ Returns: the Gst.Iterator
ofGst.Pad
.MT safe.
Return type: Gst.Iterator
Retrieves an iterator of self’s sink pads.
The order of pads returned by the iterator will be the order in which the pads were added to the element.
-
iterate_src_pads
()[source]¶ Returns: the Gst.Iterator
ofGst.Pad
.MT safe.
Return type: Gst.Iterator
Retrieves an iterator of self’s source pads.
The order of pads returned by the iterator will be the order in which the pads were added to the element.
-
link
(dest)[source]¶ Parameters: dest ( Gst.Element
) – theGst.Element
containing the destination pad.Returns: True
if the elements could be linked,False
otherwise.Return type: bool
Links self to dest. The link must be from source to destination; the other direction will not be tried. The function looks for existing pads that aren’t linked yet. It will request new pads if necessary. Such pads need to be released manually when unlinking. If multiple links are possible, only one is established.
Make sure you have added your elements to a bin or pipeline with
Gst.Bin.add
() before trying to link them.
-
link_filtered
(dest, filter)[source]¶ Parameters: - dest (
Gst.Element
) – theGst.Element
containing the destination pad. - filter (
Gst.Caps
orNone
) – theGst.Caps
to filter the link, orNone
for no filter.
Returns: Return type: Links self to dest using the given caps as filtercaps. The link must be from source to destination; the other direction will not be tried. The function looks for existing pads that aren’t linked yet. It will request new pads if necessary. If multiple links are possible, only one is established.
Make sure you have added your elements to a bin or pipeline with
Gst.Bin.add
() before trying to link them.- dest (
-
link_pads
(srcpadname, dest, destpadname)[source]¶ Parameters: - srcpadname (
str
orNone
) – the name of theGst.Pad
in source element orNone
for any pad. - dest (
Gst.Element
) – theGst.Element
containing the destination pad. - destpadname (
str
orNone
) – the name of theGst.Pad
in destination element, orNone
for any pad.
Returns: Return type: Links the two named pads of the source and destination elements. Side effect is that if one of the pads has no parent, it becomes a child of the parent of the other element. If they have different parents, the link fails.
- srcpadname (
-
link_pads_filtered
(srcpadname, dest, destpadname, filter)[source]¶ Parameters: - srcpadname (
str
orNone
) – the name of theGst.Pad
in source element orNone
for any pad. - dest (
Gst.Element
) – theGst.Element
containing the destination pad. - destpadname (
str
orNone
) – the name of theGst.Pad
in destination element orNone
for any pad. - filter (
Gst.Caps
orNone
) – theGst.Caps
to filter the link, orNone
for no filter.
Returns: Return type: Links the two named pads of the source and destination elements. Side effect is that if one of the pads has no parent, it becomes a child of the parent of the other element. If they have different parents, the link fails. If caps is not
None
, makes sure that the caps of the link is a subset of caps.- srcpadname (
-
link_pads_full
(srcpadname, dest, destpadname, flags)[source]¶ Parameters: - srcpadname (
str
orNone
) – the name of theGst.Pad
in source element orNone
for any pad. - dest (
Gst.Element
) – theGst.Element
containing the destination pad. - destpadname (
str
orNone
) – the name of theGst.Pad
in destination element, orNone
for any pad. - flags (
Gst.PadLinkCheck
) – theGst.PadLinkCheck
to be performed when linking pads.
Returns: Return type: Links the two named pads of the source and destination elements. Side effect is that if one of the pads has no parent, it becomes a child of the parent of the other element. If they have different parents, the link fails.
Calling
Gst.Element.link_pads_full
() with flags ==Gst.PadLinkCheck.DEFAULT
is the same as callingGst.Element.link_pads
() and the recommended way of linking pads with safety checks applied.This is a convenience function for
Gst.Pad.link_full
().- srcpadname (
-
lost_state
()[source]¶ Brings the element to the lost state. The current state of the element is copied to the pending state so that any call to
Gst.Element.get_state
() will returnGst.StateChangeReturn.ASYNC
.An ASYNC_START message is posted. If the element was PLAYING, it will go to PAUSED. The element will be restored to its PLAYING state by the parent pipeline when it prerolls again.
This is mostly used for elements that lost their preroll buffer in the
Gst.State.PAUSED
orGst.State.PLAYING
state after a flush, they will go to their pending state again when a new preroll buffer is queued. This function can only be called when the element is currently not in error or an async state change.This function is used internally and should normally not be called from plugins or applications.
-
message_full
(type, domain, code, text, debug, file, function, line)[source]¶ Parameters: - type (
Gst.MessageType
) – theGst.MessageType
- domain (
int
) – the GStreamerGLib.Error
domain this message belongs to - code (
int
) – theGLib.Error
code belonging to the domain - text (
str
orNone
) – an allocated text string to be used as a replacement for the default message connected to code, orNone
- debug (
str
orNone
) – an allocated debug message to be used as a replacement for the default debugging information, orNone
- file (
str
) – the source code file where the error was generated - function (
str
) – the source code function where the error was generated - line (
int
) – the source code line where the error was generated
Post an error, warning or info message on the bus from inside an element.
type must be of
Gst.MessageType.ERROR
,Gst.MessageType.WARNING
orGst.MessageType.INFO
.MT safe.
- type (
-
message_full_with_details
(type, domain, code, text, debug, file, function, line, structure)[source]¶ Parameters: - type (
Gst.MessageType
) – theGst.MessageType
- domain (
int
) – the GStreamerGLib.Error
domain this message belongs to - code (
int
) – theGLib.Error
code belonging to the domain - text (
str
orNone
) – an allocated text string to be used as a replacement for the default message connected to code, orNone
- debug (
str
orNone
) – an allocated debug message to be used as a replacement for the default debugging information, orNone
- file (
str
) – the source code file where the error was generated - function (
str
) – the source code function where the error was generated - line (
int
) – the source code line where the error was generated - structure (
Gst.Structure
) – optional details structure
Post an error, warning or info message on the bus from inside an element.
type must be of
Gst.MessageType.ERROR
,Gst.MessageType.WARNING
orGst.MessageType.INFO
.New in version 1.10.
- type (
-
no_more_pads
()[source]¶ Use this function to signal that the element does not expect any more pads to show up in the current pipeline. This function should be called whenever pads have been added by the element itself. Elements with
Gst.PadPresence.SOMETIMES
pad templates use this in combination with autopluggers to figure out that the element is done initializing its pads.This function emits the
Gst.Element
::no-more-pads
signal.MT safe.
-
post_message
(message)[source]¶ Parameters: message ( Gst.Message
) – aGst.Message
to postReturns: True
if the message was successfully posted. The function returnsFalse
if the element did not have a bus.MT safe.
Return type: bool
Post a message on the element’s
Gst.Bus
. This function takes ownership of the message; if you want to access the message after this call, you should add an additional reference before calling.
-
provide_clock
()[source]¶ Returns: the Gst.Clock
provided by the element orNone
if no clock could be provided. Unref after usage.MT safe.
Return type: Gst.Clock
orNone
Get the clock provided by the given element.
An element is only required to provide a clock in the PAUSED state. Some elements can provide a clock in other states.
-
query
(query)[source]¶ Parameters: query ( Gst.Query
) – theGst.Query
.Returns: True
if the query could be performed.MT safe.
Return type: bool
Performs a query on the given element.
For elements that don’t implement a query handler, this function forwards the query to a random srcpad or to the peer of a random linked sinkpad of this element.
Please note that some queries might need a running pipeline to work.
-
query_convert
(src_format, src_val, dest_format)[source]¶ Parameters: - src_format (
Gst.Format
) – aGst.Format
to convert from. - src_val (
int
) – a value to convert. - dest_format (
Gst.Format
) – theGst.Format
to convert to.
Returns: True
if the query could be performed.dest_val: a pointer to the result. Return type: Queries an element to convert src_val in src_format to dest_format.
- src_format (
-
query_duration
(format)[source]¶ Parameters: format ( Gst.Format
) – theGst.Format
requestedReturns: True
if the query could be performed.duration: A location in which to store the total duration, or None
.Return type: ( bool
, duration:int
)Queries an element (usually top-level pipeline or playbin element) for the total stream duration in nanoseconds. This query will only work once the pipeline is prerolled (i.e. reached PAUSED or PLAYING state). The application will receive an ASYNC_DONE message on the pipeline bus when that is the case.
If the duration changes for some reason, you will get a DURATION_CHANGED message on the pipeline bus, in which case you should re-query the duration using this function.
-
query_position
(format)[source]¶ Parameters: format ( Gst.Format
) – theGst.Format
requestedReturns: True
if the query could be performed.cur: a location in which to store the current position, or None
.Return type: ( bool
, cur:int
)Queries an element (usually top-level pipeline or playbin element) for the stream position in nanoseconds. This will be a value between 0 and the stream duration (if the stream duration is known). This query will usually only work once the pipeline is prerolled (i.e. reached PAUSED or PLAYING state). The application will receive an ASYNC_DONE message on the pipeline bus when that is the case.
If one repeatedly calls this function one can also create a query and reuse it in
Gst.Element.query
().
-
release_request_pad
(pad)[source]¶ Parameters: pad ( Gst.Pad
) – theGst.Pad
to release.Makes the element free the previously requested pad as obtained with
Gst.Element.request_pad
().This does not unref the pad. If the pad was created by using
Gst.Element.request_pad
(),Gst.Element.release_request_pad
() needs to be followed byGst.Object.unref
() to free the pad.MT safe.
-
remove_pad
(pad)[source]¶ Parameters: pad ( Gst.Pad
) – theGst.Pad
to remove from the element.Returns: True
if the pad could be removed. Can returnFalse
if the pad does not belong to the provided element.MT safe.
Return type: bool
Removes pad from self. pad will be destroyed if it has not been referenced elsewhere using
Gst.Object.unparent
().This function is used by plugin developers and should not be used by applications. Pads that were dynamically requested from elements with
Gst.Element.request_pad
() should be released with theGst.Element.release_request_pad
() function instead.Pads are not automatically deactivated so elements should perform the needed steps to deactivate the pad in case this pad is removed in the PAUSED or PLAYING state. See
Gst.Pad.set_active
() for more information about deactivating pads.The pad and the element should be unlocked when calling this function.
This function will emit the
Gst.Element
::pad-removed
signal on the element.
-
remove_property_notify_watch
(watch_id)[source]¶ Parameters: watch_id ( int
) – watch id to removeNew in version 1.10.
-
request_pad
(templ, name, caps)[source]¶ Parameters: - templ (
Gst.PadTemplate
) – aGst.PadTemplate
of which we want a pad of. - name (
str
orNone
) – the name of the requestGst.Pad
to retrieve. Can beNone
. - caps (
Gst.Caps
orNone
) – the caps of the pad we want to request. Can beNone
.
Returns: requested
Gst.Pad
if found, otherwiseNone
. Release after usage.Return type: Retrieves a request pad from the element according to the provided template. Pad templates can be looked up using
Gst.ElementFactory.get_static_pad_templates
().The pad should be released with
Gst.Element.release_request_pad
().- templ (
-
seek
(rate, format, flags, start_type, start, stop_type, stop)[source]¶ Parameters: - rate (
float
) – The new playback rate - format (
Gst.Format
) – The format of the seek values - flags (
Gst.SeekFlags
) – The optional seek flags. - start_type (
Gst.SeekType
) – The type and flags for the new start position - start (
int
) – The value of the new start position - stop_type (
Gst.SeekType
) – The type and flags for the new stop position - stop (
int
) – The value of the new stop position
Returns: True
if the event was handled. Flushing seeks will trigger a preroll, which will emitGst.MessageType.ASYNC_DONE
.Return type: Sends a seek event to an element. See
Gst.Event.new_seek
() for the details of the parameters. The seek event is sent to the element usingGst.Element.send_event
().MT safe.
- rate (
-
seek_simple
(format, seek_flags, seek_pos)[source]¶ Parameters: - format (
Gst.Format
) – aGst.Format
to execute the seek in, such asGst.Format.TIME
- seek_flags (
Gst.SeekFlags
) – seek options; playback applications will usually want to useGst.SeekFlags.FLUSH
|Gst.SeekFlags.KEY_UNIT
here - seek_pos (
int
) – position to seek to (relative to the start); if you are doing a seek inGst.Format.TIME
this value is in nanoseconds - multiply withGst.SECOND
to convert seconds to nanoseconds or withGst.MSECOND
to convert milliseconds to nanoseconds.
Returns: True
if the seek operation succeeded. Flushing seeks will trigger a preroll, which will emitGst.MessageType.ASYNC_DONE
.Return type: Simple API to perform a seek on the given element, meaning it just seeks to the given position relative to the start of the stream. For more complex operations like segment seeks (e.g. for looping) or changing the playback rate or seeking relative to the last configured playback segment you should use
Gst.Element.seek
().In a completely prerolled PAUSED or PLAYING pipeline, seeking is always guaranteed to return
True
on a seekable media type orFalse
when the media type is certainly not seekable (such as a live stream).Some elements allow for seeking in the READY state, in this case they will store the seek event and execute it when they are put to PAUSED. If the element supports seek in READY, it will always return
True
when it receives the event in the READY state.- format (
-
send_event
(event)[source]¶ Parameters: event ( Gst.Event
) – theGst.Event
to send to the element.Returns: True
if the event was handled. Events that trigger a preroll (such as flushing seeks and steps) will emitGst.MessageType.ASYNC_DONE
.Return type: bool
Sends an event to an element. If the element doesn’t implement an event handler, the event will be pushed on a random linked sink pad for downstream events or a random linked source pad for upstream events.
This function takes ownership of the provided event so you should gst_event_ref() it if you want to reuse the event after this call.
MT safe.
-
set_base_time
(time)[source]¶ Parameters: time ( int
) – the base time to set.Set the base time of an element. See
Gst.Element.get_base_time
().MT safe.
-
set_bus
(bus)[source]¶ Parameters: bus ( Gst.Bus
orNone
) – theGst.Bus
to set.Sets the bus of the element. Increases the refcount on the bus. For internal use only, unless you’re testing elements.
MT safe.
-
set_clock
(clock)[source]¶ Parameters: clock ( Gst.Clock
orNone
) – theGst.Clock
to set for the element.Returns: True
if the element accepted the clock. An element can refuse a clock when it, for example, is not able to slave its internal clock to the clock or when it requires a specific clock to operate.MT safe.
Return type: bool
Sets the clock for the element. This function increases the refcount on the clock. Any previously set clock on the object is unreffed.
-
set_context
(context)[source]¶ Parameters: context ( Gst.Context
) – theGst.Context
to set.Sets the context of the element. Increases the refcount of the context.
MT safe.
-
set_locked_state
(locked_state)[source]¶ Parameters: locked_state ( bool
) –True
to lock the element’s stateReturns: True
if the state was changed,False
if bad parameters were given or the elements state-locking needed no change.Return type: bool
Locks the state of an element, so state changes of the parent don’t affect this element anymore.
Note that this is racy if the state lock of the parent bin is not taken. The parent bin might’ve just checked the flag in another thread and as the next step proceed to change the child element’s state.
MT safe.
-
set_start_time
(time)[source]¶ Parameters: time ( int
) – the base time to set.Set the start time of an element. The start time of the element is the running time of the element when it last went to the PAUSED state. In READY or after a flushing seek, it is set to 0.
Toplevel elements like
Gst.Pipeline
will manage the start_time and base_time on its children. Setting the start_time toGst.CLOCK_TIME_NONE
on such a toplevel element will disable the distribution of the base_time to the children and can be useful if the application manages the base_time itself, for example if you want to synchronize capture from multiple pipelines, and you can also ensure that the pipelines have the same clock.MT safe.
-
set_state
(state)[source]¶ Parameters: state ( Gst.State
) – the element’s newGst.State
.Returns: Result of the state change using Gst.StateChangeReturn
.MT safe.
Return type: Gst.StateChangeReturn
Sets the state of the element. This function will try to set the requested state by going through all the intermediary states and calling the class’s state change function for each.
This function can return
Gst.StateChangeReturn.ASYNC
, in which case the element will perform the remainder of the state change asynchronously in another thread. An application can useGst.Element.get_state
() to wait for the completion of the state change or it can wait for aGst.MessageType.ASYNC_DONE
orGst.MessageType.STATE_CHANGED
on the bus.State changes to
Gst.State.READY
orGst.State.NULL
never returnGst.StateChangeReturn.ASYNC
.
-
sync_state_with_parent
()[source]¶ Returns: True
, if the element’s state could be synced to the parent’s state.MT safe.
Return type: bool
Tries to change the state of the element to the same as its parent. If this function returns
False
, the state of element is undefined.
-
unlink
(dest)[source]¶ Parameters: dest ( Gst.Element
) – the sinkGst.Element
to unlink.Unlinks all source pads of the source element with all sink pads of the sink element to which they are linked.
If the link has been made using
Gst.Element.link
(), it could have created an requestpad, which has to be released usingGst.Element.release_request_pad
().
-
unlink_pads
(srcpadname, dest, destpadname)[source]¶ Parameters: - srcpadname (
str
) – the name of theGst.Pad
in source element. - dest (
Gst.Element
) – aGst.Element
containing the destination pad. - destpadname (
str
) – the name of theGst.Pad
in destination element.
Unlinks the two named pads of the source and destination elements.
This is a convenience function for
Gst.Pad.unlink
().- srcpadname (
-
do_change_state
(transition) virtual¶ Parameters: transition ( Gst.StateChange
) – the requested transitionReturns: the Gst.StateChangeReturn
of the state transition.Return type: Gst.StateChangeReturn
Perform transition on element.
This function must be called with STATE_LOCK held and is mainly used internally.
-
do_get_state
(timeout) virtual¶ Parameters: timeout ( int
) – a #GstClockTime to specify the timeout for an async state change orGst.CLOCK_TIME_NONE
for infinite timeout.Returns: Gst.StateChangeReturn.SUCCESS
if the element has no more pending state and the last state change succeeded,Gst.StateChangeReturn.ASYNC
if the element is still performing a state change orGst.StateChangeReturn.FAILURE
if the last state change failed.MT safe.
state: a pointer to Gst.State
to hold the state. Can beNone
.pending: a pointer to Gst.State
to hold the pending state. Can beNone
.Return type: ( Gst.StateChangeReturn
, state:Gst.State
, pending:Gst.State
)Gets the state of the element.
For elements that performed an ASYNC state change, as reported by
Gst.Element.set_state
(), this function will block up to the specified timeout value for the state change to complete. If the element completes the state change or goes into an error, this function returns immediately with a return value ofGst.StateChangeReturn.SUCCESS
orGst.StateChangeReturn.FAILURE
respectively.For elements that did not return
Gst.StateChangeReturn.ASYNC
, this function returns the current and pending state immediately.This function returns
Gst.StateChangeReturn.NO_PREROLL
if the element successfully changed its state but is not able to provide data yet. This mostly happens for live sources that only produce data inGst.State.PLAYING
. While the state change return is equivalent toGst.StateChangeReturn.SUCCESS
, it is returned to the application to signal that some sink elements might not be able to complete their state change because an element is not producing data to complete the preroll. When setting the element to playing, the preroll will complete and playback will start.
-
do_no_more_pads
() virtual¶ Use this function to signal that the element does not expect any more pads to show up in the current pipeline. This function should be called whenever pads have been added by the element itself. Elements with
Gst.PadPresence.SOMETIMES
pad templates use this in combination with autopluggers to figure out that the element is done initializing its pads.This function emits the
Gst.Element
::no-more-pads
signal.MT safe.
-
do_post_message
(message) virtual¶ Parameters: message ( Gst.Message
) – aGst.Message
to postReturns: True
if the message was successfully posted. The function returnsFalse
if the element did not have a bus.MT safe.
Return type: bool
Post a message on the element’s
Gst.Bus
. This function takes ownership of the message; if you want to access the message after this call, you should add an additional reference before calling.
-
do_provide_clock
() virtual¶ Returns: the Gst.Clock
provided by the element orNone
if no clock could be provided. Unref after usage.MT safe.
Return type: Gst.Clock
orNone
Get the clock provided by the given element.
An element is only required to provide a clock in the PAUSED state. Some elements can provide a clock in other states.
-
do_query
(query) virtual¶ Parameters: query ( Gst.Query
) – theGst.Query
.Returns: True
if the query could be performed.MT safe.
Return type: bool
Performs a query on the given element.
For elements that don’t implement a query handler, this function forwards the query to a random srcpad or to the peer of a random linked sinkpad of this element.
Please note that some queries might need a running pipeline to work.
-
do_request_new_pad
(templ, name, caps) virtual¶ Parameters: - templ (
Gst.PadTemplate
) – aGst.PadTemplate
of which we want a pad of. - name (
str
orNone
) – the name of the requestGst.Pad
to retrieve. Can beNone
. - caps (
Gst.Caps
orNone
) – the caps of the pad we want to request. Can beNone
.
Returns: requested
Gst.Pad
if found, otherwiseNone
. Release after usage.Return type: Retrieves a request pad from the element according to the provided template. Pad templates can be looked up using
Gst.ElementFactory.get_static_pad_templates
().The pad should be released with
Gst.Element.release_request_pad
().- templ (
-
do_send_event
(event) virtual¶ Parameters: event ( Gst.Event
) – theGst.Event
to send to the element.Returns: True
if the event was handled. Events that trigger a preroll (such as flushing seeks and steps) will emitGst.MessageType.ASYNC_DONE
.Return type: bool
Sends an event to an element. If the element doesn’t implement an event handler, the event will be pushed on a random linked sink pad for downstream events or a random linked source pad for upstream events.
This function takes ownership of the provided event so you should gst_event_ref() it if you want to reuse the event after this call.
MT safe.
-
do_set_bus
(bus) virtual¶ Parameters: bus ( Gst.Bus
orNone
) – theGst.Bus
to set.Sets the bus of the element. Increases the refcount on the bus. For internal use only, unless you’re testing elements.
MT safe.
-
do_set_clock
(clock) virtual¶ Parameters: clock ( Gst.Clock
orNone
) – theGst.Clock
to set for the element.Returns: True
if the element accepted the clock. An element can refuse a clock when it, for example, is not able to slave its internal clock to the clock or when it requires a specific clock to operate.MT safe.
Return type: bool
Sets the clock for the element. This function increases the refcount on the clock. Any previously set clock on the object is unreffed.
-
do_set_context
(context) virtual¶ Parameters: context ( Gst.Context
) – theGst.Context
to set.Sets the context of the element. Increases the refcount of the context.
MT safe.
-
do_set_state
(state) virtual¶ Parameters: state ( Gst.State
) – the element’s newGst.State
.Returns: Result of the state change using Gst.StateChangeReturn
.MT safe.
Return type: Gst.StateChangeReturn
Sets the state of the element. This function will try to set the requested state by going through all the intermediary states and calling the class’s state change function for each.
This function can return
Gst.StateChangeReturn.ASYNC
, in which case the element will perform the remainder of the state change asynchronously in another thread. An application can useGst.Element.get_state
() to wait for the completion of the state change or it can wait for aGst.MessageType.ASYNC_DONE
orGst.MessageType.STATE_CHANGED
on the bus.State changes to
Gst.State.READY
orGst.State.NULL
never returnGst.StateChangeReturn.ASYNC
.
-
classmethod
Signal Details¶
-
Gst.Element.signals.
no_more_pads
(element)¶ Signal Name: no-more-pads
Flags: RUN_LAST
Parameters: element ( Gst.Element
) – The object which received the signalThis signals that the element will not generate more dynamic pads. Note that this signal will usually be emitted from the context of the streaming thread.
-
Gst.Element.signals.
pad_added
(element, new_pad)¶ Signal Name: pad-added
Flags: Parameters: - element (
Gst.Element
) – The object which received the signal - new_pad (
Gst.Pad
) – the pad that has been added
a new
Gst.Pad
has been added to the element. Note that this signal will usually be emitted from the context of the streaming thread. Also keep in mind that if you add new elements to the pipeline in the signal handler you will need to set them to the desired target state withGst.Element.set_state
() orGst.Element.sync_state_with_parent
().- element (
-
Gst.Element.signals.
pad_removed
(element, old_pad)¶ Signal Name: pad-removed
Flags: Parameters: - element (
Gst.Element
) – The object which received the signal - old_pad (
Gst.Pad
) – the pad that has been removed
a
Gst.Pad
has been removed from the element- element (