X-Git-Url: http://code.vuplus.com/gitweb/?p=vuplus_dvbapp;a=blobdiff_plain;f=lib%2Fservice%2Fservicemp3.cpp;h=bb75a063f13911f5c29d215b646cd97baa512730;hp=6aed8655896ad62687de7da0782515b3c32bcf5a;hb=4a5f4afeff93bb2c577c135835853ebaf2c7868b;hpb=d46cbdadbe961cd1100040d67ebe54b89679ca95 diff --git a/lib/service/servicemp3.cpp b/lib/service/servicemp3.cpp index 6aed865..bb75a06 100755 --- a/lib/service/servicemp3.cpp +++ b/lib/service/servicemp3.cpp @@ -330,7 +330,8 @@ eServiceMP3::eServiceMP3(eServiceReference ref) uri = g_filename_to_uri(filename, NULL, NULL); - eDebug("eServiceMP3::playbin2 uri=%s", uri); + //eDebug("eServiceMP3::playbin2 uri=%s", uri); + eDebug("eServiceMP3::playbin2"); m_gst_playbin = gst_element_factory_make("playbin2", "playbin"); if (!m_gst_playbin) @@ -453,7 +454,8 @@ RESULT eServiceMP3::stop() //GST_DEBUG_BIN_TO_DOT_FILE(GST_BIN(m_gst_playbin),GST_DEBUG_GRAPH_SHOW_ALL,"e2-playbin"); - eDebug("eServiceMP3::stop %s", m_ref.path.c_str()); + //eDebug("eServiceMP3::stop %s", m_ref.path.c_str()); + eDebug("eServiceMP3::stop service.."); gst_element_set_state(m_gst_playbin, GST_STATE_NULL); m_state = stStopped; @@ -1411,18 +1413,21 @@ void eServiceMP3::gstBusCall(GstBus *bus, GstMessage *msg) { if ( gst_is_missing_plugin_message(msg) ) { - GstCaps *caps; - gst_structure_get (msgstruct, "detail", GST_TYPE_CAPS, &caps, NULL); - std::string codec = (const char*) gst_caps_to_string(caps); - gchar *description = gst_missing_plugin_message_get_description(msg); - if ( description ) + GstCaps *caps= NULL; + gboolean ret = gst_structure_get (msgstruct, "detail", GST_TYPE_CAPS, &caps, NULL); + if (ret) { - eDebug("eServiceMP3::m_errorInfo.missing_codec = %s", codec.c_str()); - m_errorInfo.error_message = "GStreamer plugin " + (std::string)description + " not available!\n"; - m_errorInfo.missing_codec = codec.substr(0,(codec.find_first_of(','))); - g_free(description); + std::string codec = (const char*) gst_caps_to_string(caps); + gchar *description = gst_missing_plugin_message_get_description(msg); + if ( description ) + { + eDebug("eServiceMP3::m_errorInfo.missing_codec = %s", codec.c_str()); + m_errorInfo.error_message = "GStreamer plugin " + (std::string)description + " not available!\n"; + m_errorInfo.missing_codec = codec.substr(0,(codec.find_first_of(','))); + g_free(description); + } + gst_caps_unref(caps); } - gst_caps_unref(caps); } else {