{
/* first filter out the interesting element factories */
decode_bin->factories_lock = g_mutex_new ();
- gst_decode_bin_update_factories_list (decode_bin);
/* we create the typefind element only once */
decode_bin->typefind = gst_element_factory_make ("typefind", "typefind");
case GST_STATE_CHANGE_NULL_TO_READY:
if (dbin->typefind == NULL)
goto missing_typefind;
- g_mutex_lock (dbin->factories_lock);
- gst_decode_bin_update_factories_list (dbin);
- g_mutex_unlock (dbin->factories_lock);
break;
case GST_STATE_CHANGE_READY_TO_PAUSED:
/* Make sure we've cleared all existing chains */
/* first filter out the interesting element factories */
playbin->elements_lock = g_mutex_new ();
- gst_play_bin_update_elements_list (playbin);
- GST_FACTORY_LIST_DEBUG (playbin->elements);
/* add sink */
playbin->playsink = g_object_new (GST_TYPE_PLAY_SINK, NULL);
if (playbin->text_sink)
gst_object_unref (playbin->text_sink);
- g_value_array_free (playbin->elements);
+ if (playbin->elements)
+ g_value_array_free (playbin->elements);
g_mutex_free (playbin->lock);
g_mutex_free (playbin->dyn_lock);
g_mutex_free (playbin->elements_lock);
switch (transition) {
case GST_STATE_CHANGE_NULL_TO_READY:
- g_mutex_lock (playbin->elements_lock);
- gst_play_bin_update_elements_list (playbin);
- g_mutex_unlock (playbin->elements_lock);
memset (&playbin->duration, 0, sizeof (playbin->duration));
break;
case GST_STATE_CHANGE_READY_TO_PAUSED:
{
/* first filter out the interesting element factories */
dec->factories_lock = g_mutex_new ();
- gst_uri_decode_bin_update_factories_list (dec);
dec->lock = g_mutex_new ();
decoder = GST_URI_DECODE_BIN (element);
switch (transition) {
- case GST_STATE_CHANGE_NULL_TO_READY:
- g_mutex_lock (decoder->factories_lock);
- gst_uri_decode_bin_update_factories_list (decoder);
- g_mutex_unlock (decoder->factories_lock);
- break;
case GST_STATE_CHANGE_READY_TO_PAUSED:
if (!setup_source (decoder))
goto source_failed;