gi-ges-1.0.4: libges bindings
CopyrightWill Thompson and Iñaki García Etxebarria
LicenseLGPL-2.1
MaintainerIñaki García Etxebarria
Safe HaskellSafe-Inferred
LanguageHaskell2010

GI.GES.Objects.TimelineElement

Description

A TimelineElement will have some temporal extent in its corresponding TimelineElement:timeline, controlled by its TimelineElement:start and TimelineElement:duration. This determines when its content will be displayed, or its effect applied, in the timeline. Several objects may overlap within a given Timeline, in which case their TimelineElement:priority is used to determine their ordering in the timeline. Priority is mostly handled internally by Layer-s and Clip-s.

A timeline element can have a TimelineElement:parent, such as a Clip, which is responsible for controlling its timing.

Editing

Elements can be moved around in their TimelineElement:timeline by setting their TimelineElement:start and TimelineElement:duration using timelineElementSetStart and timelineElementSetDuration. Additionally, which parts of the underlying content are played in the timeline can be adjusted by setting the TimelineElement:inPoint using timelineElementSetInpoint. The library also provides timelineElementEdit, with various EditMode-s, which can adjust these properties in a convenient way, as well as introduce similar changes in neighbouring or later elements in the timeline.

However, a timeline may refuse a change in these properties if they would place the timeline in an unsupported configuration. See Timeline for its overlap rules.

Additionally, an edit may be refused if it would place one of the timing properties out of bounds (such as a negative time value for TimelineElement:start, or having insufficient internal content to last for the desired TimelineElement:duration).

Time Coordinates

There are three main sets of time coordinates to consider when using timeline elements:

+ Timeline coordinates: these are the time coordinates used in the output of the timeline in its Track-s. Each track share the same coordinates, so there is only one set of coordinates for the timeline. These extend indefinitely from 0. The times used for editing (including setting TimelineElement:start and TimelineElement:duration) use these coordinates, since these define when an element is present and for how long the element lasts for in the timeline. + Internal source coordinates: these are the time coordinates used internally at the element's output. This is only really defined for TrackElement-s, where it refers to time coordinates used at the final source pad of the wrapped Element-s. However, these coordinates may also be used in a Clip in reference to its children. In particular, these are the coordinates used for TimelineElement:inPoint and TimelineElement:maxDuration. + Internal sink coordinates: these are the time coordinates used internally at the element's input. A Source has no input, so these would be undefined. Otherwise, for most TrackElement-s these will be the same set of coordinates as the internal source coordinates because the element does not change the timing internally. Only BaseEffect can support elements where these are different. See BaseEffect for more information.

You can determine the timeline time for a given internal source time in a Track in a Clip using clipGetTimelineTimeFromInternalTime, and vice versa using clipGetInternalTimeFromTimelineTime, for the purposes of editing and setting timings properties.

Children Properties

If a timeline element owns another Object and wishes to expose some of its properties, it can do so by registering the property as one of the timeline element's children properties using timelineElementAddChildProperty. The registered property of the child can then be read and set using the timelineElementGetChildProperty and timelineElementSetChildProperty methods, respectively. Some sub-classed objects will be created with pre-registered children properties; for example, to expose part of an underlying Element that is used internally. The registered properties can be listed with timelineElementListChildrenProperties.

Synopsis

Exported types

newtype TimelineElement Source #

Memory-managed wrapper type.

Constructors

TimelineElement (ManagedPtr TimelineElement) 

Instances

Instances details
Eq TimelineElement Source # 
Instance details

Defined in GI.GES.Objects.TimelineElement

GObject TimelineElement Source # 
Instance details

Defined in GI.GES.Objects.TimelineElement

ManagedPtrNewtype TimelineElement Source # 
Instance details

Defined in GI.GES.Objects.TimelineElement

TypedObject TimelineElement Source # 
Instance details

Defined in GI.GES.Objects.TimelineElement

Methods

glibType :: IO GType

HasParentTypes TimelineElement Source # 
Instance details

Defined in GI.GES.Objects.TimelineElement

IsGValue (Maybe TimelineElement) Source #

Convert TimelineElement to and from GValue. See toGValue and fromGValue.

Instance details

Defined in GI.GES.Objects.TimelineElement

Methods

gvalueGType_ :: IO GType

gvalueSet_ :: Ptr GValue -> Maybe TimelineElement -> IO ()

gvalueGet_ :: Ptr GValue -> IO (Maybe TimelineElement)

type ParentTypes TimelineElement Source # 
Instance details

Defined in GI.GES.Objects.TimelineElement

type ParentTypes TimelineElement = '[Object, Extractable, MetaContainer]

class (GObject o, IsDescendantOf TimelineElement o) => IsTimelineElement o Source #

Type class for types which can be safely cast to TimelineElement, for instance with toTimelineElement.

Instances

Instances details
(GObject o, IsDescendantOf TimelineElement o) => IsTimelineElement o Source # 
Instance details

Defined in GI.GES.Objects.TimelineElement

toTimelineElement :: (MonadIO m, IsTimelineElement o) => o -> m TimelineElement Source #

Cast to TimelineElement, for types for which this is known to be safe. For general casts, use castTo.

Methods

addChildProperty

timelineElementAddChildProperty Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a, IsObject b) 
=> a

self: A TimelineElement

-> GParamSpec

pspec: The specification for the property to add

-> b

child: The Object who the property belongs to

-> m Bool

Returns: True if the property was successfully registered.

Register a property of a child of the element to allow it to be written with timelineElementSetChildProperty and read with timelineElementGetChildProperty. A change in the property will also appear in the TimelineElement::deepNotify signal.

pspec should be unique from other children properties that have been registered on self.

copy

timelineElementCopy Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: The TimelineElement to copy

-> Bool

deep: Whether the copy is needed for pasting

-> m TimelineElement

Returns: The newly create element, copied from self.

Create a copy of self. All the properties of self are copied into a new element, with the exception of TimelineElement:parent, TimelineElement:timeline and TimelineElement:name. Other data, such the list of a Container's children, is **not** copied.

If deep is True, then the new element is prepared so that it can be used in timelineElementPaste or timelinePasteElement. In the case of copying a Container, this ensures that the children of self will also be pasted. The new element should not be used for anything else and can only be used **once** in a pasting operation. In particular, the new element itself is not an actual 'deep' copy of self, but should be thought of as an intermediate object used for a single paste operation.

edit

timelineElementEdit Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a, IsLayer b) 
=> a

self: The TimelineElement to edit

-> [b]

layers: A whitelist of layers where the edit can be performed, Nothing allows all layers in the timeline.

-> Int64

newLayerPriority: The priority/index of the layer self should be moved to. -1 means no move

-> EditMode

mode: The edit mode

-> Edge

edge: The edge of self where the edit should occur

-> Word64

position: The edit position: a new location for the edge of self (in nanoseconds) in the timeline coordinates

-> m Bool

Returns: True if the edit of self completed, False on failure.

See timelineElementEditFull, which also gives an error.

Note that the layers argument is currently ignored, so you should just pass Nothing.

Since: 1.18

editFull

timelineElementEditFull Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: The TimelineElement to edit

-> Int64

newLayerPriority: The priority/index of the layer self should be moved to. -1 means no move

-> EditMode

mode: The edit mode

-> Edge

edge: The edge of self where the edit should occur

-> Word64

position: The edit position: a new location for the edge of self (in nanoseconds) in the timeline coordinates

-> m ()

(Can throw GError)

Edits the element within its timeline by adjusting its TimelineElement:start, TimelineElement:duration or TimelineElement:inPoint, and potentially doing the same for other elements in the timeline. See EditMode for details about each edit mode. An edit may fail if it would place one of these properties out of bounds, or if it would place the timeline in an unsupported configuration.

Note that if you act on a TrackElement, this will edit its parent Clip instead. Moreover, for any TimelineElement, if you select GES_EDGE_NONE for GES_EDIT_MODE_NORMAL or GES_EDIT_MODE_RIPPLE, this will edit the toplevel instead, but still in such a way as to make the TimelineElement:start of self reach the edit position.

Note that if the element's timeline has a Timeline:snappingDistance set, then the edit position may be snapped to the edge of some element under the edited element.

newLayerPriority can be used to switch self, and other elements moved by the edit, to a new layer. New layers may be be created if the the corresponding layer priority/index does not yet exist for the timeline.

Since: 1.18

getChildProperty

timelineElementGetChildProperty Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> Text

propertyName: The name of the child property to get

-> m (Bool, GValue)

Returns: True if the property was found and copied to value.

Gets the property of a child of the element.

propertyName can either be in the format "prop-name" or "TypeNamepropName", where "prop-name" is the name of the property to get (as used in g_object_get()), and "TypeName" is the type name of the child (as returned by G_OBJECT_TYPE_NAME()). The latter format is useful when two children of different types share the same property name.

The first child found with the given "prop-name" property that was registered with timelineElementAddChildProperty (and of the type "TypeName", if it was given) will have the corresponding property copied into value.

Note that ges_timeline_element_get_child_properties() may be more convenient for C programming.

getChildPropertyByPspec

timelineElementGetChildPropertyByPspec Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> GParamSpec

pspec: The specification of a registered child property to get

-> m GValue 

Gets the property of a child of the element. Specifically, the property corresponding to the pspec used in timelineElementAddChildProperty is copied into value.

getDuration

timelineElementGetDuration Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> m Word64

Returns: The duration of self (in nanoseconds).

Gets the TimelineElement:duration for the element.

getInpoint

timelineElementGetInpoint Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> m Word64

Returns: The in-point of self (in nanoseconds).

Gets the TimelineElement:inPoint for the element.

getLayerPriority

timelineElementGetLayerPriority Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> m Word32

Returns: The priority of the layer self is in, or TIMELINE_ELEMENT_NO_LAYER_PRIORITY if self does not exist in a layer.

Gets the priority of the layer the element is in. A Group may span several layers, so this would return the highest priority (numerically, the smallest) amongst them.

Since: 1.16

getMaxDuration

timelineElementGetMaxDuration Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> m Word64

Returns: The max-duration of self (in nanoseconds).

Gets the TimelineElement:maxDuration for the element.

getName

timelineElementGetName Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> m (Maybe Text)

Returns: The name of self.

Gets the TimelineElement:name for the element.

getNaturalFramerate

timelineElementGetNaturalFramerate Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: The TimelineElement to get "natural" framerate from

-> m (Bool, Int32, Int32)

Returns: Whether self has a natural framerate or not, framerateN and framerateD will be set to, respectively, 0 and -1 if it is not the case.

Get the "natural" framerate of self. This is to say, for example for a VideoUriSource the framerate of the source.

Note that a AudioSource may also have a natural framerate if it derives from the same SourceClip asset as a VideoSource, and its value will be that of the video source. For example, if the uri of a UriClip points to a file that contains both a video and audio stream, then the corresponding AudioUriSource will share the natural framerate of the corresponding VideoUriSource.

Since: 1.18

getParent

timelineElementGetParent Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> m (Maybe TimelineElement)

Returns: The parent of self, or Nothing if self has no parent.

Gets the TimelineElement:parent for the element.

getPriority

timelineElementGetPriority Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> m Word32

Returns: The priority of self.

Gets the TimelineElement:priority for the element.

getStart

timelineElementGetStart Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> m Word64

Returns: The start of self (in nanoseconds).

Gets the TimelineElement:start for the element.

getTimeline

timelineElementGetTimeline Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> m (Maybe Timeline)

Returns: The timeline of self, or Nothing if self has no timeline.

Gets the TimelineElement:timeline for the element.

getToplevelParent

timelineElementGetToplevelParent Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: The TimelineElement to get the toplevel parent from

-> m TimelineElement

Returns: The toplevel parent of self.

Gets the toplevel TimelineElement:parent of the element.

getTrackTypes

timelineElementGetTrackTypes Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> m [TrackType]

Returns: The track types that self supports.

Gets the track types that the element can interact with, i.e. the type of Track it can exist in, or will create TrackElement-s for.

Since: 1.6.0

lookupChild

timelineElementLookupChild Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> Text

propName: The name of a child property

-> m (Bool, Object, GParamSpec)

Returns: True if a child corresponding to the property was found, in which case child and pspec are set.

Looks up a child property of the element.

propName can either be in the format "prop-name" or "TypeNamepropName", where "prop-name" is the name of the property to look up (as used in g_object_get()), and "TypeName" is the type name of the child (as returned by G_OBJECT_TYPE_NAME()). The latter format is useful when two children of different types share the same property name.

The first child found with the given "prop-name" property that was registered with timelineElementAddChildProperty (and of the type "TypeName", if it was given) will be passed to child, and the registered specification of this property will be passed to pspec.

paste

timelineElementPaste Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: The TimelineElement to paste

-> Word64

pastePosition: The position in the timeline element should be pasted to, i.e. the TimelineElement:start value for the pasted element.

-> m (Maybe TimelineElement)

Returns: The newly created element, or Nothing if pasting fails.

Paste an element inside the same timeline and layer as self. self **must** be the return of timelineElementCopy with deep=TRUE, and it should not be changed before pasting. self is not placed in the timeline, instead a new element is created, alike to the originally copied element. Note that the originally copied element must stay within the same timeline and layer, at both the point of copying and pasting.

Pasting may fail if it would place the timeline in an unsupported configuration.

After calling this function element should not be used. In particular, element can **not** be pasted again. Instead, you can copy the returned element and paste that copy (although, this is only possible if the paste was successful).

See also timelinePasteElement.

Since: 1.6.0

removeChildProperty

timelineElementRemoveChildProperty Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> GParamSpec

pspec: The specification for the property to remove

-> m Bool

Returns: True if the property was successfully un-registered for self.

Remove a child property from the element. pspec should be a specification that was passed to timelineElementAddChildProperty. The corresponding property will no longer be registered as a child property for the element.

ripple

timelineElementRipple Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: The TimelineElement to ripple

-> Word64

start: The new start time of self in ripple mode

-> m Bool

Returns: True if the ripple edit of self completed, False on failure.

Edits the start time of an element within its timeline in ripple mode. See timelineElementEdit with GES_EDIT_MODE_RIPPLE and GES_EDGE_NONE.

rippleEnd

timelineElementRippleEnd Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: The TimelineElement to ripple

-> Word64

end: The new end time of self in ripple mode

-> m Bool

Returns: True if the ripple edit of self completed, False on failure.

Edits the end time of an element within its timeline in ripple mode. See timelineElementEdit with GES_EDIT_MODE_RIPPLE and GES_EDGE_END.

rollEnd

timelineElementRollEnd Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: The TimelineElement to roll

-> Word64

end: The new end time of self in roll mode

-> m Bool

Returns: True if the roll edit of self completed, False on failure.

Edits the end time of an element within its timeline in roll mode. See timelineElementEdit with GES_EDIT_MODE_ROLL and GES_EDGE_END.

rollStart

timelineElementRollStart Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: The TimelineElement to roll

-> Word64

start: The new start time of self in roll mode

-> m Bool

Returns: True if the roll edit of self completed, False on failure.

Edits the start time of an element within its timeline in roll mode. See timelineElementEdit with GES_EDIT_MODE_ROLL and GES_EDGE_START.

setChildProperty

timelineElementSetChildProperty Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> Text

propertyName: The name of the child property to set

-> GValue

value: The value to set the property to

-> m Bool

Returns: True if the property was found and set.

See timelineElementSetChildPropertyFull, which also gives an error.

Note that ges_timeline_element_set_child_properties() may be more convenient for C programming.

setChildPropertyByPspec

timelineElementSetChildPropertyByPspec Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> GParamSpec

pspec: The specification of a registered child property to set

-> GValue

value: The value to set the property to

-> m () 

Sets the property of a child of the element. Specifically, the property corresponding to the pspec used in timelineElementAddChildProperty is set to value.

setChildPropertyFull

timelineElementSetChildPropertyFull Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> Text

propertyName: The name of the child property to set

-> GValue

value: The value to set the property to

-> m ()

(Can throw GError)

Sets the property of a child of the element.

propertyName can either be in the format "prop-name" or "TypeNamepropName", where "prop-name" is the name of the property to set (as used in g_object_set()), and "TypeName" is the type name of the child (as returned by G_OBJECT_TYPE_NAME()). The latter format is useful when two children of different types share the same property name.

The first child found with the given "prop-name" property that was registered with timelineElementAddChildProperty (and of the type "TypeName", if it was given) will have the corresponding property set to value. Other children that may have also matched the property name (and type name) are left unchanged!

Since: 1.18

setDuration

timelineElementSetDuration Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> Word64

duration: The desired duration in its timeline

-> m Bool

Returns: True if duration could be set for self.

Sets TimelineElement:duration for the element.

Whilst the element is part of a Timeline, this is the same as editing the element with timelineElementEdit under GES_EDIT_MODE_TRIM with GES_EDGE_END. In particular, the TimelineElement:duration of the element may be snapped to a different timeline time difference from the one given. In addition, setting may fail if it would place the timeline in an unsupported configuration, or the element does not have enough internal content to last the desired duration.

setInpoint

timelineElementSetInpoint Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> Word64

inpoint: The in-point, in internal time coordinates

-> m Bool

Returns: True if inpoint could be set for self.

Sets TimelineElement:inPoint for the element. If the new in-point is above the current TimelineElement:maxDuration of the element, this method will fail.

setMaxDuration

timelineElementSetMaxDuration Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> Word64

maxduration: The maximum duration, in internal time coordinates

-> m Bool

Returns: True if maxduration could be set for self.

Sets TimelineElement:maxDuration for the element. If the new maximum duration is below the current TimelineElement:inPoint of the element, this method will fail.

setName

timelineElementSetName Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> Maybe Text

name: The name self should take

-> m Bool

Returns: True if name or a generated name for self could be set.

Sets the TimelineElement:name for the element. If Nothing is given for name, then the library will instead generate a new name based on the type name of the element, such as the name "uriclip3" for a UriClip, and will set that name instead.

If self already has a TimelineElement:timeline, you should not call this function with name set to Nothing.

You should ensure that, within each Timeline, every element has a unique name. If you call this function with name as Nothing, then the library should ensure that the set generated name is unique from previously **generated** names. However, if you choose a name that interferes with the naming conventions of the library, the library will attempt to ensure that the generated names will not conflict with the chosen name, which may lead to a different name being set instead, but the uniqueness between generated and user-chosen names is not guaranteed.

setParent

timelineElementSetParent Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a, IsTimelineElement b) 
=> a

self: A TimelineElement parent (nullable): New parent of self

-> b 
-> m Bool

Returns: True if parent could be set for self.

Sets the TimelineElement:parent for the element.

This is used internally and you should normally not call this. A Container will set the TimelineElement:parent of its children in containerAdd and containerRemove.

Note, if parent is not Nothing, self must not already have a parent set. Therefore, if you wish to switch parents, you will need to call this function twice: first to set the parent to Nothing, and then to the new parent.

If parent is not Nothing, you must ensure it already has a (non-floating) reference to self before calling this.

setPriority

timelineElementSetPriority Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> Word32

priority: The priority

-> m Bool

Returns: True if priority could be set for self.

Deprecated: (Since version 1.10)All priority management is done by GES itself now.To set Effect priorities ges_clip_set_top_effect_index shouldbe used.

Sets the priority of the element within the containing layer.

setStart

timelineElementSetStart Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: A TimelineElement

-> Word64

start: The desired start position of the element in its timeline

-> m Bool

Returns: True if start could be set for self.

Sets TimelineElement:start for the element. If the element has a parent, this will also move its siblings with the same shift.

Whilst the element is part of a Timeline, this is the same as editing the element with timelineElementEdit under GES_EDIT_MODE_NORMAL with GES_EDGE_NONE. In particular, the TimelineElement:start of the element may be snapped to a different timeline time from the one given. In addition, setting may fail if it would place the timeline in an unsupported configuration.

setTimeline

timelineElementSetTimeline Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a, IsTimeline b) 
=> a

self: A TimelineElement timeline (nullable): The Timeline self should be in

-> b 
-> m Bool

Returns: True if timeline could be set for self.

Sets the TimelineElement:timeline of the element.

This is used internally and you should normally not call this. A Clip will have its TimelineElement:timeline set through its Layer. A Track will similarly take care of setting the TimelineElement:timeline of its TrackElement-s. A Group will adopt the same TimelineElement:timeline as its children.

If timeline is Nothing, this will stop its current TimelineElement:timeline from tracking it, otherwise timeline will start tracking self. Note, in the latter case, self must not already have a timeline set. Therefore, if you wish to switch timelines, you will need to call this function twice: first to set the timeline to Nothing, and then to the new timeline.

trim

timelineElementTrim Source #

Arguments

:: (HasCallStack, MonadIO m, IsTimelineElement a) 
=> a

self: The TimelineElement to trim

-> Word64

start: The new start time of self in trim mode

-> m Bool

Returns: True if the trim edit of self completed, False on failure.

Edits the start time of an element within its timeline in trim mode. See timelineElementEdit with GES_EDIT_MODE_TRIM and GES_EDGE_START.

Properties

duration

The duration that the element is in effect for in the timeline (a time difference in nanoseconds using the time coordinates of the timeline). For example, for a source element, this would determine for how long it should output its internal content for. For an operation element, this would determine for how long its effect should be applied to any source content.

constructTimelineElementDuration :: (IsTimelineElement o, MonadIO m) => Word64 -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “duration” property. This is rarely needed directly, but it is used by new.

getTimelineElementDuration :: (MonadIO m, IsTimelineElement o) => o -> m Word64 Source #

Get the value of the “duration” property. When overloading is enabled, this is equivalent to

get timelineElement #duration

setTimelineElementDuration :: (MonadIO m, IsTimelineElement o) => o -> Word64 -> m () Source #

Set the value of the “duration” property. When overloading is enabled, this is equivalent to

set timelineElement [ #duration := value ]

inPoint

The initial offset to use internally when outputting content (in nanoseconds, but in the time coordinates of the internal content).

For example, for a VideoUriSource that references some media file, the "internal content" is the media file data, and the in-point would correspond to some timestamp in the media file. When playing the timeline, and when the element is first reached at timeline-time TimelineElement:start, it will begin outputting the data from the timestamp in-point **onwards**, until it reaches the end of its TimelineElement:duration in the timeline.

For elements that have no internal content, this should be kept as 0.

constructTimelineElementInPoint :: (IsTimelineElement o, MonadIO m) => Word64 -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “in-point” property. This is rarely needed directly, but it is used by new.

getTimelineElementInPoint :: (MonadIO m, IsTimelineElement o) => o -> m Word64 Source #

Get the value of the “in-point” property. When overloading is enabled, this is equivalent to

get timelineElement #inPoint

setTimelineElementInPoint :: (MonadIO m, IsTimelineElement o) => o -> Word64 -> m () Source #

Set the value of the “in-point” property. When overloading is enabled, this is equivalent to

set timelineElement [ #inPoint := value ]

maxDuration

The full duration of internal content that is available (a time difference in nanoseconds using the time coordinates of the internal content).

This will act as a cap on the TimelineElement:inPoint of the element (which is in the same time coordinates), and will sometimes be used to limit the TimelineElement:duration of the element in the timeline.

For example, for a VideoUriSource that references some media file, this would be the length of the media file.

For elements that have no internal content, or whose content is indefinite, this should be kept as CLOCK_TIME_NONE.

constructTimelineElementMaxDuration :: (IsTimelineElement o, MonadIO m) => Word64 -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “max-duration” property. This is rarely needed directly, but it is used by new.

getTimelineElementMaxDuration :: (MonadIO m, IsTimelineElement o) => o -> m Word64 Source #

Get the value of the “max-duration” property. When overloading is enabled, this is equivalent to

get timelineElement #maxDuration

setTimelineElementMaxDuration :: (MonadIO m, IsTimelineElement o) => o -> Word64 -> m () Source #

Set the value of the “max-duration” property. When overloading is enabled, this is equivalent to

set timelineElement [ #maxDuration := value ]

name

The name of the element. This should be unique within its timeline.

clearTimelineElementName :: (MonadIO m, IsTimelineElement o) => o -> m () Source #

Set the value of the “name” property to Nothing. When overloading is enabled, this is equivalent to

clear #name

constructTimelineElementName :: (IsTimelineElement o, MonadIO m) => Text -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “name” property. This is rarely needed directly, but it is used by new.

getTimelineElementName :: (MonadIO m, IsTimelineElement o) => o -> m (Maybe Text) Source #

Get the value of the “name” property. When overloading is enabled, this is equivalent to

get timelineElement #name

setTimelineElementName :: (MonadIO m, IsTimelineElement o) => o -> Text -> m () Source #

Set the value of the “name” property. When overloading is enabled, this is equivalent to

set timelineElement [ #name := value ]

parent

The parent container of the element.

clearTimelineElementParent :: (MonadIO m, IsTimelineElement o) => o -> m () Source #

Set the value of the “parent” property to Nothing. When overloading is enabled, this is equivalent to

clear #parent

constructTimelineElementParent :: (IsTimelineElement o, MonadIO m, IsTimelineElement a) => a -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “parent” property. This is rarely needed directly, but it is used by new.

getTimelineElementParent :: (MonadIO m, IsTimelineElement o) => o -> m (Maybe TimelineElement) Source #

Get the value of the “parent” property. When overloading is enabled, this is equivalent to

get timelineElement #parent

setTimelineElementParent :: (MonadIO m, IsTimelineElement o, IsTimelineElement a) => o -> a -> m () Source #

Set the value of the “parent” property. When overloading is enabled, this is equivalent to

set timelineElement [ #parent := value ]

priority

The priority of the element.

constructTimelineElementPriority :: (IsTimelineElement o, MonadIO m) => Word32 -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “priority” property. This is rarely needed directly, but it is used by new.

getTimelineElementPriority :: (MonadIO m, IsTimelineElement o) => o -> m Word32 Source #

Get the value of the “priority” property. When overloading is enabled, this is equivalent to

get timelineElement #priority

setTimelineElementPriority :: (MonadIO m, IsTimelineElement o) => o -> Word32 -> m () Source #

Set the value of the “priority” property. When overloading is enabled, this is equivalent to

set timelineElement [ #priority := value ]

serialize

Whether the element should be serialized.

constructTimelineElementSerialize :: (IsTimelineElement o, MonadIO m) => Bool -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “serialize” property. This is rarely needed directly, but it is used by new.

getTimelineElementSerialize :: (MonadIO m, IsTimelineElement o) => o -> m Bool Source #

Get the value of the “serialize” property. When overloading is enabled, this is equivalent to

get timelineElement #serialize

setTimelineElementSerialize :: (MonadIO m, IsTimelineElement o) => o -> Bool -> m () Source #

Set the value of the “serialize” property. When overloading is enabled, this is equivalent to

set timelineElement [ #serialize := value ]

start

The starting position of the element in the timeline (in nanoseconds and in the time coordinates of the timeline). For example, for a source element, this would determine the time at which it should start outputting its internal content. For an operation element, this would determine the time at which it should start applying its effect to any source content.

constructTimelineElementStart :: (IsTimelineElement o, MonadIO m) => Word64 -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “start” property. This is rarely needed directly, but it is used by new.

getTimelineElementStart :: (MonadIO m, IsTimelineElement o) => o -> m Word64 Source #

Get the value of the “start” property. When overloading is enabled, this is equivalent to

get timelineElement #start

setTimelineElementStart :: (MonadIO m, IsTimelineElement o) => o -> Word64 -> m () Source #

Set the value of the “start” property. When overloading is enabled, this is equivalent to

set timelineElement [ #start := value ]

timeline

The timeline that the element lies within.

clearTimelineElementTimeline :: (MonadIO m, IsTimelineElement o) => o -> m () Source #

Set the value of the “timeline” property to Nothing. When overloading is enabled, this is equivalent to

clear #timeline

constructTimelineElementTimeline :: (IsTimelineElement o, MonadIO m, IsTimeline a) => a -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “timeline” property. This is rarely needed directly, but it is used by new.

getTimelineElementTimeline :: (MonadIO m, IsTimelineElement o) => o -> m (Maybe Timeline) Source #

Get the value of the “timeline” property. When overloading is enabled, this is equivalent to

get timelineElement #timeline

setTimelineElementTimeline :: (MonadIO m, IsTimelineElement o, IsTimeline a) => o -> a -> m () Source #

Set the value of the “timeline” property. When overloading is enabled, this is equivalent to

set timelineElement [ #timeline := value ]

Signals

childPropertyAdded

type TimelineElementChildPropertyAddedCallback Source #

Arguments

 = Object

propObject: The child whose property has been registered

-> GParamSpec

prop: The specification for the property that has been registered

-> IO () 

Emitted when the element has a new child property registered. See timelineElementAddChildProperty.

Note that some GES elements will be automatically created with pre-registered children properties. You can use timelineElementListChildrenProperties to list these.

Since: 1.18

afterTimelineElementChildPropertyAdded :: (IsTimelineElement a, MonadIO m) => a -> ((?self :: a) => TimelineElementChildPropertyAddedCallback) -> m SignalHandlerId Source #

Connect a signal handler for the childPropertyAdded signal, to be run after the default handler. When overloading is enabled, this is equivalent to

after timelineElement #childPropertyAdded callback

By default the object invoking the signal is not passed to the callback. If you need to access it, you can use the implit ?self parameter. Note that this requires activating the ImplicitParams GHC extension.

onTimelineElementChildPropertyAdded :: (IsTimelineElement a, MonadIO m) => a -> ((?self :: a) => TimelineElementChildPropertyAddedCallback) -> m SignalHandlerId Source #

Connect a signal handler for the childPropertyAdded signal, to be run before the default handler. When overloading is enabled, this is equivalent to

on timelineElement #childPropertyAdded callback

childPropertyRemoved

type TimelineElementChildPropertyRemovedCallback Source #

Arguments

 = Object

propObject: The child whose property has been unregistered

-> GParamSpec

prop: The specification for the property that has been unregistered

-> IO () 

Emitted when the element has a child property unregistered. See timelineElementRemoveChildProperty.

Since: 1.18

afterTimelineElementChildPropertyRemoved :: (IsTimelineElement a, MonadIO m) => a -> ((?self :: a) => TimelineElementChildPropertyRemovedCallback) -> m SignalHandlerId Source #

Connect a signal handler for the childPropertyRemoved signal, to be run after the default handler. When overloading is enabled, this is equivalent to

after timelineElement #childPropertyRemoved callback

By default the object invoking the signal is not passed to the callback. If you need to access it, you can use the implit ?self parameter. Note that this requires activating the ImplicitParams GHC extension.

onTimelineElementChildPropertyRemoved :: (IsTimelineElement a, MonadIO m) => a -> ((?self :: a) => TimelineElementChildPropertyRemovedCallback) -> m SignalHandlerId Source #

Connect a signal handler for the childPropertyRemoved signal, to be run before the default handler. When overloading is enabled, this is equivalent to

on timelineElement #childPropertyRemoved callback

deepNotify

type TimelineElementDeepNotifyCallback Source #

Arguments

 = Object

propObject: The child whose property has been set

-> GParamSpec

prop: The specification for the property that been set

-> IO () 

Emitted when a child of the element has one of its registered properties set. See timelineElementAddChildProperty. Note that unlike Object::notify, a child property name can not be used as a signal detail.

afterTimelineElementDeepNotify :: (IsTimelineElement a, MonadIO m) => a -> Maybe Text -> ((?self :: a) => TimelineElementDeepNotifyCallback) -> m SignalHandlerId Source #

Connect a signal handler for the deepNotify signal, to be run after the default handler. When overloading is enabled, this is equivalent to

after timelineElement #deepNotify callback

This signal admits a optional parameter detail. If it's not Nothing, we will connect to “deep-notify::detail” instead.

By default the object invoking the signal is not passed to the callback. If you need to access it, you can use the implit ?self parameter. Note that this requires activating the ImplicitParams GHC extension.

onTimelineElementDeepNotify :: (IsTimelineElement a, MonadIO m) => a -> Maybe Text -> ((?self :: a) => TimelineElementDeepNotifyCallback) -> m SignalHandlerId Source #

Connect a signal handler for the deepNotify signal, to be run before the default handler. When overloading is enabled, this is equivalent to

on timelineElement #deepNotify callback

This signal admits a optional parameter detail. If it's not Nothing, we will connect to “deep-notify::detail” instead.