pub trait ClipAssetExt:
    IsA<ClipAsset>
    + Sealed
    + 'static {
    // Provided methods
    fn frame_time(&self, frame_number: FrameNumber) -> Option<ClockTime> { ... }
    fn natural_framerate(&self) -> Option<(i32, i32)> { ... }
    fn supported_formats(&self) -> TrackType { ... }
    fn set_supported_formats(&self, supportedformats: TrackType) { ... }
    fn connect_supported_formats_notify<F: Fn(&Self) + Send + Sync + 'static>(
        &self,
        f: F,
    ) -> SignalHandlerId { ... }
}
Expand description

Trait containing all ClipAsset methods.

§Implementors

ClipAsset, SourceClipAsset

Provided Methods§

source

fn frame_time(&self, frame_number: FrameNumber) -> Option<ClockTime>

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 Clip.

§frame_number

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.

source

fn natural_framerate(&self) -> Option<(i32, i32)>

Result: true if self has a natural framerate false otherwise

§Returns
§framerate_n

The framerate numerator

§framerate_d

The framerate denominator

source

fn supported_formats(&self) -> TrackType

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

§Returns

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

source

fn set_supported_formats(&self, supportedformats: TrackType)

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

§supportedformats

The track types supported by the GESClipAsset

source

fn connect_supported_formats_notify<F: Fn(&Self) + Send + Sync + 'static>( &self, f: F, ) -> SignalHandlerId

Object Safety§

This trait is not object safe.

Implementors§