pub trait TrackElementExt: 'static {
Show 32 methods
fn add_children_props(
&self,
element: &impl IsA<Element>,
wanted_categories: &[&str],
blacklist: &[&str],
whitelist: &[&str]
);
fn clamp_control_source(&self, property_name: &str);
fn edit(
&self,
layers: &[Layer],
mode: EditMode,
edge: Edge,
position: u64
) -> Result<(), BoolError>;
fn is_auto_clamp_control_sources(&self) -> bool;
fn child_property(&self, property_name: &str) -> Option<Value>;
fn child_property_by_pspec(&self, pspec: impl AsRef<ParamSpec>) -> Value;
fn control_binding(&self, property_name: &str) -> Option<ControlBinding>;
fn element(&self) -> Option<Element>;
fn gnlobject(&self) -> Element;
fn nleobject(&self) -> Element;
fn track(&self) -> Option<Track>;
fn track_type(&self) -> TrackType;
fn has_internal_source(&self) -> bool;
fn is_active(&self) -> bool;
fn is_core(&self) -> bool;
fn list_children_properties(&self) -> Vec<ParamSpec> ⓘ;
fn lookup_child(&self, prop_name: &str) -> Option<(Element, ParamSpec)>;
fn remove_control_binding(
&self,
property_name: &str
) -> Result<(), BoolError>;
fn set_active(&self, active: bool) -> bool;
fn set_auto_clamp_control_sources(&self, auto_clamp: bool);
fn set_child_property(
&self,
property_name: &str,
value: &Value
) -> Result<(), BoolError>;
fn set_child_property_by_pspec(
&self,
pspec: impl AsRef<ParamSpec>,
value: &Value
);
fn set_control_source(
&self,
source: &impl IsA<ControlSource>,
property_name: &str,
binding_type: &str
) -> bool;
fn set_has_internal_source(&self, has_internal_source: bool) -> bool;
fn set_track_type(&self, type_: TrackType);
fn connect_control_binding_added<F: Fn(&Self, &ControlBinding) + 'static>(
&self,
f: F
) -> SignalHandlerId;
fn connect_control_binding_removed<F: Fn(&Self, &ControlBinding) + 'static>(
&self,
f: F
) -> SignalHandlerId;
fn connect_active_notify<F: Fn(&Self) + 'static>(
&self,
f: F
) -> SignalHandlerId;
fn connect_auto_clamp_control_sources_notify<F: Fn(&Self) + 'static>(
&self,
f: F
) -> SignalHandlerId;
fn connect_has_internal_source_notify<F: Fn(&Self) + 'static>(
&self,
f: F
) -> SignalHandlerId;
fn connect_track_notify<F: Fn(&Self) + 'static>(
&self,
f: F
) -> SignalHandlerId;
fn connect_track_type_notify<F: Fn(&Self) + 'static>(
&self,
f: F
) -> SignalHandlerId;
}
Expand description
Required Methods§
sourcefn add_children_props(
&self,
element: &impl IsA<Element>,
wanted_categories: &[&str],
blacklist: &[&str],
whitelist: &[&str]
)
fn add_children_props(
&self,
element: &impl IsA<Element>,
wanted_categories: &[&str],
blacklist: &[&str],
whitelist: &[&str]
)
Adds all the properties of a gst::Element
that match the criteria as
children properties of the track element. If the name of element
’s
gst::ElementFactory
is not in blacklist
, and the factory’s
GST_ELEMENT_METADATA_KLASS
contains at least one member of
wanted_categories
(e.g. GST_ELEMENT_FACTORY_KLASS_DECODER
), then
all the properties of element
that are also in whitelist
are added as
child properties of self
using
TimelineElementExt::add_child_property()
.
This is intended to be used by subclasses when constructing.
element
The child object to retrieve properties from
wanted_categories
An array of element factory “klass” categories to whitelist, or None
to accept all categories
blacklist
A
blacklist of element factory names, or None
to not blacklist any
element factory
whitelist
A
whitelist of element property names, or None
to whitelist all
writeable properties
sourcefn clamp_control_source(&self, property_name: &str)
fn clamp_control_source(&self, property_name: &str)
v1_18
only.Clamp the GstTimedValueControlSource
for the specified child property
to lie between the in-point
and out-point of the
element. The out-point is the GES_TIMELINE_ELEMENT_END
of the element
translated from the timeline coordinates to the internal source
coordinates of the element.
If the property does not have a GstTimedValueControlSource
set by
set_control_source()
, nothing happens. Otherwise, if
a timed value for the control source lies before the in-point of the
element, or after its out-point, then it will be removed. At the
in-point and out-point times, a new interpolated value will be placed.
property_name
The name of the child property to clamp the control source of
sourcefn edit(
&self,
layers: &[Layer],
mode: EditMode,
edge: Edge,
position: u64
) -> Result<(), BoolError>
fn edit(
&self,
layers: &[Layer],
mode: EditMode,
edge: Edge,
position: u64
) -> Result<(), BoolError>
Edits the element within its track.
Deprecated since 1.18
use ges_timeline_element_edit
instead.
layers
A whitelist of layers
where the edit can be performed, None
allows all layers in the
timeline
mode
The edit mode
edge
The edge of self
where the edit should occur
position
The edit position: a new location for the edge of self
(in nanoseconds)
Returns
sourcefn is_auto_clamp_control_sources(&self) -> bool
fn is_auto_clamp_control_sources(&self) -> bool
v1_18
only.Gets auto-clamp-control-sources
.
Returns
Whether the control sources for the child properties of
self
are automatically clamped.
sourcefn child_property(&self, property_name: &str) -> Option<Value>
fn child_property(&self, property_name: &str) -> Option<Value>
In general, a copy is made of the property contents and
the caller is responsible for freeing the memory by calling
[glib::Value::unset()
][crate::glib::Value::unset()].
Gets a property of a GstElement contained in self
.
Note that ges_track_element_get_child_property
is really
intended for language bindings, ges_track_element_get_child_properties
is much more convenient for C programming.
Deprecated
Use ges_timeline_element_get_child_property
property_name
The name of the property
Returns
true
if the property was found, false
otherwise.
value
return location for the property value, it will be initialized if it is initialized with 0
sourcefn child_property_by_pspec(&self, pspec: impl AsRef<ParamSpec>) -> Value
fn child_property_by_pspec(&self, pspec: impl AsRef<ParamSpec>) -> Value
Gets a property of a child of self
.
Deprecated
Use ges_timeline_element_get_child_property_by_pspec
pspec
The glib::ParamSpec
that specifies the property you want to get
Returns
value
return location for the value
fn control_binding(&self, property_name: &str) -> Option<ControlBinding>
fn element(&self) -> Option<Element>
fn gnlobject(&self) -> Element
fn nleobject(&self) -> Element
fn track(&self) -> Option<Track>
fn track_type(&self) -> TrackType
sourcefn has_internal_source(&self) -> bool
fn has_internal_source(&self) -> bool
v1_18
only.fn is_active(&self) -> bool
fn list_children_properties(&self) -> Vec<ParamSpec> ⓘ
fn lookup_child(&self, prop_name: &str) -> Option<(Element, ParamSpec)>
fn remove_control_binding(&self, property_name: &str) -> Result<(), BoolError>
fn set_active(&self, active: bool) -> bool
sourcefn set_auto_clamp_control_sources(&self, auto_clamp: bool)
fn set_auto_clamp_control_sources(&self, auto_clamp: bool)
v1_18
only.fn set_child_property(
&self,
property_name: &str,
value: &Value
) -> Result<(), BoolError>
fn set_child_property_by_pspec(&self, pspec: impl AsRef<ParamSpec>, value: &Value)
fn set_control_source(
&self,
source: &impl IsA<ControlSource>,
property_name: &str,
binding_type: &str
) -> bool
sourcefn set_has_internal_source(&self, has_internal_source: bool) -> bool
fn set_has_internal_source(&self, has_internal_source: bool) -> bool
v1_18
only.fn set_track_type(&self, type_: TrackType)
fn connect_control_binding_added<F: Fn(&Self, &ControlBinding) + 'static>(
&self,
f: F
) -> SignalHandlerId
fn connect_control_binding_removed<F: Fn(&Self, &ControlBinding) + 'static>(
&self,
f: F
) -> SignalHandlerId
fn connect_active_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId
sourcefn connect_auto_clamp_control_sources_notify<F: Fn(&Self) + 'static>(
&self,
f: F
) -> SignalHandlerId
fn connect_auto_clamp_control_sources_notify<F: Fn(&Self) + 'static>(
&self,
f: F
) -> SignalHandlerId
v1_18
only.sourcefn connect_has_internal_source_notify<F: Fn(&Self) + 'static>(
&self,
f: F
) -> SignalHandlerId
fn connect_has_internal_source_notify<F: Fn(&Self) + 'static>(
&self,
f: F
) -> SignalHandlerId
v1_18
only.