Top | ![]() |
![]() |
![]() |
![]() |
GESSimpleTimelineLayerGESSimpleTimelineLayer — High-level GESTimelineLayer |
GESSimpleTimelineLayer * | ges_simple_timeline_layer_new () |
gboolean | ges_simple_timeline_layer_add_object () |
gboolean | ges_simple_timeline_layer_move_object () |
GESTimelineObject * | ges_simple_timeline_layer_nth () |
gint | ges_simple_timeline_layer_index () |
gboolean | ges_simple_timeline_layer_is_valid () |
GESSimpleTimelineLayer allows using GESTimelineObject(s) with a list-like API. Clients can add any type of GESTimelineObject to a GESSimpleTimelineLayer, and the layer will automatically compute the appropriate start times.
Users should be aware that GESTimelineTransition objects are considered to have a negative duration for the purposes of positioning GESTimelineSource objects (i.e., adding a GESTimelineTransition creates an overlap between the two adjacent sources.
GESSimpleTimelineLayer *
ges_simple_timeline_layer_new (void
);
Creates a new GESSimpleTimelineLayer.
gboolean ges_simple_timeline_layer_add_object (GESSimpleTimelineLayer *layer
,GESTimelineObject *object
,gint position
);
Adds the object at the given position in the layer. The position is where the object will be inserted. To put the object before all objects, use position 0. To put after all objects, use position -1.
When adding transitions, it is important that the adjacent objects (objects at position, and position + 1) be (1) A derivative of GESTimelineSource or other non-transition, and (2) have a duration at least as long as the duration of the transition.
The layer will steal a reference to the provided object.
layer |
||
object |
the GESTimelineObject to add |
|
position |
the position at which to add the object |
gboolean ges_simple_timeline_layer_move_object (GESSimpleTimelineLayer *layer
,GESTimelineObject *object
,gint newposition
);
Moves the object to the given position in the layer. To put the object before all other objects, use position 0. To put the objects after all objects, use position -1.
layer |
||
object |
the GESTimelineObject to move |
|
newposition |
the new position at which to move the object |
GESTimelineObject * ges_simple_timeline_layer_nth (GESSimpleTimelineLayer *layer
,gint position
);
Gets the timeline object at the given position.
The GESTimelineObject at the given position or NULL if the position is off the end of the layer.
[transfer none]
gint ges_simple_timeline_layer_index (GESSimpleTimelineLayer *layer
,GESTimelineObject *object
);
Gets the position of the given object within the given layer.
gboolean
ges_simple_timeline_layer_is_valid (GESSimpleTimelineLayer *layer
);
Checks whether the arrangement of objects in the layer would cause errors or unexpected output during playback. Do not set the containing pipeline state to PLAYING when this property is FALSE.
“object-moved”
signalvoid user_function (GESSimpleTimelineLayer *layer, GESTimelineObject *object, gint old, gint new, gpointer user_data)
Will be emitted when an object is moved with ges_simple_timeline_layer_move_object.
layer |
||
object |
the GESTimelineObject that was added |
|
old |
the previous position of the object |
|
new |
the new position of the object |
|
user_data |
user data set when the signal handler was connected. |
Flags: Run First