issue in setting pipeline again in PLAYING state once it got EOS

rajnikant jachak rajnikantjachak at gmail.com
Tue Jan 8 07:08:24 PST 2013


Hi All,

I wanted to play video files one after other using playbin2 gstreamer
element. So, in pipeline message handler, on receiving EOS, I'm resetting
values for uri and suburi properties of playbin2 element and setting state
to PLAYING again. But my binary is getting stuck and no video output is
getting displayed on TV screen.

1. What state pipeline would be when it gets EOS? Is it NULL or PLAYING?
2. Do one need to flush pipeline if pipeline has to reset for next playback?

I'm using gstreamer-0.10.30 version. Following is the code snippet:

/* Message Handler funct */
static gboolean handle_message (GstBus *bus, GstMessage *msg, CustomData
*data) {
  GError *err;
  gchar *debug_info;
  gint flags;

  switch (GST_MESSAGE_TYPE (msg)) {
    case GST_MESSAGE_ERROR:
       . . .
       . . .
       . . .
      break;
    case GST_MESSAGE_EOS:
      g_print ("End-Of-Stream reached. Playin same clip again\n");
      g_object_set (data->playbin2, "uri", "file:///home/root/BBBs.ogv",
NULL);

      /* Set the subtitle URI to play and some font description */
      g_object_set (data->playbin2, "suburi",
"file:///home/root/subtitle.srt", NULL);

      gst_element_set_state (data->playbin2, GST_STATE_READY);
      gst_element_set_state (data->playbin2, GST_STATE_PLAYING);
      break;
    case default:
      . . .
      . . .
}

Thanks,
Rajnikant
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20130108/300ce244/attachment.html>


More information about the gstreamer-devel mailing list