GES Timeline
Eloi Bail
eloi.bail at gmail.com
Thu Mar 28 14:41:32 PDT 2013
Hi all,
I was using GESTimeline to play continuously a media split in several files.
It was working fine so far ( I can chain my split media files and playback
them).
However, I need more feature and am struggling to know how to use classes
such as Asset, Clip, Track, TrackElement, Layout...etc
I would like to manage my playback in this way :
- manage multi-audio tracks. For the moment I am able to discover multi
audio tracks using GstDiscoverer but I do not know how to set / change an
audio track to my timelinepipeline
- manage audio and/or video tracks duration. For the moment I am setting a
global duration by media.
sometimes have - audio track from file 1 = 1:59:50
- video track from file 1 = 2:00:00
- audio track from file 2 = 2:00:10
- video track from file 1 = 2:00:00
I would like to have no gab on audio playing. So I would need
to deal with duration per track
I have several solution: Track, Clip, Asset and do not know what is the
best for my purpose (BTW I am using Gstreamer SDK 2012.11-1)
Could you please give me some advice ?
Thanks,
Eloi
Here is an extract of my code :
/* This is our main GESTimeline */
>
> data->timeline = ges_timeline_new ();
> data->tracka = ges_track_audio_raw_new ();
> data->trackv = ges_track_video_raw_new ();
> data->layer = (GESTimelineLayer *) ges_simple_timeline_layer_new ();
> g_object_set (data->layer, "priority", 0, NULL);
> ges_timeline_layer_set_auto_transition (data->layer, TRUE);
> data->sinkVideo =
> gst_parse_bin_from_description ("timeoverlay ! ximagesink
> name=directdrawsink-output", TRUE, NULL);
> /* In order to listen our timeline, let's grab a convenience pipeline to
> put
> * our timeline in. */
> data->pipeline = ges_timeline_pipeline_new ();
> /* Add the timeline to that pipeline */
> if (!ges_timeline_add_layer (data->timeline, data->layer) ||
> !ges_timeline_add_track (data->timeline, data->tracka) ||
> !ges_timeline_add_track (data->timeline, data->trackv) ||
> !ges_timeline_pipeline_add_timeline (data->pipeline, data->timeline))
> return 1;
> ges_timeline_pipeline_preview_set_video_sink (data->pipeline,
> data->sinkVideo);
> ges_timeline_pipeline_preview_set_audio_sink (data->pipeline,
> data->sinkAudio);
>
>
> -----
> newuri =
> g_strdup_printf ("file://%s",
> "/home/eloi/avi/file1.avi");
> GESTimelineFileSource *src2 = ges_timeline_filesource_new (newuri);
> g_assert (src2);
> g_free (newuri);
> g_object_set (src2, "start", data->cycle * data->CLIP_DURATION,
> "duration",
> data->CLIP_DURATION, NULL);
> ges_timeline_layer_add_object (data->layer, (GESTimelineObject *)
> src2);
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20130328/3be5958c/attachment-0001.html>
More information about the gstreamer-devel
mailing list