From 4aaca2cc0242f5d20344d39418b02d9c0e446521 Mon Sep 17 00:00:00 2001 From: Thibault Saunier Date: Mon, 8 Jan 2024 11:26:10 -0300 Subject: [PATCH] ges: launch: Print the timeline after we set its state to READY Part-of: --- subprojects/gst-editing-services/tools/ges-launcher.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/subprojects/gst-editing-services/tools/ges-launcher.c b/subprojects/gst-editing-services/tools/ges-launcher.c index 6659f110d5..fba897849c 100644 --- a/subprojects/gst-editing-services/tools/ges-launcher.c +++ b/subprojects/gst-editing-services/tools/ges-launcher.c @@ -899,16 +899,25 @@ _project_loaded_cb (GESProject * project, GESTimeline * timeline, g_error ("Failed to setup rendering details\n"); } - print_timeline (self->priv->timeline); g_free (project_uri); if (!self->priv->seenerrors && opts->needs_set_state) { ges_timeline_commit (self->priv->timeline); + if (gst_element_set_state (GST_ELEMENT (self->priv->pipeline), + GST_STATE_READY) == GST_STATE_CHANGE_FAILURE) { + g_error ("Failed to start the pipeline\n"); + } + + /* Printing the pipeline only in READY state as there might be elements + * tweaking it in while going to READY */ + print_timeline (self->priv->timeline); if (gst_element_set_state (GST_ELEMENT (self->priv->pipeline), GST_STATE_PLAYING) == GST_STATE_CHANGE_FAILURE) { g_error ("Failed to start the pipeline\n"); } + } else { + print_timeline (self->priv->timeline); } }