GES.ClipAsset

g GES.Asset GES.Asset GES.ClipAsset GES.ClipAsset GES.Asset->GES.ClipAsset GES.MetaContainer GES.MetaContainer GES.MetaContainer->GES.Asset GObject.GInterface GObject.GInterface GObject.GInterface->GES.MetaContainer Gio.AsyncInitable Gio.AsyncInitable GObject.GInterface->Gio.AsyncInitable Gio.Initable Gio.Initable GObject.GInterface->Gio.Initable GObject.Object GObject.Object GObject.Object->GES.Asset Gio.AsyncInitable->GES.Asset Gio.Initable->GES.Asset

Subclasses:

GES.SourceClipAsset

Methods

Inherited:

GES.Asset (13), GObject.Object (37), GES.MetaContainer (40), Gio.AsyncInitable (4), Gio.Initable (2)

Structs:

GObject.ObjectClass (5)

get_frame_time (frame_number)

get_natural_framerate ()

get_supported_formats ()

set_supported_formats (supportedformats)

Virtual Methods

Inherited:

GES.Asset (5), GObject.Object (7), Gio.AsyncInitable (2), Gio.Initable (1)

do_get_natural_framerate ()

Properties

Inherited:

GES.Asset (4)

Name

Type

Flags

Short Description

supported-formats

GES.TrackType

r/w/c

Formats supported by the file

Signals

Inherited:

GObject.Object (1), GES.MetaContainer (1)

Fields

Inherited:

GObject.Object (1), GES.MetaContainer (1)

Name

Type

Access

Description

parent

GES.Asset

r

Class Details

class GES.ClipAsset(**kwargs)
Bases:

GES.Asset

Abstract:

No

Structure:

GES.ClipAssetClass

The GES.UriClipAsset is a special GES.Asset specilized in GES.Clip. it is mostly used to get information about the GES.TrackType-s the objects extracted from it can potentialy create GES.TrackElement for.

get_frame_time(frame_number)[source]
Parameters:

frame_number (int) – The frame number we want the internal time coordinate timestamp of

Returns:

The timestamp corresponding to frame_number in the element source, given in internal time coordinates, or Gst.CLOCK_TIME_NONE if the clip asset does not have a natural frame rate.

Return type:

int

Converts the given frame number into a timestamp, using the “natural” frame rate of the asset.

You can use this to reference a specific frame in a media file and use this as, for example, the in-point or max-duration of a GES.Clip.

New in version 1.18.

get_natural_framerate()[source]
Returns:

framerate_n:

The framerate numerator

framerate_d:

The framerate denominator

Return type:

(bool, framerate_n: int, framerate_d: int)

Result: True if self has a natural framerate False otherwise

New in version 1.18.

get_supported_formats()[source]
Returns:

The track types on which self will create TrackElement when added to a layer

Return type:

GES.TrackType

Gets track types for which objects extracted from self can create GES.TrackElement

set_supported_formats(supportedformats)[source]
Parameters:

supportedformats (GES.TrackType) – The track types supported by the GES.ClipAsset

Sets track types for which objects extracted from self can create GES.TrackElement

do_get_natural_framerate() virtual
Returns:

True if self has a natural framerate False otherwise.

framerate_n:

The framerate numerator

framerate_d:

The framerate denominator

Return type:

(bool, framerate_n: int, framerate_d: int)

Result: True if self has a natural framerate False otherwise

New in version 1.18.

Property Details

GES.ClipAsset.props.supported_formats
Name:

supported-formats

Type:

GES.TrackType

Default Value:

GES.TrackType.AUDIO | GES.TrackType.VIDEO

Flags:

READABLE, WRITABLE, CONSTRUCT

The formats supported by the asset.