Track


Description:

[ CCode ( has_construct_function = false ) ]
public Track (TrackType type, owned Caps caps)

Creates a new track with the given track-type and caps.

If type is VIDEO, and caps is a subset of "video/x-raw(ANY)", then a VideoTrack is created. This will automatically choose a gap creation method suitable for video data. You will likely want to set restriction_caps separately. You may prefer to use the VideoTrack method instead.

If type is AUDIO, and caps is a subset of "audio/x-raw(ANY)", then a AudioTrack is created. This will automatically choose a gap creation method suitable for audio data, and will set the restriction_caps to the default for AudioTrack. You may prefer to use the AudioTrack method instead.

Otherwise, a plain Track is returned. You will likely want to set the restriction_caps and call ges_track_set_create_element_for_gap_func on the returned track.

Parameters:

type

The track_type for the track

caps

The caps for the track

Returns:

A new track.