palybin http sources

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

palybin http sources

Ash-25
using playbin with fakesinks, i cant seem to get to the PAUSED state with http sources but it works with file sources...any idea why?

Time for vacation? WIN what you need. Enter Now!
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: palybin http sources

Benoit Fouet
Hi,

Ash wrote:
> using playbin with fakesinks, i cant seem to get to the PAUSED state
> with http sources but it works with file sources...any idea why?

could you elaborate ?
what is your command line ? what is the code snippet you're using ?
you really have to help us help you

--
Benoit Fouet
Purple Labs S.A.
www.purplelabs.com

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: palybin http sources

Ash-25
here is my code:
 
    GstElement *pipeline = gst_pipeline_new("gst-test");
    GstElement *bin = gst_element_factory_make("playbin", "bin");
    GstElement *videosink = gst_element_factory_make("fakesink", "videosink");
    GstElement *audiosink = gst_element_factory_make("fakesink", "audiosink");
    if(!pipeline || !bin || !videosink || !audiosink)
        return false;
    g_object_set(G_OBJECT(bin), "video-sink", videosink, NULL);
    g_object_set(G_OBJECT(bin), "audio-sink", audiosink, NULL);
    if(!gst_bin_add(GST_BIN(pipeline), bin))
        return false;
    g_object_set(G_OBJECT(bin), "uri", buf, NULL);
    GstBus *bus;
    bus = gst_pipeline_get_bus(GST_PIPELINE(pipeline));
    gst_bus_add_signal_watch(bus);
    gst_bus_add_watch(bus, bus_test, NULL);
    gst_object_unref(bus);
    gst_element_set_state(pipeline, GST_STATE_PAUSED);
    g_loop = g_main_loop_new(NULL, FALSE);
    g_main_loop_run(g_loop);

In my bus_test handler, I checked for STATE CHANGED messages. For File sources, usually after about 4 STATE CHANGED messages, the state is changed from READY TO PAUSED. However with HTTP sources, the source never changes from READY.
 

> Date: Tue, 22 Jul 2008 12:00:45 +0200
> From: [hidden email]
> To: [hidden email]
> CC: [hidden email]
> Subject: Re: [gst-devel] palybin http sources
>
> Hi,
>
> Ash wrote:
> > using playbin with fakesinks, i cant seem to get to the PAUSED state
> > with http sources but it works with file sources...any idea why?
>
> could you elaborate ?
> what is your command line ? what is the code snippet you're using ?
> you really have to help us help you
>
> --
> Benoit Fouet
> Purple Labs S.A.
> www.purplelabs.com



Time for vacation? WIN what you need. Enter Now!
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: palybin http sources

Tim-Philipp Müller-2
On Tue, 2008-07-22 at 17:43 +0000, Ash wrote:

>     gst_element_set_state(pipeline, GST_STATE_PAUSED);
>     g_loop = g_main_loop_new(NULL, FALSE);
>     g_main_loop_run(g_loop);
>
> In my bus_test handler, I checked for STATE CHANGED messages. For File
> sources, usually after about 4 STATE CHANGED messages, the state is
> changed from READY TO PAUSED. However with HTTP sources, the source
> never changes from READY.

You should also check the return value of _set_state() for FAILURE
and/or check for ERROR messages on the bus. Do you get any error
messages?

Cheers
 -Tim



-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: palybin http sources

Ash-25
The return of set state is GST_STATE_CHANGE_ASYNC, and I do not get any error messages or any other type of message besides STATE_CHANGE.
 
I just receive 4 state change messages saying the oldstate was 1 (NULL) and new state is 2 (READY). After these 4 state messages, I receive a GStreamer-CRITICAL **: gst_bus_source_dispatch: assertion message !=NULL failed. message. I am not sure where this is coming from as it does not happen with file sources.


> From: [hidden email]
> To: [hidden email]
> Date: Tue, 22 Jul 2008 19:57:43 +0100
> Subject: Re: [gst-devel] palybin http sources
>
> On Tue, 2008-07-22 at 17:43 +0000, Ash wrote:
>
> > gst_element_set_state(pipeline, GST_STATE_PAUSED);
> > g_loop = g_main_loop_new(NULL, FALSE);
> > g_main_loop_run(g_loop);
> >
> > In my bus_test handler, I checked for STATE CHANGED messages. For File
> > sources, usually after about 4 STATE CHANGED messages, the state is
> > changed from READY TO PAUSED. However with HTTP sources, the source
> > never changes from READY.
>
> You should also check the return value of _set_state() for FAILURE
> and/or check for ERROR messages on the bus. Do you get any error
> messages?
>
> Cheers
> -Tim
>
>
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
> Build the coolest Linux based applications with Moblin SDK & win great prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> gstreamer-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/gstreamer-devel



Use video conversation to talk face-to-face with Windows Live Messenger. Get started.
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: palybin http sources

Ash-25
In reply to this post by Tim-Philipp Müller-2
Hello,
I fixed this problem by not adding playbin to another pipeline and just using playbin as the pipeline itself. Weird, but it works now.

> From: [hidden email]
> To: [hidden email]
> Date: Tue, 22 Jul 2008 19:57:43 +0100
> Subject: Re: [gst-devel] palybin http sources
>
> On Tue, 2008-07-22 at 17:43 +0000, Ash wrote:
>
> > gst_element_set_state(pipeline, GST_STATE_PAUSED);
> > g_loop = g_main_loop_new(NULL, FALSE);
> > g_main_loop_run(g_loop);
> >
> > In my bus_test handler, I checked for STATE CHANGED messages. For File
> > sources, usually after about 4 STATE CHANGED messages, the state is
> > changed from READY TO PAUSED. However with HTTP sources, the source
> > never changes from READY.
>
> You should also check the return value of _set_state() for FAILURE
> and/or check for ERROR messages on the bus. Do you get any error
> messages?
>
> Cheers
> -Tim
>
>
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
> Build the coolest Linux based applications with Moblin SDK & win great prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> gstreamer-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/gstreamer-devel



Time for vacation? WIN what you need. Enter Now!
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel