pipeline: Handle the case were we are still loading the project and the user tries to set its state to PLAYING/PAUSED.
Submitted by Kyrylo V. Polezhaiev
Link to original bug (#743938)
Description
I want to use GESProject and GESPipeline to render .xges file into the .webm one. My code looks like this:
...
project = ges_project_new(uri); /// URI of XGES file
GESTimeline *timeline =
GES_TIMELINE(ges_asset_extract(GES_ASSET(project), &error));
if (error)
...
/// I handle error here
...
else
{
pipeline = ges_pipeline_new();
ges_pipeline_set_timeline(pipeline, timeline);
gchar *uri = g_strdup_printf("file://" RAMFS_PATH "t%"
G_GUINT64_FORMAT ".webm", operation_identifier); /// Yet another URI: .webm
file where output should be directed
ges_pipeline_set_render_settings(pipeline, uri,
GST_ENCODING_PROFILE(encoding_profile)); /// WebM with vp8 and Vorbis
g_free(uri);
ges_pipeline_set_mode(pipeline, GES_PIPELINE_MODE_RENDER);
...
/// Here I attach some stuff to bus to handle errors, eos, etc.
...
gst_element_set_state(GST_ELEMENT(pipeline), GST_STATE_PLAYING);
...
I face a problem causing pipeline to work infinte time without sending error or EOS messages to bus. It happens first time I run pipeline. Second (and subsequent) pipelines seem to work without this error (or at least it becames rare). With gst-editing-services from git master error looks like this:
ERROR nlecomposition nle/nlecomposition.c:2524:_relink_children_recursively: Not enough sinkpads to link all objects to the operation ! 1 / 0
ERROR nlecomposition nle/nlecomposition.c:2527:_relink_children_recursively: Operation has no child objects to be connected to !!!
In GES 1.4.0 error looks a bit different:
ERROR gnlcomposition gnlcomposition.c:2385:compare_relink_single_node: Not enough sinkpads to link all objects to the operation ! 2 / 0
ERROR gnlcomposition gnlcomposition.c:2387:compare_relink_single_node: Operation has no child objects to be connected to !!!